forked from neilmshah/bayou
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patha_e_pb2_grpc.py
63 lines (52 loc) · 2.07 KB
/
a_e_pb2_grpc.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
import grpc
import a_e_pb2 as a__e__pb2
class BayouStub(object):
# missing associated documentation comment in .proto file
pass
def __init__(self, channel):
"""Constructor.
Args:
channel: A grpc.Channel.
"""
self.anti_entropy = channel.stream_stream(
'/bayouapp.Bayou/anti_entropy',
request_serializer=a__e__pb2.calendarEntry.SerializeToString,
response_deserializer=a__e__pb2.calendarEntry.FromString,
)
self.checktest = channel.stream_stream(
'/bayouapp.Bayou/checktest',
request_serializer=a__e__pb2.test.SerializeToString,
response_deserializer=a__e__pb2.test.FromString,
)
class BayouServicer(object):
# missing associated documentation comment in .proto file
pass
def anti_entropy(self, request_iterator, 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!')
def checktest(self, request_iterator, 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!')
def add_BayouServicer_to_server(servicer, server):
rpc_method_handlers = {
'anti_entropy': grpc.stream_stream_rpc_method_handler(
servicer.anti_entropy,
request_deserializer=a__e__pb2.calendarEntry.FromString,
response_serializer=a__e__pb2.calendarEntry.SerializeToString,
),
'checktest': grpc.stream_stream_rpc_method_handler(
servicer.checktest,
request_deserializer=a__e__pb2.test.FromString,
response_serializer=a__e__pb2.test.SerializeToString,
),
}
generic_handler = grpc.method_handlers_generic_handler(
'bayouapp.Bayou', rpc_method_handlers)
server.add_generic_rpc_handlers((generic_handler,))