Slide 24
Slide 24 text
# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
import grpc
import cheese_pb2 as cheese__pb2
class CheeseServiceStub(object):
# missing associated documentation comment in .proto file
pass
def __init__(self, channel):
"""Constructor.
Args:
channel: A grpc.Channel.
"""
self.Order = channel.unary_unary(
'/cheesefarm.CheeseService/Order',
request_serializer=cheese__pb2.CheeseRequest.SerializeToString,
response_deserializer=cheese__pb2.Cheese.FromString,
)
class CheeseServiceServicer(object):
# missing associated documentation comment in .proto file
pass
def Order(self, request, context):
# missing associated documentation comment in .proto file
pass
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
context.set_details('Method not implemented!')
raise NotImplementedError('Method not implemented!')
Resulted code
example
gRPC Workflow