chalk-remote-call-python 1.10.5__cp315-cp315-win_amd64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- chalk_remote_call/__init__.py +4 -0
- chalk_remote_call/__main__.py +3 -0
- chalk_remote_call/_gen/__init__.py +0 -0
- chalk_remote_call/_gen/chalk/__init__.py +0 -0
- chalk_remote_call/_gen/chalk/auth/__init__.py +0 -0
- chalk_remote_call/_gen/chalk/auth/v1/__init__.py +0 -0
- chalk_remote_call/_gen/chalk/auth/v1/permissions_pb2.py +115 -0
- chalk_remote_call/_gen/chalk/auth/v1/permissions_pb2_grpc.py +4 -0
- chalk_remote_call/_gen/chalk/common/__init__.py +0 -0
- chalk_remote_call/_gen/chalk/common/v1/__init__.py +0 -0
- chalk_remote_call/_gen/chalk/common/v1/chalk_error_pb2.py +33 -0
- chalk_remote_call/_gen/chalk/common/v1/chalk_error_pb2_grpc.py +4 -0
- chalk_remote_call/_gen/chalk/runtime/__init__.py +0 -0
- chalk_remote_call/_gen/chalk/runtime/v1/__init__.py +0 -0
- chalk_remote_call/_gen/chalk/runtime/v1/fnq_consumer_pb2.py +53 -0
- chalk_remote_call/_gen/chalk/runtime/v1/fnq_consumer_pb2_grpc.py +138 -0
- chalk_remote_call/_gen/chalk/runtime/v1/remote_python_call_pb2.py +104 -0
- chalk_remote_call/_gen/chalk/runtime/v1/remote_python_call_pb2_grpc.py +363 -0
- chalk_remote_call/_gen/chalk/utils/__init__.py +0 -0
- chalk_remote_call/_gen/chalk/utils/v1/__init__.py +0 -0
- chalk_remote_call/_gen/chalk/utils/v1/encoding_pb2.py +32 -0
- chalk_remote_call/_gen/chalk/utils/v1/encoding_pb2_grpc.py +4 -0
- chalk_remote_call/_gen/chalk/utils/v1/field_change_pb2.py +29 -0
- chalk_remote_call/_gen/chalk/utils/v1/field_change_pb2_grpc.py +4 -0
- chalk_remote_call/_gen/chalk/utils/v1/large_pb2.py +26 -0
- chalk_remote_call/_gen/chalk/utils/v1/large_pb2_grpc.py +4 -0
- chalk_remote_call/_gen/chalk/utils/v1/sensitive_pb2.py +26 -0
- chalk_remote_call/_gen/chalk/utils/v1/sensitive_pb2_grpc.py +4 -0
- chalk_remote_call/_native.cp315-win_amd64.pyd +0 -0
- chalk_remote_call/_native.pyi +13 -0
- chalk_remote_call/_version.py +1 -0
- chalk_remote_call/arrow_utils.py +21 -0
- chalk_remote_call/cli.py +160 -0
- chalk_remote_call/errors.py +118 -0
- chalk_remote_call/handler_loader.py +57 -0
- chalk_remote_call/input_transform.py +50 -0
- chalk_remote_call/logging.py +29 -0
- chalk_remote_call/server.py +117 -0
- chalk_remote_call/servicer.py +400 -0
- chalk_remote_call/tracing.py +445 -0
- chalk_remote_call_python-1.10.5.dist-info/METADATA +288 -0
- chalk_remote_call_python-1.10.5.dist-info/RECORD +45 -0
- chalk_remote_call_python-1.10.5.dist-info/WHEEL +5 -0
- chalk_remote_call_python-1.10.5.dist-info/entry_points.txt +2 -0
- chalk_remote_call_python-1.10.5.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,363 @@
|
|
|
1
|
+
# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
|
|
2
|
+
"""Client and server classes corresponding to protobuf-defined services."""
|
|
3
|
+
import grpc
|
|
4
|
+
|
|
5
|
+
from chalk_remote_call._gen.chalk.runtime.v1 import remote_python_call_pb2 as chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class RemoteCallServiceStub(object):
|
|
9
|
+
"""Missing associated documentation comment in .proto file."""
|
|
10
|
+
|
|
11
|
+
def __init__(self, channel):
|
|
12
|
+
"""Constructor.
|
|
13
|
+
|
|
14
|
+
Args:
|
|
15
|
+
channel: A grpc.Channel.
|
|
16
|
+
"""
|
|
17
|
+
self.CallFunction = channel.stream_stream(
|
|
18
|
+
'/chalk.runtime.v1.RemoteCallService/CallFunction',
|
|
19
|
+
request_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.CallFunctionRequest.SerializeToString,
|
|
20
|
+
response_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.CallFunctionResponse.FromString,
|
|
21
|
+
)
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
class RemoteCallServiceServicer(object):
|
|
25
|
+
"""Missing associated documentation comment in .proto file."""
|
|
26
|
+
|
|
27
|
+
def CallFunction(self, request_iterator, context):
|
|
28
|
+
"""Missing associated documentation comment in .proto file."""
|
|
29
|
+
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
30
|
+
context.set_details('Method not implemented!')
|
|
31
|
+
raise NotImplementedError('Method not implemented!')
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
def add_RemoteCallServiceServicer_to_server(servicer, server):
|
|
35
|
+
rpc_method_handlers = {
|
|
36
|
+
'CallFunction': grpc.stream_stream_rpc_method_handler(
|
|
37
|
+
servicer.CallFunction,
|
|
38
|
+
request_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.CallFunctionRequest.FromString,
|
|
39
|
+
response_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.CallFunctionResponse.SerializeToString,
|
|
40
|
+
),
|
|
41
|
+
}
|
|
42
|
+
generic_handler = grpc.method_handlers_generic_handler(
|
|
43
|
+
'chalk.runtime.v1.RemoteCallService', rpc_method_handlers)
|
|
44
|
+
server.add_generic_rpc_handlers((generic_handler,))
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
# This class is part of an EXPERIMENTAL API.
|
|
48
|
+
class RemoteCallService(object):
|
|
49
|
+
"""Missing associated documentation comment in .proto file."""
|
|
50
|
+
|
|
51
|
+
@staticmethod
|
|
52
|
+
def CallFunction(request_iterator,
|
|
53
|
+
target,
|
|
54
|
+
options=(),
|
|
55
|
+
channel_credentials=None,
|
|
56
|
+
call_credentials=None,
|
|
57
|
+
insecure=False,
|
|
58
|
+
compression=None,
|
|
59
|
+
wait_for_ready=None,
|
|
60
|
+
timeout=None,
|
|
61
|
+
metadata=None):
|
|
62
|
+
return grpc.experimental.stream_stream(request_iterator, target, '/chalk.runtime.v1.RemoteCallService/CallFunction',
|
|
63
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.CallFunctionRequest.SerializeToString,
|
|
64
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.CallFunctionResponse.FromString,
|
|
65
|
+
options, channel_credentials,
|
|
66
|
+
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
class AsyncRemoteCallServiceStub(object):
|
|
70
|
+
"""Missing associated documentation comment in .proto file."""
|
|
71
|
+
|
|
72
|
+
def __init__(self, channel):
|
|
73
|
+
"""Constructor.
|
|
74
|
+
|
|
75
|
+
Args:
|
|
76
|
+
channel: A grpc.Channel.
|
|
77
|
+
"""
|
|
78
|
+
self.EnqueueRemoteCall = channel.unary_unary(
|
|
79
|
+
'/chalk.runtime.v1.AsyncRemoteCallService/EnqueueRemoteCall',
|
|
80
|
+
request_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.EnqueueRemoteCallRequest.SerializeToString,
|
|
81
|
+
response_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.EnqueueRemoteCallResponse.FromString,
|
|
82
|
+
)
|
|
83
|
+
self.PollRemoteCall = channel.unary_unary(
|
|
84
|
+
'/chalk.runtime.v1.AsyncRemoteCallService/PollRemoteCall',
|
|
85
|
+
request_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PollRemoteCallRequest.SerializeToString,
|
|
86
|
+
response_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PollRemoteCallResponse.FromString,
|
|
87
|
+
)
|
|
88
|
+
self.StreamRemoteCallBatch = channel.stream_stream(
|
|
89
|
+
'/chalk.runtime.v1.AsyncRemoteCallService/StreamRemoteCallBatch',
|
|
90
|
+
request_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.StreamRemoteCallBatchRequest.SerializeToString,
|
|
91
|
+
response_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.StreamRemoteCallBatchResponse.FromString,
|
|
92
|
+
)
|
|
93
|
+
self.PurgeQueue = channel.unary_unary(
|
|
94
|
+
'/chalk.runtime.v1.AsyncRemoteCallService/PurgeQueue',
|
|
95
|
+
request_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PurgeQueueRequest.SerializeToString,
|
|
96
|
+
response_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PurgeQueueResponse.FromString,
|
|
97
|
+
)
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
class AsyncRemoteCallServiceServicer(object):
|
|
101
|
+
"""Missing associated documentation comment in .proto file."""
|
|
102
|
+
|
|
103
|
+
def EnqueueRemoteCall(self, request, context):
|
|
104
|
+
"""Accept a CallFunctionRequest and enqueue it for async execution.
|
|
105
|
+
"""
|
|
106
|
+
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
107
|
+
context.set_details('Method not implemented!')
|
|
108
|
+
raise NotImplementedError('Method not implemented!')
|
|
109
|
+
|
|
110
|
+
def PollRemoteCall(self, request, context):
|
|
111
|
+
"""Poll for results. The caller passes a cursor to resume from the
|
|
112
|
+
last position; the server returns any new result chunks plus an
|
|
113
|
+
updated cursor.
|
|
114
|
+
"""
|
|
115
|
+
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
116
|
+
context.set_details('Method not implemented!')
|
|
117
|
+
raise NotImplementedError('Method not implemented!')
|
|
118
|
+
|
|
119
|
+
def StreamRemoteCallBatch(self, request_iterator, context):
|
|
120
|
+
"""Submit Arrow chunks containing many logical calls and receive per-call
|
|
121
|
+
acknowledgements and results without polling each call ID independently.
|
|
122
|
+
"""
|
|
123
|
+
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
124
|
+
context.set_details('Method not implemented!')
|
|
125
|
+
raise NotImplementedError('Method not implemented!')
|
|
126
|
+
|
|
127
|
+
def PurgeQueue(self, request, context):
|
|
128
|
+
"""Drop pending items from one or all per-function queues for the tenant.
|
|
129
|
+
"""
|
|
130
|
+
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
131
|
+
context.set_details('Method not implemented!')
|
|
132
|
+
raise NotImplementedError('Method not implemented!')
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
def add_AsyncRemoteCallServiceServicer_to_server(servicer, server):
|
|
136
|
+
rpc_method_handlers = {
|
|
137
|
+
'EnqueueRemoteCall': grpc.unary_unary_rpc_method_handler(
|
|
138
|
+
servicer.EnqueueRemoteCall,
|
|
139
|
+
request_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.EnqueueRemoteCallRequest.FromString,
|
|
140
|
+
response_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.EnqueueRemoteCallResponse.SerializeToString,
|
|
141
|
+
),
|
|
142
|
+
'PollRemoteCall': grpc.unary_unary_rpc_method_handler(
|
|
143
|
+
servicer.PollRemoteCall,
|
|
144
|
+
request_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PollRemoteCallRequest.FromString,
|
|
145
|
+
response_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PollRemoteCallResponse.SerializeToString,
|
|
146
|
+
),
|
|
147
|
+
'StreamRemoteCallBatch': grpc.stream_stream_rpc_method_handler(
|
|
148
|
+
servicer.StreamRemoteCallBatch,
|
|
149
|
+
request_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.StreamRemoteCallBatchRequest.FromString,
|
|
150
|
+
response_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.StreamRemoteCallBatchResponse.SerializeToString,
|
|
151
|
+
),
|
|
152
|
+
'PurgeQueue': grpc.unary_unary_rpc_method_handler(
|
|
153
|
+
servicer.PurgeQueue,
|
|
154
|
+
request_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PurgeQueueRequest.FromString,
|
|
155
|
+
response_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PurgeQueueResponse.SerializeToString,
|
|
156
|
+
),
|
|
157
|
+
}
|
|
158
|
+
generic_handler = grpc.method_handlers_generic_handler(
|
|
159
|
+
'chalk.runtime.v1.AsyncRemoteCallService', rpc_method_handlers)
|
|
160
|
+
server.add_generic_rpc_handlers((generic_handler,))
|
|
161
|
+
|
|
162
|
+
|
|
163
|
+
# This class is part of an EXPERIMENTAL API.
|
|
164
|
+
class AsyncRemoteCallService(object):
|
|
165
|
+
"""Missing associated documentation comment in .proto file."""
|
|
166
|
+
|
|
167
|
+
@staticmethod
|
|
168
|
+
def EnqueueRemoteCall(request,
|
|
169
|
+
target,
|
|
170
|
+
options=(),
|
|
171
|
+
channel_credentials=None,
|
|
172
|
+
call_credentials=None,
|
|
173
|
+
insecure=False,
|
|
174
|
+
compression=None,
|
|
175
|
+
wait_for_ready=None,
|
|
176
|
+
timeout=None,
|
|
177
|
+
metadata=None):
|
|
178
|
+
return grpc.experimental.unary_unary(request, target, '/chalk.runtime.v1.AsyncRemoteCallService/EnqueueRemoteCall',
|
|
179
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.EnqueueRemoteCallRequest.SerializeToString,
|
|
180
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.EnqueueRemoteCallResponse.FromString,
|
|
181
|
+
options, channel_credentials,
|
|
182
|
+
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
183
|
+
|
|
184
|
+
@staticmethod
|
|
185
|
+
def PollRemoteCall(request,
|
|
186
|
+
target,
|
|
187
|
+
options=(),
|
|
188
|
+
channel_credentials=None,
|
|
189
|
+
call_credentials=None,
|
|
190
|
+
insecure=False,
|
|
191
|
+
compression=None,
|
|
192
|
+
wait_for_ready=None,
|
|
193
|
+
timeout=None,
|
|
194
|
+
metadata=None):
|
|
195
|
+
return grpc.experimental.unary_unary(request, target, '/chalk.runtime.v1.AsyncRemoteCallService/PollRemoteCall',
|
|
196
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PollRemoteCallRequest.SerializeToString,
|
|
197
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PollRemoteCallResponse.FromString,
|
|
198
|
+
options, channel_credentials,
|
|
199
|
+
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
200
|
+
|
|
201
|
+
@staticmethod
|
|
202
|
+
def StreamRemoteCallBatch(request_iterator,
|
|
203
|
+
target,
|
|
204
|
+
options=(),
|
|
205
|
+
channel_credentials=None,
|
|
206
|
+
call_credentials=None,
|
|
207
|
+
insecure=False,
|
|
208
|
+
compression=None,
|
|
209
|
+
wait_for_ready=None,
|
|
210
|
+
timeout=None,
|
|
211
|
+
metadata=None):
|
|
212
|
+
return grpc.experimental.stream_stream(request_iterator, target, '/chalk.runtime.v1.AsyncRemoteCallService/StreamRemoteCallBatch',
|
|
213
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.StreamRemoteCallBatchRequest.SerializeToString,
|
|
214
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.StreamRemoteCallBatchResponse.FromString,
|
|
215
|
+
options, channel_credentials,
|
|
216
|
+
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
217
|
+
|
|
218
|
+
@staticmethod
|
|
219
|
+
def PurgeQueue(request,
|
|
220
|
+
target,
|
|
221
|
+
options=(),
|
|
222
|
+
channel_credentials=None,
|
|
223
|
+
call_credentials=None,
|
|
224
|
+
insecure=False,
|
|
225
|
+
compression=None,
|
|
226
|
+
wait_for_ready=None,
|
|
227
|
+
timeout=None,
|
|
228
|
+
metadata=None):
|
|
229
|
+
return grpc.experimental.unary_unary(request, target, '/chalk.runtime.v1.AsyncRemoteCallService/PurgeQueue',
|
|
230
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PurgeQueueRequest.SerializeToString,
|
|
231
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.PurgeQueueResponse.FromString,
|
|
232
|
+
options, channel_credentials,
|
|
233
|
+
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
class FunctionQueueMetaServiceStub(object):
|
|
237
|
+
"""Missing associated documentation comment in .proto file."""
|
|
238
|
+
|
|
239
|
+
def __init__(self, channel):
|
|
240
|
+
"""Constructor.
|
|
241
|
+
|
|
242
|
+
Args:
|
|
243
|
+
channel: A grpc.Channel.
|
|
244
|
+
"""
|
|
245
|
+
self.GetRecentCalls = channel.unary_unary(
|
|
246
|
+
'/chalk.runtime.v1.FunctionQueueMetaService/GetRecentCalls',
|
|
247
|
+
request_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetRecentCallsRequest.SerializeToString,
|
|
248
|
+
response_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetRecentCallsResponse.FromString,
|
|
249
|
+
)
|
|
250
|
+
self.GetCallResults = channel.unary_unary(
|
|
251
|
+
'/chalk.runtime.v1.FunctionQueueMetaService/GetCallResults',
|
|
252
|
+
request_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallResultsRequest.SerializeToString,
|
|
253
|
+
response_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallResultsResponse.FromString,
|
|
254
|
+
)
|
|
255
|
+
self.GetCallCount = channel.unary_unary(
|
|
256
|
+
'/chalk.runtime.v1.FunctionQueueMetaService/GetCallCount',
|
|
257
|
+
request_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallCountRequest.SerializeToString,
|
|
258
|
+
response_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallCountResponse.FromString,
|
|
259
|
+
)
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
class FunctionQueueMetaServiceServicer(object):
|
|
263
|
+
"""Missing associated documentation comment in .proto file."""
|
|
264
|
+
|
|
265
|
+
def GetRecentCalls(self, request, context):
|
|
266
|
+
"""Return the most recent k calls to a function, ordered newest-first.
|
|
267
|
+
"""
|
|
268
|
+
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
269
|
+
context.set_details('Method not implemented!')
|
|
270
|
+
raise NotImplementedError('Method not implemented!')
|
|
271
|
+
|
|
272
|
+
def GetCallResults(self, request, context):
|
|
273
|
+
"""Return current status and accumulated result chunks for specific calls.
|
|
274
|
+
"""
|
|
275
|
+
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
276
|
+
context.set_details('Method not implemented!')
|
|
277
|
+
raise NotImplementedError('Method not implemented!')
|
|
278
|
+
|
|
279
|
+
def GetCallCount(self, request, context):
|
|
280
|
+
"""Return the number of calls submitted to a function in the past hour.
|
|
281
|
+
"""
|
|
282
|
+
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
283
|
+
context.set_details('Method not implemented!')
|
|
284
|
+
raise NotImplementedError('Method not implemented!')
|
|
285
|
+
|
|
286
|
+
|
|
287
|
+
def add_FunctionQueueMetaServiceServicer_to_server(servicer, server):
|
|
288
|
+
rpc_method_handlers = {
|
|
289
|
+
'GetRecentCalls': grpc.unary_unary_rpc_method_handler(
|
|
290
|
+
servicer.GetRecentCalls,
|
|
291
|
+
request_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetRecentCallsRequest.FromString,
|
|
292
|
+
response_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetRecentCallsResponse.SerializeToString,
|
|
293
|
+
),
|
|
294
|
+
'GetCallResults': grpc.unary_unary_rpc_method_handler(
|
|
295
|
+
servicer.GetCallResults,
|
|
296
|
+
request_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallResultsRequest.FromString,
|
|
297
|
+
response_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallResultsResponse.SerializeToString,
|
|
298
|
+
),
|
|
299
|
+
'GetCallCount': grpc.unary_unary_rpc_method_handler(
|
|
300
|
+
servicer.GetCallCount,
|
|
301
|
+
request_deserializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallCountRequest.FromString,
|
|
302
|
+
response_serializer=chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallCountResponse.SerializeToString,
|
|
303
|
+
),
|
|
304
|
+
}
|
|
305
|
+
generic_handler = grpc.method_handlers_generic_handler(
|
|
306
|
+
'chalk.runtime.v1.FunctionQueueMetaService', rpc_method_handlers)
|
|
307
|
+
server.add_generic_rpc_handlers((generic_handler,))
|
|
308
|
+
|
|
309
|
+
|
|
310
|
+
# This class is part of an EXPERIMENTAL API.
|
|
311
|
+
class FunctionQueueMetaService(object):
|
|
312
|
+
"""Missing associated documentation comment in .proto file."""
|
|
313
|
+
|
|
314
|
+
@staticmethod
|
|
315
|
+
def GetRecentCalls(request,
|
|
316
|
+
target,
|
|
317
|
+
options=(),
|
|
318
|
+
channel_credentials=None,
|
|
319
|
+
call_credentials=None,
|
|
320
|
+
insecure=False,
|
|
321
|
+
compression=None,
|
|
322
|
+
wait_for_ready=None,
|
|
323
|
+
timeout=None,
|
|
324
|
+
metadata=None):
|
|
325
|
+
return grpc.experimental.unary_unary(request, target, '/chalk.runtime.v1.FunctionQueueMetaService/GetRecentCalls',
|
|
326
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetRecentCallsRequest.SerializeToString,
|
|
327
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetRecentCallsResponse.FromString,
|
|
328
|
+
options, channel_credentials,
|
|
329
|
+
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
330
|
+
|
|
331
|
+
@staticmethod
|
|
332
|
+
def GetCallResults(request,
|
|
333
|
+
target,
|
|
334
|
+
options=(),
|
|
335
|
+
channel_credentials=None,
|
|
336
|
+
call_credentials=None,
|
|
337
|
+
insecure=False,
|
|
338
|
+
compression=None,
|
|
339
|
+
wait_for_ready=None,
|
|
340
|
+
timeout=None,
|
|
341
|
+
metadata=None):
|
|
342
|
+
return grpc.experimental.unary_unary(request, target, '/chalk.runtime.v1.FunctionQueueMetaService/GetCallResults',
|
|
343
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallResultsRequest.SerializeToString,
|
|
344
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallResultsResponse.FromString,
|
|
345
|
+
options, channel_credentials,
|
|
346
|
+
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
347
|
+
|
|
348
|
+
@staticmethod
|
|
349
|
+
def GetCallCount(request,
|
|
350
|
+
target,
|
|
351
|
+
options=(),
|
|
352
|
+
channel_credentials=None,
|
|
353
|
+
call_credentials=None,
|
|
354
|
+
insecure=False,
|
|
355
|
+
compression=None,
|
|
356
|
+
wait_for_ready=None,
|
|
357
|
+
timeout=None,
|
|
358
|
+
metadata=None):
|
|
359
|
+
return grpc.experimental.unary_unary(request, target, '/chalk.runtime.v1.FunctionQueueMetaService/GetCallCount',
|
|
360
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallCountRequest.SerializeToString,
|
|
361
|
+
chalk_dot_runtime_dot_v1_dot_remote__python__call__pb2.GetCallCountResponse.FromString,
|
|
362
|
+
options, channel_credentials,
|
|
363
|
+
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
3
|
+
# source: chalk/utils/v1/encoding.proto
|
|
4
|
+
# Protobuf Python Version: 4.25.3
|
|
5
|
+
"""Generated protocol buffer code."""
|
|
6
|
+
from google.protobuf import descriptor as _descriptor
|
|
7
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
8
|
+
from google.protobuf import symbol_database as _symbol_database
|
|
9
|
+
from google.protobuf.internal import builder as _builder
|
|
10
|
+
# @@protoc_insertion_point(imports)
|
|
11
|
+
|
|
12
|
+
_sym_db = _symbol_database.Default()
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from google.protobuf import descriptor_pb2 as google_dot_protobuf_dot_descriptor__pb2
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1d\x63halk/utils/v1/encoding.proto\x12\x0e\x63halk.utils.v1\x1a google/protobuf/descriptor.proto\"\x93\x01\n\x0eStringEncoding\x12\x45\n\x07mapping\x18\x01 \x03(\x0b\x32+.chalk.utils.v1.StringEncoding.MappingEntryR\x07mapping\x1a:\n\x0cMappingEntry\x12\x10\n\x03key\x18\x01 \x01(\x05R\x03key\x12\x14\n\x05value\x18\x02 \x01(\tR\x05value:\x02\x38\x01:]\n\x08\x65ncoding\x12\x1c.google.protobuf.EnumOptions\x18\x9c\xf4\x04 \x01(\x0b\x32\x1e.chalk.utils.v1.StringEncodingR\x08\x65ncoding\x88\x01\x01\x42}\n\x12\x63om.chalk.utils.v1B\rEncodingProtoP\x01\xa2\x02\x03\x43UX\xaa\x02\x0e\x43halk.Utils.V1\xca\x02\x0e\x43halk\\Utils\\V1\xe2\x02\x1a\x43halk\\Utils\\V1\\GPBMetadata\xea\x02\x10\x43halk::Utils::V1b\x06proto3')
|
|
19
|
+
|
|
20
|
+
_globals = globals()
|
|
21
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
|
22
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'chalk.utils.v1.encoding_pb2', _globals)
|
|
23
|
+
if _descriptor._USE_C_DESCRIPTORS == False:
|
|
24
|
+
_globals['DESCRIPTOR']._options = None
|
|
25
|
+
_globals['DESCRIPTOR']._serialized_options = b'\n\022com.chalk.utils.v1B\rEncodingProtoP\001\242\002\003CUX\252\002\016Chalk.Utils.V1\312\002\016Chalk\\Utils\\V1\342\002\032Chalk\\Utils\\V1\\GPBMetadata\352\002\020Chalk::Utils::V1'
|
|
26
|
+
_globals['_STRINGENCODING_MAPPINGENTRY']._options = None
|
|
27
|
+
_globals['_STRINGENCODING_MAPPINGENTRY']._serialized_options = b'8\001'
|
|
28
|
+
_globals['_STRINGENCODING']._serialized_start=84
|
|
29
|
+
_globals['_STRINGENCODING']._serialized_end=231
|
|
30
|
+
_globals['_STRINGENCODING_MAPPINGENTRY']._serialized_start=173
|
|
31
|
+
_globals['_STRINGENCODING_MAPPINGENTRY']._serialized_end=231
|
|
32
|
+
# @@protoc_insertion_point(module_scope)
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
3
|
+
# source: chalk/utils/v1/field_change.proto
|
|
4
|
+
# Protobuf Python Version: 4.25.3
|
|
5
|
+
"""Generated protocol buffer code."""
|
|
6
|
+
from google.protobuf import descriptor as _descriptor
|
|
7
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
8
|
+
from google.protobuf import symbol_database as _symbol_database
|
|
9
|
+
from google.protobuf.internal import builder as _builder
|
|
10
|
+
# @@protoc_insertion_point(imports)
|
|
11
|
+
|
|
12
|
+
_sym_db = _symbol_database.Default()
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n!chalk/utils/v1/field_change.proto\x12\x0e\x63halk.utils.v1\"\xe0\x01\n\x0b\x46ieldChange\x12\x1d\n\nfield_name\x18\x01 \x01(\tR\tfieldName\x12*\n\x0eprevious_value\x18\x02 \x01(\tH\x00R\rpreviousValue\x88\x01\x01\x12 \n\tnew_value\x18\x03 \x01(\tH\x01R\x08newValue\x88\x01\x01\x12\x43\n\x0enested_changes\x18\x04 \x03(\x0b\x32\x1c.chalk.utils.v1.NestedChangeR\rnestedChangesB\x11\n\x0f_previous_valueB\x0c\n\n_new_value\"\x91\x01\n\x0cNestedChange\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path\x12*\n\x0eprevious_value\x18\x02 \x01(\tH\x00R\rpreviousValue\x88\x01\x01\x12 \n\tnew_value\x18\x03 \x01(\tH\x01R\x08newValue\x88\x01\x01\x42\x11\n\x0f_previous_valueB\x0c\n\n_new_valueB\x80\x01\n\x12\x63om.chalk.utils.v1B\x10\x46ieldChangeProtoP\x01\xa2\x02\x03\x43UX\xaa\x02\x0e\x43halk.Utils.V1\xca\x02\x0e\x43halk\\Utils\\V1\xe2\x02\x1a\x43halk\\Utils\\V1\\GPBMetadata\xea\x02\x10\x43halk::Utils::V1b\x06proto3')
|
|
18
|
+
|
|
19
|
+
_globals = globals()
|
|
20
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
|
21
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'chalk.utils.v1.field_change_pb2', _globals)
|
|
22
|
+
if _descriptor._USE_C_DESCRIPTORS == False:
|
|
23
|
+
_globals['DESCRIPTOR']._options = None
|
|
24
|
+
_globals['DESCRIPTOR']._serialized_options = b'\n\022com.chalk.utils.v1B\020FieldChangeProtoP\001\242\002\003CUX\252\002\016Chalk.Utils.V1\312\002\016Chalk\\Utils\\V1\342\002\032Chalk\\Utils\\V1\\GPBMetadata\352\002\020Chalk::Utils::V1'
|
|
25
|
+
_globals['_FIELDCHANGE']._serialized_start=54
|
|
26
|
+
_globals['_FIELDCHANGE']._serialized_end=278
|
|
27
|
+
_globals['_NESTEDCHANGE']._serialized_start=281
|
|
28
|
+
_globals['_NESTEDCHANGE']._serialized_end=426
|
|
29
|
+
# @@protoc_insertion_point(module_scope)
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
3
|
+
# source: chalk/utils/v1/large.proto
|
|
4
|
+
# Protobuf Python Version: 4.25.3
|
|
5
|
+
"""Generated protocol buffer code."""
|
|
6
|
+
from google.protobuf import descriptor as _descriptor
|
|
7
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
8
|
+
from google.protobuf import symbol_database as _symbol_database
|
|
9
|
+
from google.protobuf.internal import builder as _builder
|
|
10
|
+
# @@protoc_insertion_point(imports)
|
|
11
|
+
|
|
12
|
+
_sym_db = _symbol_database.Default()
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from google.protobuf import descriptor_pb2 as google_dot_protobuf_dot_descriptor__pb2
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1a\x63halk/utils/v1/large.proto\x12\x0e\x63halk.utils.v1\x1a google/protobuf/descriptor.proto:8\n\x05large\x12\x1d.google.protobuf.FieldOptions\x18\x9d\xf4\x04 \x01(\x08R\x05large\x88\x01\x01\x42z\n\x12\x63om.chalk.utils.v1B\nLargeProtoP\x01\xa2\x02\x03\x43UX\xaa\x02\x0e\x43halk.Utils.V1\xca\x02\x0e\x43halk\\Utils\\V1\xe2\x02\x1a\x43halk\\Utils\\V1\\GPBMetadata\xea\x02\x10\x43halk::Utils::V1b\x06proto3')
|
|
19
|
+
|
|
20
|
+
_globals = globals()
|
|
21
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
|
22
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'chalk.utils.v1.large_pb2', _globals)
|
|
23
|
+
if _descriptor._USE_C_DESCRIPTORS == False:
|
|
24
|
+
_globals['DESCRIPTOR']._options = None
|
|
25
|
+
_globals['DESCRIPTOR']._serialized_options = b'\n\022com.chalk.utils.v1B\nLargeProtoP\001\242\002\003CUX\252\002\016Chalk.Utils.V1\312\002\016Chalk\\Utils\\V1\342\002\032Chalk\\Utils\\V1\\GPBMetadata\352\002\020Chalk::Utils::V1'
|
|
26
|
+
# @@protoc_insertion_point(module_scope)
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# -*- coding: utf-8 -*-
|
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
3
|
+
# source: chalk/utils/v1/sensitive.proto
|
|
4
|
+
# Protobuf Python Version: 4.25.3
|
|
5
|
+
"""Generated protocol buffer code."""
|
|
6
|
+
from google.protobuf import descriptor as _descriptor
|
|
7
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
8
|
+
from google.protobuf import symbol_database as _symbol_database
|
|
9
|
+
from google.protobuf.internal import builder as _builder
|
|
10
|
+
# @@protoc_insertion_point(imports)
|
|
11
|
+
|
|
12
|
+
_sym_db = _symbol_database.Default()
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from google.protobuf import descriptor_pb2 as google_dot_protobuf_dot_descriptor__pb2
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1e\x63halk/utils/v1/sensitive.proto\x12\x0e\x63halk.utils.v1\x1a google/protobuf/descriptor.proto:@\n\tsensitive\x12\x1d.google.protobuf.FieldOptions\x18\x9b\xf4\x04 \x01(\x08R\tsensitive\x88\x01\x01\x42~\n\x12\x63om.chalk.utils.v1B\x0eSensitiveProtoP\x01\xa2\x02\x03\x43UX\xaa\x02\x0e\x43halk.Utils.V1\xca\x02\x0e\x43halk\\Utils\\V1\xe2\x02\x1a\x43halk\\Utils\\V1\\GPBMetadata\xea\x02\x10\x43halk::Utils::V1b\x06proto3')
|
|
19
|
+
|
|
20
|
+
_globals = globals()
|
|
21
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
|
22
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'chalk.utils.v1.sensitive_pb2', _globals)
|
|
23
|
+
if _descriptor._USE_C_DESCRIPTORS == False:
|
|
24
|
+
_globals['DESCRIPTOR']._options = None
|
|
25
|
+
_globals['DESCRIPTOR']._serialized_options = b'\n\022com.chalk.utils.v1B\016SensitiveProtoP\001\242\002\003CUX\252\002\016Chalk.Utils.V1\312\002\016Chalk\\Utils\\V1\342\002\032Chalk\\Utils\\V1\\GPBMetadata\352\002\020Chalk::Utils::V1'
|
|
26
|
+
# @@protoc_insertion_point(module_scope)
|
|
Binary file
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
from collections.abc import Callable
|
|
2
|
+
from typing import Any
|
|
3
|
+
|
|
4
|
+
def start_server(
|
|
5
|
+
handler: Callable[..., Any],
|
|
6
|
+
process_fn: Callable[..., list[bytes]],
|
|
7
|
+
host: str,
|
|
8
|
+
port: int,
|
|
9
|
+
workers: int,
|
|
10
|
+
arg_names: list[str] | None = None,
|
|
11
|
+
max_batching_size: int = 0,
|
|
12
|
+
max_buffer_duration_ms: int = 0,
|
|
13
|
+
) -> None: ...
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "1.10.5"
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
from __future__ import annotations
|
|
2
|
+
|
|
3
|
+
import pyarrow as pa
|
|
4
|
+
import pyarrow.ipc as ipc
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
def decode_ipc_stream(data: bytes) -> list[pa.RecordBatch]:
|
|
8
|
+
"""Eagerly decode all batches, for callers that need the complete stream.
|
|
9
|
+
|
|
10
|
+
For incremental processing, iterate over ``ipc.open_stream(data)`` instead.
|
|
11
|
+
"""
|
|
12
|
+
with ipc.open_stream(data) as reader:
|
|
13
|
+
return list(reader)
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
def encode_record_batch(batch: pa.RecordBatch) -> bytes:
|
|
17
|
+
"""Encode a RecordBatch as Arrow IPC stream bytes."""
|
|
18
|
+
sink = pa.BufferOutputStream()
|
|
19
|
+
with ipc.new_stream(sink, batch.schema) as writer:
|
|
20
|
+
writer.write_batch(batch)
|
|
21
|
+
return sink.getvalue().to_pybytes()
|