indexify 0.4.9__tar.gz → 0.4.10__tar.gz
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.
- {indexify-0.4.9 → indexify-0.4.10}/PKG-INFO +2 -2
- {indexify-0.4.9 → indexify-0.4.10}/pyproject.toml +2 -2
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/executor.py +1 -1
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/function_executor.py +35 -7
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/invocation_state_client.py +26 -16
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/completed_task_metrics.py +1 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/create_function_executor.py +1 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/downloads.py +20 -9
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/function_executor_controller.py +4 -7
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/run_task.py +68 -20
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/task_output.py +11 -14
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/upload_task_output.py +102 -62
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/proto/executor_api.proto +32 -28
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/proto/executor_api_pb2.py +19 -21
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/proto/executor_api_pb2.pyi +8 -10
- {indexify-0.4.9 → indexify-0.4.10}/README.md +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/cli/__init__.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/cli/build_image.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/cli/deploy.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/cli/executor.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/README.md +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/blob_store/blob_store.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/blob_store/local_fs_blob_store.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/blob_store/metrics/blob_store.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/blob_store/s3_blob_store.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/channel_manager.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_allowlist.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/health_checker.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/metrics/function_executor.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/metrics/health_checker.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/metrics/invocation_state_client.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/server/client_configuration.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/server/function_executor_server.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/server/function_executor_server_factory.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/server/subprocess_function_executor_server.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/server/subprocess_function_executor_server_factory.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/__init__.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/debug_event_loop.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/destroy_function_executor.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/events.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/function_executor_startup_output.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/loggers.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/message_validators.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/metrics/completed_task_metrics.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/metrics/downloads.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/metrics/function_executor_controller.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/metrics/run_task.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/metrics/upload_task_output.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/prepare_task.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/task_info.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/host_resources/host_resources.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/host_resources/nvidia_gpu.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/host_resources/nvidia_gpu_allocator.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/metrics/channel_manager.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/metrics/executor.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/metrics/state_reconciler.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/metrics/state_reporter.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/monitoring/handler.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/monitoring/health_check_handler.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/monitoring/health_checker/generic_health_checker.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/monitoring/health_checker/health_checker.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/monitoring/metrics.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/monitoring/prometheus_metrics_handler.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/monitoring/server.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/monitoring/startup_probe_handler.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/state_reconciler.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/state_reporter.py +0 -0
- {indexify-0.4.9 → indexify-0.4.10}/src/indexify/proto/executor_api_pb2_grpc.py +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.3
|
2
2
|
Name: indexify
|
3
|
-
Version: 0.4.
|
3
|
+
Version: 0.4.10
|
4
4
|
Summary: Open Source Indexify components and helper tools
|
5
5
|
Home-page: https://github.com/tensorlakeai/indexify
|
6
6
|
License: Apache 2.0
|
@@ -17,7 +17,7 @@ Requires-Dist: aiohttp (>=3.11.0,<4.0.0)
|
|
17
17
|
Requires-Dist: boto3 (>=1.37.30,<2.0.0)
|
18
18
|
Requires-Dist: prometheus-client (>=0.21.1,<0.22.0)
|
19
19
|
Requires-Dist: psutil (>=7.0.0,<8.0.0)
|
20
|
-
Requires-Dist: tensorlake (==0.2.
|
20
|
+
Requires-Dist: tensorlake (==0.2.7)
|
21
21
|
Project-URL: Repository, https://github.com/tensorlakeai/indexify
|
22
22
|
Description-Content-Type: text/markdown
|
23
23
|
|
@@ -1,7 +1,7 @@
|
|
1
1
|
[tool.poetry]
|
2
2
|
name = "indexify"
|
3
3
|
# Incremented if any of the components provided in this packages are updated.
|
4
|
-
version = "0.4.
|
4
|
+
version = "0.4.10"
|
5
5
|
description = "Open Source Indexify components and helper tools"
|
6
6
|
authors = ["Tensorlake Inc. <support@tensorlake.ai>"]
|
7
7
|
license = "Apache 2.0"
|
@@ -25,7 +25,7 @@ prometheus-client = "^0.21.1"
|
|
25
25
|
psutil = "^7.0.0"
|
26
26
|
# Adds function-executor binary, utils lib, sdk used in indexify-cli commands.
|
27
27
|
# We need to specify the tensorlake version exactly because pip install doesn't respect poetry.lock files.
|
28
|
-
tensorlake = "0.2.
|
28
|
+
tensorlake = "0.2.7"
|
29
29
|
# Uncomment the next line to use local tensorlake package (only for development!)
|
30
30
|
# tensorlake = { path = "../tensorlake", develop = true }
|
31
31
|
# pydantic is provided by tensorlake
|
@@ -52,7 +52,7 @@ class Executor:
|
|
52
52
|
blob_store: BLOBStore,
|
53
53
|
host_resources_provider: HostResourcesProvider,
|
54
54
|
):
|
55
|
-
self._logger = structlog.get_logger(module=__name__)
|
55
|
+
self._logger = structlog.get_logger(module=__name__, executor_id=id)
|
56
56
|
protocol: str = "http"
|
57
57
|
if config_path:
|
58
58
|
self._logger.info("running the extractor with TLS enabled")
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/function_executor.py
RENAMED
@@ -7,6 +7,8 @@ import grpc
|
|
7
7
|
from tensorlake.function_executor.proto.function_executor_pb2 import (
|
8
8
|
InfoRequest,
|
9
9
|
InfoResponse,
|
10
|
+
InitializationFailureReason,
|
11
|
+
InitializationOutcomeCode,
|
10
12
|
InitializeRequest,
|
11
13
|
InitializeResponse,
|
12
14
|
)
|
@@ -315,16 +317,42 @@ async def _initialize_server(
|
|
315
317
|
initialize_request,
|
316
318
|
timeout=customer_code_timeout_sec,
|
317
319
|
)
|
318
|
-
|
319
|
-
if
|
320
|
-
|
321
|
-
|
320
|
+
|
321
|
+
if (
|
322
|
+
initialize_response.outcome_code
|
323
|
+
== InitializationOutcomeCode.INITIALIZE_OUTCOME_CODE_SUCCESS
|
324
|
+
):
|
322
325
|
return FunctionExecutorInitializationResult(
|
323
|
-
|
324
|
-
stderr=initialize_response.customer_error,
|
326
|
+
stdout=initialize_response.stdout, stderr=initialize_response.stderr
|
325
327
|
)
|
328
|
+
elif (
|
329
|
+
initialize_response.outcome_code
|
330
|
+
== InitializationOutcomeCode.INITIALIZE_OUTCOME_CODE_FAILURE
|
331
|
+
):
|
332
|
+
if (
|
333
|
+
initialize_response.failure_reason
|
334
|
+
== InitializationFailureReason.INITIALIZATION_FAILURE_REASON_FUNCTION_ERROR
|
335
|
+
):
|
336
|
+
return FunctionExecutorInitializationResult(
|
337
|
+
error=FunctionExecutorInitializationError.FUNCTION_ERROR,
|
338
|
+
stdout=initialize_response.stdout,
|
339
|
+
stderr=initialize_response.stderr,
|
340
|
+
)
|
341
|
+
elif (
|
342
|
+
initialize_response.failure_reason
|
343
|
+
== InitializationFailureReason.INITIALIZATION_FAILURE_REASON_INTERNAL_ERROR
|
344
|
+
):
|
345
|
+
# Don't add stdout/stderr because this is customer data.
|
346
|
+
raise RuntimeError("initialize RPC failed with internal error")
|
347
|
+
else:
|
348
|
+
raise ValueError(
|
349
|
+
f"unexpected failure reason {InitializationFailureReason.Name(initialize_response.failure_reason)} in initialize RPC response"
|
350
|
+
)
|
326
351
|
else:
|
327
|
-
raise
|
352
|
+
raise ValueError(
|
353
|
+
f"unexpected outcome code {InitializationOutcomeCode.Name(initialize_response.outcome_code)} in initialize RPC response"
|
354
|
+
)
|
355
|
+
|
328
356
|
except grpc.aio.AioRpcError as e:
|
329
357
|
if e.code() == grpc.StatusCode.DEADLINE_EXCEEDED:
|
330
358
|
return FunctionExecutorInitializationResult(
|
@@ -8,6 +8,7 @@ from tensorlake.function_executor.proto.function_executor_pb2 import (
|
|
8
8
|
InvocationStateRequest,
|
9
9
|
InvocationStateResponse,
|
10
10
|
SerializedObject,
|
11
|
+
SerializedObjectEncoding,
|
11
12
|
SetInvocationStateResponse,
|
12
13
|
)
|
13
14
|
from tensorlake.function_executor.proto.function_executor_pb2_grpc import (
|
@@ -25,6 +26,10 @@ from .metrics.invocation_state_client import (
|
|
25
26
|
metric_server_set_state_requests,
|
26
27
|
)
|
27
28
|
|
29
|
+
# We're currently only supporting CloudPickle for invocation state values.
|
30
|
+
# FIXME: if Function Executor sends us something else then we fail the calls.
|
31
|
+
_VALUE_CONTENT_TYPE = "application/octet-stream"
|
32
|
+
|
28
33
|
|
29
34
|
class InvocationStateClient:
|
30
35
|
"""InvocationStateClient is a client for the invocation state server of a Function Executor.
|
@@ -196,14 +201,21 @@ class InvocationStateClient:
|
|
196
201
|
url: str = (
|
197
202
|
f"{self._base_url}/internal/namespaces/{self._namespace}/compute_graphs/{self._graph}/invocations/{invocation_id}/ctx/{key}"
|
198
203
|
)
|
199
|
-
|
204
|
+
if (
|
205
|
+
value.encoding
|
206
|
+
!= SerializedObjectEncoding.SERIALIZED_OBJECT_ENCODING_BINARY_PICKLE
|
207
|
+
):
|
208
|
+
raise ValueError(
|
209
|
+
f"Unsupported value encoding: {SerializedObjectEncoding.Name(value.encoding)}. "
|
210
|
+
"Only binary pickle is supported for invocation state values."
|
211
|
+
)
|
200
212
|
|
201
213
|
response = await self._http_client.post(
|
202
214
|
url=url,
|
203
215
|
files=[
|
204
216
|
(
|
205
217
|
"value",
|
206
|
-
("value",
|
218
|
+
("value", value.data, _VALUE_CONTENT_TYPE),
|
207
219
|
),
|
208
220
|
],
|
209
221
|
)
|
@@ -245,7 +257,7 @@ class InvocationStateClient:
|
|
245
257
|
)
|
246
258
|
raise
|
247
259
|
|
248
|
-
return
|
260
|
+
return _serialized_object_from_http_response(response)
|
249
261
|
|
250
262
|
def _validate_request(self, request: InvocationStateRequest) -> None:
|
251
263
|
(
|
@@ -265,17 +277,15 @@ class InvocationStateClient:
|
|
265
277
|
raise ValueError("unknown request type")
|
266
278
|
|
267
279
|
|
268
|
-
def
|
269
|
-
|
270
|
-
|
271
|
-
|
272
|
-
|
273
|
-
"application/pickle",
|
274
|
-
]:
|
275
|
-
return SerializedObject(
|
276
|
-
bytes=response.content, content_type=response.headers["content-type"]
|
277
|
-
)
|
278
|
-
else:
|
279
|
-
return SerializedObject(
|
280
|
-
string=response.text, content_type=response.headers["content-type"]
|
280
|
+
def _serialized_object_from_http_response(response: httpx.Response) -> SerializedObject:
|
281
|
+
if response.headers["content-type"] != _VALUE_CONTENT_TYPE:
|
282
|
+
raise ValueError(
|
283
|
+
f"Unexpected content type: {response.headers['content-type']}. "
|
284
|
+
f"Expected: {_VALUE_CONTENT_TYPE}."
|
281
285
|
)
|
286
|
+
|
287
|
+
return SerializedObject(
|
288
|
+
data=response.content,
|
289
|
+
encoding=SerializedObjectEncoding.SERIALIZED_OBJECT_ENCODING_BINARY_PICKLE,
|
290
|
+
encoding_version=0,
|
291
|
+
)
|
@@ -66,6 +66,7 @@ def emit_completed_task_metrics(task_info: TaskInfo, logger: Any) -> None:
|
|
66
66
|
elif task_failure_reason in [
|
67
67
|
TaskFailureReason.TASK_FAILURE_REASON_FUNCTION_ERROR,
|
68
68
|
TaskFailureReason.TASK_FAILURE_REASON_FUNCTION_TIMEOUT,
|
69
|
+
TaskFailureReason.TASK_FAILURE_REASON_INVOCATION_ERROR,
|
69
70
|
]:
|
70
71
|
metric_tasks_completed.labels(
|
71
72
|
outcome_code=METRIC_TASKS_COMPLETED_OUTCOME_CODE_FAILURE,
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/downloads.py
RENAMED
@@ -4,7 +4,10 @@ from pathlib import Path
|
|
4
4
|
from typing import Any, Optional
|
5
5
|
|
6
6
|
import nanoid
|
7
|
-
from tensorlake.function_executor.proto.function_executor_pb2 import
|
7
|
+
from tensorlake.function_executor.proto.function_executor_pb2 import (
|
8
|
+
SerializedObject,
|
9
|
+
SerializedObjectEncoding,
|
10
|
+
)
|
8
11
|
|
9
12
|
from indexify.executor.blob_store.blob_store import BLOBStore
|
10
13
|
from indexify.proto.executor_api_pb2 import (
|
@@ -179,20 +182,28 @@ def _serialized_object_from_data_payload_proto(
|
|
179
182
|
"""
|
180
183
|
if data_payload.encoding == DataPayloadEncoding.DATA_PAYLOAD_ENCODING_BINARY_PICKLE:
|
181
184
|
return SerializedObject(
|
182
|
-
|
183
|
-
|
185
|
+
data=data,
|
186
|
+
encoding=SerializedObjectEncoding.SERIALIZED_OBJECT_ENCODING_BINARY_PICKLE,
|
187
|
+
encoding_version=data_payload.encoding_version,
|
184
188
|
)
|
185
189
|
elif data_payload.encoding == DataPayloadEncoding.DATA_PAYLOAD_ENCODING_UTF8_TEXT:
|
186
190
|
return SerializedObject(
|
187
|
-
|
188
|
-
|
191
|
+
data=data,
|
192
|
+
encoding=SerializedObjectEncoding.SERIALIZED_OBJECT_ENCODING_UTF8_TEXT,
|
193
|
+
encoding_version=data_payload.encoding_version,
|
189
194
|
)
|
190
195
|
elif data_payload.encoding == DataPayloadEncoding.DATA_PAYLOAD_ENCODING_UTF8_JSON:
|
191
|
-
|
192
|
-
|
193
|
-
|
196
|
+
return SerializedObject(
|
197
|
+
data=data,
|
198
|
+
encoding=SerializedObjectEncoding.SERIALIZED_OBJECT_ENCODING_UTF8_JSON,
|
199
|
+
encoding_version=data_payload.encoding_version,
|
200
|
+
)
|
201
|
+
elif data_payload.encoding == DataPayloadEncoding.DATA_PAYLOAD_ENCODING_BINARY_ZIP:
|
202
|
+
return SerializedObject(
|
203
|
+
data=data,
|
204
|
+
encoding=SerializedObjectEncoding.SERIALIZED_OBJECT_ENCODING_BINARY_ZIP,
|
205
|
+
encoding_version=data_payload.encoding_version,
|
194
206
|
)
|
195
|
-
return result
|
196
207
|
|
197
208
|
raise ValueError(
|
198
209
|
f"Can't convert data payload {data_payload} into serialized object"
|
@@ -197,7 +197,6 @@ class FunctionExecutorController:
|
|
197
197
|
task_info.is_cancelled = True
|
198
198
|
logger.info(
|
199
199
|
"cancelling task",
|
200
|
-
allocation_id=task_info.allocation.allocation_id,
|
201
200
|
)
|
202
201
|
if task_info.aio_task is not None:
|
203
202
|
task_info.aio_task.cancel()
|
@@ -332,7 +331,7 @@ class FunctionExecutorController:
|
|
332
331
|
self._logger.error(
|
333
332
|
"unexpected exception in function executor controller control loop",
|
334
333
|
exc_info=e,
|
335
|
-
|
334
|
+
event_type=event.event_type.name,
|
336
335
|
)
|
337
336
|
|
338
337
|
def _handle_event(self, event: BaseEvent) -> None:
|
@@ -786,16 +785,14 @@ def _to_task_result_proto(output: TaskOutput) -> TaskResult:
|
|
786
785
|
graph_invocation_id=output.allocation.task.graph_invocation_id,
|
787
786
|
reducer=output.reducer,
|
788
787
|
outcome_code=output.outcome_code,
|
789
|
-
|
788
|
+
failure_reason=output.failure_reason,
|
789
|
+
next_functions=output.next_functions,
|
790
790
|
function_outputs=output.uploaded_data_payloads,
|
791
|
+
invocation_error_output=output.uploaded_invocation_error_output,
|
791
792
|
)
|
792
|
-
if output.failure_reason is not None:
|
793
|
-
task_result.failure_reason = output.failure_reason
|
794
793
|
if output.uploaded_stdout is not None:
|
795
794
|
task_result.stdout.CopyFrom(output.uploaded_stdout)
|
796
795
|
if output.uploaded_stderr is not None:
|
797
796
|
task_result.stderr.CopyFrom(output.uploaded_stderr)
|
798
|
-
if output.router_output is not None:
|
799
|
-
task_result.routing.next_functions[:] = output.router_output.edges
|
800
797
|
|
801
798
|
return task_result
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/run_task.py
RENAMED
@@ -6,6 +6,13 @@ import grpc
|
|
6
6
|
from tensorlake.function_executor.proto.function_executor_pb2 import (
|
7
7
|
RunTaskRequest,
|
8
8
|
RunTaskResponse,
|
9
|
+
SerializedObject,
|
10
|
+
)
|
11
|
+
from tensorlake.function_executor.proto.function_executor_pb2 import (
|
12
|
+
TaskFailureReason as FETaskFailureReason,
|
13
|
+
)
|
14
|
+
from tensorlake.function_executor.proto.function_executor_pb2 import (
|
15
|
+
TaskOutcomeCode as FETaskOutcomeCode,
|
9
16
|
)
|
10
17
|
from tensorlake.function_executor.proto.function_executor_pb2_grpc import (
|
11
18
|
FunctionExecutorStub,
|
@@ -83,6 +90,7 @@ async def run_task_on_function_executor(
|
|
83
90
|
task_info.output = _task_output_from_function_executor_response(
|
84
91
|
allocation=task_info.allocation,
|
85
92
|
response=response,
|
93
|
+
logger=logger,
|
86
94
|
)
|
87
95
|
except grpc.aio.AioRpcError as e:
|
88
96
|
if e.code() == grpc.StatusCode.DEADLINE_EXCEEDED:
|
@@ -140,13 +148,13 @@ async def run_task_on_function_executor(
|
|
140
148
|
|
141
149
|
|
142
150
|
def _task_output_from_function_executor_response(
|
143
|
-
allocation: TaskAllocation, response: RunTaskResponse
|
151
|
+
allocation: TaskAllocation, response: RunTaskResponse, logger: Any
|
144
152
|
) -> TaskOutput:
|
145
153
|
response_validator = MessageValidator(response)
|
146
154
|
response_validator.required_field("stdout")
|
147
155
|
response_validator.required_field("stderr")
|
148
156
|
response_validator.required_field("is_reducer")
|
149
|
-
response_validator.required_field("
|
157
|
+
response_validator.required_field("outcome_code")
|
150
158
|
|
151
159
|
metrics = TaskMetrics(counters={}, timers={})
|
152
160
|
if response.HasField("metrics"):
|
@@ -154,31 +162,34 @@ def _task_output_from_function_executor_response(
|
|
154
162
|
metrics.counters = dict(response.metrics.counters)
|
155
163
|
metrics.timers = dict(response.metrics.timers)
|
156
164
|
|
157
|
-
|
165
|
+
outcome_code: TaskOutcomeCode = _to_task_outcome_code(
|
166
|
+
response.outcome_code, logger=logger
|
167
|
+
)
|
168
|
+
failure_reason: Optional[TaskFailureReason] = None
|
169
|
+
invocation_error_output: Optional[SerializedObject] = None
|
170
|
+
|
171
|
+
if outcome_code == TaskOutcomeCode.TASK_OUTCOME_CODE_FAILURE:
|
172
|
+
response_validator.required_field("failure_reason")
|
173
|
+
failure_reason: Optional[TaskFailureReason] = _to_task_failure_reason(
|
174
|
+
response.failure_reason, logger
|
175
|
+
)
|
176
|
+
if failure_reason == TaskFailureReason.TASK_FAILURE_REASON_INVOCATION_ERROR:
|
177
|
+
response_validator.required_field("invocation_error_output")
|
178
|
+
invocation_error_output = response.invocation_error_output
|
179
|
+
|
180
|
+
return TaskOutput(
|
158
181
|
allocation=allocation,
|
159
|
-
outcome_code=
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
failure_reason=(
|
165
|
-
None
|
166
|
-
if response.success
|
167
|
-
else TaskFailureReason.TASK_FAILURE_REASON_FUNCTION_ERROR
|
168
|
-
),
|
182
|
+
outcome_code=outcome_code,
|
183
|
+
failure_reason=failure_reason,
|
184
|
+
invocation_error_output=invocation_error_output,
|
185
|
+
function_outputs=response.function_outputs,
|
186
|
+
next_functions=response.next_functions,
|
169
187
|
stdout=response.stdout,
|
170
188
|
stderr=response.stderr,
|
171
189
|
reducer=response.is_reducer,
|
172
190
|
metrics=metrics,
|
173
191
|
)
|
174
192
|
|
175
|
-
if response.HasField("function_output"):
|
176
|
-
output.function_output = response.function_output
|
177
|
-
if response.HasField("router_output"):
|
178
|
-
output.router_output = response.router_output
|
179
|
-
|
180
|
-
return output
|
181
|
-
|
182
193
|
|
183
194
|
def _log_task_execution_finished(output: TaskOutput, logger: Any) -> None:
|
184
195
|
logger.info(
|
@@ -191,3 +202,40 @@ def _log_task_execution_finished(output: TaskOutput, logger: Any) -> None:
|
|
191
202
|
else None
|
192
203
|
),
|
193
204
|
)
|
205
|
+
|
206
|
+
|
207
|
+
def _to_task_outcome_code(
|
208
|
+
fe_task_outcome_code: FETaskOutcomeCode, logger
|
209
|
+
) -> TaskOutcomeCode:
|
210
|
+
if fe_task_outcome_code == FETaskOutcomeCode.TASK_OUTCOME_CODE_SUCCESS:
|
211
|
+
return TaskOutcomeCode.TASK_OUTCOME_CODE_SUCCESS
|
212
|
+
elif fe_task_outcome_code == FETaskOutcomeCode.TASK_OUTCOME_CODE_FAILURE:
|
213
|
+
return TaskOutcomeCode.TASK_OUTCOME_CODE_FAILURE
|
214
|
+
else:
|
215
|
+
logger.warning(
|
216
|
+
"Unknown TaskOutcomeCode received from Function Executor",
|
217
|
+
value=FETaskOutcomeCode.Name(fe_task_outcome_code),
|
218
|
+
)
|
219
|
+
return TaskOutcomeCode.TASK_OUTCOME_CODE_UNKNOWN
|
220
|
+
|
221
|
+
|
222
|
+
def _to_task_failure_reason(
|
223
|
+
fe_task_failure_reason: FETaskFailureReason, logger: Any
|
224
|
+
) -> TaskFailureReason:
|
225
|
+
if fe_task_failure_reason == FETaskFailureReason.TASK_FAILURE_REASON_FUNCTION_ERROR:
|
226
|
+
return TaskFailureReason.TASK_FAILURE_REASON_FUNCTION_ERROR
|
227
|
+
elif (
|
228
|
+
fe_task_failure_reason
|
229
|
+
== FETaskFailureReason.TASK_FAILURE_REASON_INVOCATION_ERROR
|
230
|
+
):
|
231
|
+
return TaskFailureReason.TASK_FAILURE_REASON_INVOCATION_ERROR
|
232
|
+
elif (
|
233
|
+
fe_task_failure_reason == FETaskFailureReason.TASK_FAILURE_REASON_INTERNAL_ERROR
|
234
|
+
):
|
235
|
+
return TaskFailureReason.TASK_FAILURE_REASON_INTERNAL_ERROR
|
236
|
+
else:
|
237
|
+
logger.warning(
|
238
|
+
"Unknown TaskFailureReason received from Function Executor",
|
239
|
+
value=FETaskFailureReason.Name(fe_task_failure_reason),
|
240
|
+
)
|
241
|
+
return TaskFailureReason.TASK_FAILURE_REASON_UNKNOWN
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/task_output.py
RENAMED
@@ -1,8 +1,7 @@
|
|
1
1
|
from typing import Dict, List, Optional
|
2
2
|
|
3
3
|
from tensorlake.function_executor.proto.function_executor_pb2 import (
|
4
|
-
|
5
|
-
RouterOutput,
|
4
|
+
SerializedObject,
|
6
5
|
)
|
7
6
|
|
8
7
|
from indexify.proto.executor_api_pb2 import (
|
@@ -30,31 +29,29 @@ class TaskOutput:
|
|
30
29
|
outcome_code: TaskOutcomeCode,
|
31
30
|
# Optional[TaskFailureReason] is not supported in python 3.9
|
32
31
|
failure_reason: TaskFailureReason = None,
|
33
|
-
|
34
|
-
|
35
|
-
|
32
|
+
invocation_error_output: Optional[SerializedObject] = None,
|
33
|
+
function_outputs: List[SerializedObject] = [],
|
34
|
+
next_functions: List[str] = [],
|
36
35
|
stdout: Optional[str] = None,
|
37
36
|
stderr: Optional[str] = None,
|
38
37
|
reducer: bool = False,
|
39
38
|
metrics: Optional[TaskMetrics] = None,
|
40
|
-
uploaded_data_payloads: List[DataPayload] = [],
|
41
|
-
uploaded_stdout: Optional[DataPayload] = None,
|
42
|
-
uploaded_stderr: Optional[DataPayload] = None,
|
43
39
|
):
|
44
40
|
self.task = allocation.task
|
45
41
|
self.allocation = allocation
|
46
|
-
self.
|
47
|
-
self.
|
42
|
+
self.function_outputs = function_outputs
|
43
|
+
self.next_functions = next_functions
|
48
44
|
self.stdout = stdout
|
49
45
|
self.stderr = stderr
|
50
46
|
self.reducer = reducer
|
51
47
|
self.outcome_code = outcome_code
|
52
48
|
self.failure_reason = failure_reason
|
49
|
+
self.invocation_error_output = invocation_error_output
|
53
50
|
self.metrics = metrics
|
54
|
-
self.
|
55
|
-
self.
|
56
|
-
self.
|
57
|
-
self.
|
51
|
+
self.uploaded_data_payloads: List[DataPayload] = []
|
52
|
+
self.uploaded_stdout: Optional[DataPayload] = None
|
53
|
+
self.uploaded_stderr: Optional[DataPayload] = None
|
54
|
+
self.uploaded_invocation_error_output: Optional[DataPayload] = None
|
58
55
|
|
59
56
|
@classmethod
|
60
57
|
def internal_error(
|
@@ -1,7 +1,12 @@
|
|
1
1
|
import asyncio
|
2
2
|
import hashlib
|
3
3
|
import time
|
4
|
-
from typing import Any
|
4
|
+
from typing import Any, List
|
5
|
+
|
6
|
+
from tensorlake.function_executor.proto.function_executor_pb2 import (
|
7
|
+
SerializedObject,
|
8
|
+
SerializedObjectEncoding,
|
9
|
+
)
|
5
10
|
|
6
11
|
from indexify.executor.blob_store.blob_store import BLOBStore
|
7
12
|
from indexify.proto.executor_api_pb2 import (
|
@@ -74,11 +79,13 @@ class _TaskOutputSummary:
|
|
74
79
|
def __init__(self):
|
75
80
|
self.output_count: int = 0
|
76
81
|
self.output_total_bytes: int = 0
|
77
|
-
self.
|
82
|
+
self.next_functions_count: int = 0
|
78
83
|
self.stdout_count: int = 0
|
79
84
|
self.stdout_total_bytes: int = 0
|
80
85
|
self.stderr_count: int = 0
|
81
86
|
self.stderr_total_bytes: int = 0
|
87
|
+
self.invocation_error_output_count: int = 0
|
88
|
+
self.invocation_error_output_total_bytes: int = 0
|
82
89
|
self.total_bytes: int = 0
|
83
90
|
|
84
91
|
|
@@ -95,12 +102,14 @@ async def _upload_task_output_once(
|
|
95
102
|
total_bytes=output_summary.total_bytes,
|
96
103
|
total_files=output_summary.output_count
|
97
104
|
+ output_summary.stdout_count
|
98
|
-
+ output_summary.stderr_count
|
105
|
+
+ output_summary.stderr_count
|
106
|
+
+ output_summary.invocation_error_output_count,
|
99
107
|
output_files=output_summary.output_count,
|
100
108
|
output_bytes=output_summary.total_bytes,
|
101
|
-
|
109
|
+
next_functions_count=output_summary.next_functions_count,
|
102
110
|
stdout_bytes=output_summary.stdout_total_bytes,
|
103
111
|
stderr_bytes=output_summary.stderr_total_bytes,
|
112
|
+
invocation_error_output_bytes=output_summary.invocation_error_output_total_bytes,
|
104
113
|
)
|
105
114
|
|
106
115
|
start_time = time.time()
|
@@ -109,7 +118,9 @@ async def _upload_task_output_once(
|
|
109
118
|
metric_task_output_blob_store_upload_errors.count_exceptions(),
|
110
119
|
):
|
111
120
|
metric_task_output_blob_store_uploads.inc()
|
112
|
-
await _upload_to_blob_store(
|
121
|
+
await _upload_to_blob_store(
|
122
|
+
task_output=output, blob_store=blob_store, logger=logger
|
123
|
+
)
|
113
124
|
|
114
125
|
logger.info(
|
115
126
|
"files uploaded to blob store",
|
@@ -118,86 +129,105 @@ async def _upload_task_output_once(
|
|
118
129
|
|
119
130
|
|
120
131
|
async def _upload_to_blob_store(
|
121
|
-
|
132
|
+
task_output: TaskOutput, blob_store: BLOBStore, logger: Any
|
122
133
|
) -> None:
|
123
|
-
if
|
124
|
-
stdout_url = f"{
|
125
|
-
stdout_bytes: bytes =
|
134
|
+
if task_output.stdout is not None:
|
135
|
+
stdout_url = f"{task_output.allocation.task.output_payload_uri_prefix}.{task_output.allocation.task.id}.stdout"
|
136
|
+
stdout_bytes: bytes = task_output.stdout.encode()
|
126
137
|
await blob_store.put(stdout_url, stdout_bytes, logger)
|
127
|
-
|
138
|
+
task_output.uploaded_stdout = DataPayload(
|
128
139
|
uri=stdout_url,
|
129
140
|
size=len(stdout_bytes),
|
130
141
|
sha256_hash=compute_hash(stdout_bytes),
|
131
142
|
encoding=DataPayloadEncoding.DATA_PAYLOAD_ENCODING_UTF8_TEXT,
|
132
143
|
encoding_version=0,
|
133
144
|
)
|
134
|
-
# stdout is uploaded, free the memory used for it.
|
135
|
-
|
145
|
+
# stdout is uploaded, free the memory used for it and don't upload again if we retry overall output upload again.
|
146
|
+
task_output.stdout = None
|
136
147
|
|
137
|
-
if
|
138
|
-
stderr_url = f"{
|
139
|
-
stderr_bytes: bytes =
|
148
|
+
if task_output.stderr is not None:
|
149
|
+
stderr_url = f"{task_output.allocation.task.output_payload_uri_prefix}.{task_output.allocation.task.id}.stderr"
|
150
|
+
stderr_bytes: bytes = task_output.stderr.encode()
|
140
151
|
await blob_store.put(stderr_url, stderr_bytes, logger)
|
141
|
-
|
152
|
+
task_output.uploaded_stderr = DataPayload(
|
142
153
|
uri=stderr_url,
|
143
154
|
size=len(stderr_bytes),
|
144
155
|
sha256_hash=compute_hash(stderr_bytes),
|
145
156
|
encoding=DataPayloadEncoding.DATA_PAYLOAD_ENCODING_UTF8_TEXT,
|
146
157
|
encoding_version=0,
|
147
158
|
)
|
148
|
-
# stderr is uploaded, free the memory used for it.
|
149
|
-
|
150
|
-
|
151
|
-
if
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
159
|
+
# stderr is uploaded, free the memory used for it and don't upload again if we retry overall output upload again.
|
160
|
+
task_output.stderr = None
|
161
|
+
|
162
|
+
if task_output.invocation_error_output is not None:
|
163
|
+
invocation_error_output_url = (
|
164
|
+
f"{task_output.allocation.task.output_payload_uri_prefix}.inverr."
|
165
|
+
f"{task_output.allocation.task.graph_invocation_id}"
|
166
|
+
)
|
167
|
+
invocation_error_output_bytes: bytes = task_output.invocation_error_output.data
|
168
|
+
await blob_store.put(
|
169
|
+
invocation_error_output_url, invocation_error_output_bytes, logger
|
170
|
+
)
|
171
|
+
task_output.uploaded_invocation_error_output = DataPayload(
|
172
|
+
uri=invocation_error_output_url,
|
173
|
+
size=len(invocation_error_output_bytes),
|
174
|
+
sha256_hash=compute_hash(invocation_error_output_bytes),
|
175
|
+
encoding=_to_grpc_data_payload_encoding(
|
176
|
+
task_output.invocation_error_output.encoding, logger
|
177
|
+
),
|
178
|
+
encoding_version=0,
|
179
|
+
)
|
180
|
+
# Invocation error output is uploaded, free the memory used for it and don't upload again if we retry overall output upload again.
|
181
|
+
task_output.invocation_error_output = None
|
182
|
+
|
183
|
+
# We can't use the default empty list output.uploaded_data_payloads because it's a singleton.
|
184
|
+
uploaded_data_payloads: List[DataPayload] = []
|
185
|
+
for output in task_output.function_outputs:
|
186
|
+
output: SerializedObject
|
187
|
+
output_ix: int = len(uploaded_data_payloads)
|
188
|
+
output_url: str = (
|
189
|
+
f"{task_output.allocation.task.output_payload_uri_prefix}.{task_output.allocation.task.id}.{output_ix}"
|
190
|
+
)
|
191
|
+
await blob_store.put(output_url, output.data, logger)
|
192
|
+
uploaded_data_payloads.append(
|
193
|
+
DataPayload(
|
194
|
+
uri=output_url,
|
195
|
+
size=len(output.data),
|
196
|
+
sha256_hash=compute_hash(output.data),
|
197
|
+
encoding=_to_grpc_data_payload_encoding(output.encoding, logger),
|
198
|
+
encoding_version=0,
|
171
199
|
)
|
200
|
+
)
|
172
201
|
|
173
|
-
|
174
|
-
|
175
|
-
|
202
|
+
task_output.uploaded_data_payloads = uploaded_data_payloads
|
203
|
+
# The output is uploaded, free the memory used for it and don't upload again if we retry overall output upload again.
|
204
|
+
task_output.function_outputs = []
|
176
205
|
|
177
206
|
|
178
|
-
def _task_output_summary(
|
207
|
+
def _task_output_summary(task_output: TaskOutput) -> _TaskOutputSummary:
|
179
208
|
summary: _TaskOutputSummary = _TaskOutputSummary()
|
180
209
|
|
181
|
-
if
|
210
|
+
if task_output.stdout is not None:
|
182
211
|
summary.stdout_count += 1
|
183
|
-
summary.stdout_total_bytes += len(
|
212
|
+
summary.stdout_total_bytes += len(task_output.stdout)
|
184
213
|
|
185
|
-
if
|
214
|
+
if task_output.stderr is not None:
|
186
215
|
summary.stderr_count += 1
|
187
|
-
summary.stderr_total_bytes += len(
|
188
|
-
|
189
|
-
if
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
else func_output_item.string
|
195
|
-
)
|
196
|
-
summary.output_count += 1
|
197
|
-
summary.output_total_bytes += output_len
|
216
|
+
summary.stderr_total_bytes += len(task_output.stderr)
|
217
|
+
|
218
|
+
if task_output.invocation_error_output is not None:
|
219
|
+
summary.invocation_error_output_count += 1
|
220
|
+
summary.invocation_error_output_total_bytes += len(
|
221
|
+
task_output.invocation_error_output.data
|
222
|
+
)
|
198
223
|
|
199
|
-
|
200
|
-
|
224
|
+
for output in task_output.function_outputs:
|
225
|
+
output: SerializedObject
|
226
|
+
output_len: bytes = len(output.data)
|
227
|
+
summary.output_count += 1
|
228
|
+
summary.output_total_bytes += output_len
|
229
|
+
|
230
|
+
summary.next_functions_count = len(task_output.next_functions)
|
201
231
|
|
202
232
|
summary.total_bytes = (
|
203
233
|
summary.output_total_bytes
|
@@ -207,11 +237,21 @@ def _task_output_summary(output: TaskOutput) -> _TaskOutputSummary:
|
|
207
237
|
return summary
|
208
238
|
|
209
239
|
|
210
|
-
def _to_grpc_data_payload_encoding(
|
211
|
-
|
240
|
+
def _to_grpc_data_payload_encoding(
|
241
|
+
encoding: SerializedObjectEncoding, logger: Any
|
242
|
+
) -> DataPayloadEncoding:
|
243
|
+
if encoding == SerializedObjectEncoding.SERIALIZED_OBJECT_ENCODING_BINARY_PICKLE:
|
244
|
+
return DataPayloadEncoding.DATA_PAYLOAD_ENCODING_BINARY_PICKLE
|
245
|
+
elif encoding == SerializedObjectEncoding.SERIALIZED_OBJECT_ENCODING_UTF8_JSON:
|
212
246
|
return DataPayloadEncoding.DATA_PAYLOAD_ENCODING_UTF8_JSON
|
247
|
+
elif encoding == SerializedObjectEncoding.SERIALIZED_OBJECT_ENCODING_UTF8_TEXT:
|
248
|
+
return DataPayloadEncoding.DATA_PAYLOAD_ENCODING_UTF8_TEXT
|
213
249
|
else:
|
214
|
-
|
250
|
+
logger.error(
|
251
|
+
"Unexpected encoding for SerializedObject",
|
252
|
+
encoding=SerializedObjectEncoding.Name(encoding),
|
253
|
+
)
|
254
|
+
return DataPayloadEncoding.DATA_PAYLOAD_ENCODING_UNKNOWN
|
215
255
|
|
216
256
|
|
217
257
|
def compute_hash(data: bytes) -> str:
|
@@ -7,11 +7,10 @@ package executor_api_pb;
|
|
7
7
|
// ===== DataPayload =====
|
8
8
|
enum DataPayloadEncoding {
|
9
9
|
DATA_PAYLOAD_ENCODING_UNKNOWN = 0;
|
10
|
-
// These encodings are currently mapping 1:1 to mime types.
|
11
|
-
// TODO: use SDK specific encodings becase 1:1 mapping might not work in the future.
|
12
10
|
DATA_PAYLOAD_ENCODING_UTF8_JSON = 1;
|
13
11
|
DATA_PAYLOAD_ENCODING_UTF8_TEXT = 2;
|
14
12
|
DATA_PAYLOAD_ENCODING_BINARY_PICKLE = 3;
|
13
|
+
DATA_PAYLOAD_ENCODING_BINARY_ZIP = 4;
|
15
14
|
}
|
16
15
|
|
17
16
|
message DataPayload {
|
@@ -62,28 +61,38 @@ message AllowedFunction {
|
|
62
61
|
|
63
62
|
enum FunctionExecutorStatus {
|
64
63
|
FUNCTION_EXECUTOR_STATUS_UNKNOWN = 0;
|
65
|
-
//
|
64
|
+
// FE is being created.
|
66
65
|
FUNCTION_EXECUTOR_STATUS_PENDING = 1;
|
67
|
-
//
|
66
|
+
// FE is running and ready to accept tasks.
|
68
67
|
FUNCTION_EXECUTOR_STATUS_RUNNING = 2;
|
69
|
-
//
|
68
|
+
// FE is terminated, all resources are freed.
|
70
69
|
FUNCTION_EXECUTOR_STATUS_TERMINATED = 3;
|
71
70
|
}
|
72
71
|
|
73
72
|
enum FunctionExecutorTerminationReason {
|
74
73
|
FUNCTION_EXECUTOR_TERMINATION_REASON_UNKNOWN = 0;
|
74
|
+
// Internal error aka platform error on FE startup.
|
75
75
|
FUNCTION_EXECUTOR_TERMINATION_REASON_STARTUP_FAILED_INTERNAL_ERROR = 1;
|
76
|
+
// A clear function constructor code error on FE startup.
|
77
|
+
// Typically an exception raised from the constructor.
|
76
78
|
FUNCTION_EXECUTOR_TERMINATION_REASON_STARTUP_FAILED_FUNCTION_ERROR = 2;
|
77
79
|
// Timeout on FE startup while running the function constructor.
|
78
80
|
FUNCTION_EXECUTOR_TERMINATION_REASON_STARTUP_FAILED_FUNCTION_TIMEOUT = 3;
|
79
81
|
|
82
|
+
// FE was terminated on Executor shutdown.
|
80
83
|
FUNCTION_EXECUTOR_TERMINATION_REASON_EXECUTOR_SHUTDOWN = 10;
|
84
|
+
// FE was removed from the Executor desired state by Server.
|
81
85
|
FUNCTION_EXECUTOR_TERMINATION_REASON_REMOVED_FROM_DESIRED_STATE = 11;
|
86
|
+
// FE was terminated because it failed a health check.
|
82
87
|
FUNCTION_EXECUTOR_TERMINATION_REASON_UNHEALTHY = 12;
|
88
|
+
// FE was terminated due to an unrecoverable internal error on Executor.
|
83
89
|
FUNCTION_EXECUTOR_TERMINATION_REASON_INTERNAL_ERROR = 13;
|
84
|
-
//
|
90
|
+
// FE was terminated because Function code exceeded its cofigured timeout.
|
91
|
+
// FE termination is the only way to reliably stop the function code execution.
|
85
92
|
FUNCTION_EXECUTOR_TERMINATION_REASON_FUNCTION_TIMEOUT = 14;
|
86
|
-
//
|
93
|
+
// FE was terminated because function allocation currently running on it was removed
|
94
|
+
// from Executor desired state.
|
95
|
+
// FE termination is the only way to reliably stop the function code execution.
|
87
96
|
FUNCTION_EXECUTOR_TERMINATION_REASON_FUNCTION_CANCELLED = 15;
|
88
97
|
}
|
89
98
|
|
@@ -129,9 +138,13 @@ message FunctionExecutorUpdate {
|
|
129
138
|
|
130
139
|
enum ExecutorStatus {
|
131
140
|
EXECUTOR_STATUS_UNKNOWN = 0;
|
141
|
+
// Executor is starting up, not ready to accept task allocations and FEs.
|
132
142
|
EXECUTOR_STATUS_STARTING_UP = 1;
|
143
|
+
// Executor is ready to accept task allocations and FEs.
|
133
144
|
EXECUTOR_STATUS_RUNNING = 2;
|
145
|
+
// No new task allocations or FEs should be places on the Executor.
|
134
146
|
EXECUTOR_STATUS_DRAINED = 3;
|
147
|
+
// Executor is stopped, all resources are freed, all FEs are terminated.
|
135
148
|
EXECUTOR_STATUS_STOPPED = 4;
|
136
149
|
}
|
137
150
|
|
@@ -228,17 +241,19 @@ enum TaskOutcomeCode {
|
|
228
241
|
|
229
242
|
enum TaskFailureReason {
|
230
243
|
TASK_FAILURE_REASON_UNKNOWN = 0;
|
244
|
+
// Internal error on Executor aka platform error.
|
245
|
+
// Includes grey failures when we can't determine the exact cause.
|
231
246
|
TASK_FAILURE_REASON_INTERNAL_ERROR = 1;
|
247
|
+
// Clear function code failure typically by raising an exception from the function code.
|
232
248
|
TASK_FAILURE_REASON_FUNCTION_ERROR = 2;
|
249
|
+
// Function code run time exceeded its cofigured timeout.
|
233
250
|
TASK_FAILURE_REASON_FUNCTION_TIMEOUT = 3;
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
|
240
|
-
// NB: An empty list indicates that no routing should be performed.
|
241
|
-
repeated string next_functions = 1;
|
251
|
+
// Function code raised InvocationError to mark the invocation as permanently failed.
|
252
|
+
TASK_FAILURE_REASON_INVOCATION_ERROR = 4;
|
253
|
+
// Server removed the task allocation from Executor desired state. The task allocation didn't finish before the removal.
|
254
|
+
TASK_FAILURE_REASON_TASK_CANCELLED = 5;
|
255
|
+
// Function Executor terminated - can't run the task allocation on it anymore.
|
256
|
+
TASK_FAILURE_REASON_FUNCTION_EXECUTOR_TERMINATED = 6;
|
242
257
|
}
|
243
258
|
|
244
259
|
message TaskResult {
|
@@ -253,24 +268,13 @@ message TaskResult {
|
|
253
268
|
optional TaskOutcomeCode outcome_code = 9;
|
254
269
|
optional TaskFailureReason failure_reason = 10;
|
255
270
|
// Edges that the function wants the invocation to be routed to.
|
256
|
-
// Previously called router_edges.
|
257
|
-
// NB: An empty list indicates that the graph's route definitions should be used,
|
258
|
-
// unless this field is overridden by the presence of the `routing` field.
|
259
271
|
repeated string next_functions = 11;
|
260
272
|
repeated DataPayload function_outputs = 12;
|
261
273
|
// Standard output and error streams of the function.
|
262
274
|
optional DataPayload stdout = 13;
|
263
275
|
optional DataPayload stderr = 14;
|
264
|
-
|
265
|
-
|
266
|
-
// If this is present, it replaces `next_functions`.
|
267
|
-
//
|
268
|
-
// If absent, `next_functions` will be used; note that if no
|
269
|
-
// routes are defined in `next_functions`, this will use the
|
270
|
-
// graph's routing. The long-term goal is to deprecate
|
271
|
-
// `next_functions`, so that if `routing` is not present, the
|
272
|
-
// graph's routing definitions will always be used.
|
273
|
-
ResultRouting routing = 15;
|
276
|
+
// User payload for invocation error if task failed with invocation error.
|
277
|
+
optional DataPayload invocation_error_output = 15;
|
274
278
|
}
|
275
279
|
|
276
280
|
// Internal API for scheduling and running tasks on Executors. Executors are acting as clients of this API.
|
@@ -19,7 +19,7 @@ _sym_db = _symbol_database.Default()
|
|
19
19
|
|
20
20
|
|
21
21
|
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(
|
22
|
-
b'\n!indexify/proto/executor_api.proto\x12\x0f\x65xecutor_api_pb"\xeb\x01\n\x0b\x44\x61taPayload\x12\x11\n\x04size\x18\x02 \x01(\x04H\x00\x88\x01\x01\x12\x18\n\x0bsha256_hash\x18\x03 \x01(\tH\x01\x88\x01\x01\x12\x10\n\x03uri\x18\x04 \x01(\tH\x02\x88\x01\x01\x12;\n\x08\x65ncoding\x18\x05 \x01(\x0e\x32$.executor_api_pb.DataPayloadEncodingH\x03\x88\x01\x01\x12\x1d\n\x10\x65ncoding_version\x18\x06 \x01(\x04H\x04\x88\x01\x01\x42\x07\n\x05_sizeB\x0e\n\x0c_sha256_hashB\x06\n\x04_uriB\x0b\n\t_encodingB\x13\n\x11_encoding_version"e\n\x0cGPUResources\x12\x12\n\x05\x63ount\x18\x01 \x01(\rH\x00\x88\x01\x01\x12-\n\x05model\x18\x02 \x01(\x0e\x32\x19.executor_api_pb.GPUModelH\x01\x88\x01\x01\x42\x08\n\x06_countB\x08\n\x06_model"\xc2\x01\n\rHostResources\x12\x16\n\tcpu_count\x18\x01 \x01(\rH\x00\x88\x01\x01\x12\x19\n\x0cmemory_bytes\x18\x02 \x01(\x04H\x01\x88\x01\x01\x12\x17\n\ndisk_bytes\x18\x03 \x01(\x04H\x02\x88\x01\x01\x12/\n\x03gpu\x18\x04 \x01(\x0b\x32\x1d.executor_api_pb.GPUResourcesH\x03\x88\x01\x01\x42\x0c\n\n_cpu_countB\x0f\n\r_memory_bytesB\r\n\x0b_disk_bytesB\x06\n\x04_gpu"\xbb\x01\n\x0f\x41llowedFunction\x12\x16\n\tnamespace\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x17\n\ngraph_name\x18\x02 \x01(\tH\x01\x88\x01\x01\x12\x1a\n\rfunction_name\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x1a\n\rgraph_version\x18\x04 \x01(\tH\x03\x88\x01\x01\x42\x0c\n\n_namespaceB\r\n\x0b_graph_nameB\x10\n\x0e_function_nameB\x10\n\x0e_graph_version"\xd8\x01\n\x19\x46unctionExecutorResources\x12\x1b\n\x0e\x63pu_ms_per_sec\x18\x01 \x01(\rH\x00\x88\x01\x01\x12\x19\n\x0cmemory_bytes\x18\x02 \x01(\x04H\x01\x88\x01\x01\x12\x17\n\ndisk_bytes\x18\x03 \x01(\x04H\x02\x88\x01\x01\x12/\n\x03gpu\x18\x04 \x01(\x0b\x32\x1d.executor_api_pb.GPUResourcesH\x03\x88\x01\x01\x42\x11\n\x0f_cpu_ms_per_secB\x0f\n\r_memory_bytesB\r\n\x0b_disk_bytesB\x06\n\x04_gpu"\xb3\x04\n\x1b\x46unctionExecutorDescription\x12\x0f\n\x02id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x16\n\tnamespace\x18\x02 \x01(\tH\x01\x88\x01\x01\x12\x17\n\ngraph_name\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x1a\n\rgraph_version\x18\x04 \x01(\tH\x03\x88\x01\x01\x12\x1a\n\rfunction_name\x18\x05 \x01(\tH\x04\x88\x01\x01\x12\x16\n\timage_uri\x18\x06 \x01(\tH\x05\x88\x01\x01\x12\x14\n\x0csecret_names\x18\x07 \x03(\t\x12%\n\x18\x63ustomer_code_timeout_ms\x18\t \x01(\rH\x06\x88\x01\x01\x12\x30\n\x05graph\x18\n \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x07\x88\x01\x01\x12\x42\n\tresources\x18\x0b \x01(\x0b\x32*.executor_api_pb.FunctionExecutorResourcesH\x08\x88\x01\x01\x12&\n\x19output_payload_uri_prefix\x18\x0c \x01(\tH\t\x88\x01\x01\x42\x05\n\x03_idB\x0c\n\n_namespaceB\r\n\x0b_graph_nameB\x10\n\x0e_graph_versionB\x10\n\x0e_function_nameB\x0c\n\n_image_uriB\x1b\n\x19_customer_code_timeout_msB\x08\n\x06_graphB\x0c\n\n_resourcesB\x1c\n\x1a_output_payload_uri_prefix"\xa4\x02\n\x15\x46unctionExecutorState\x12\x46\n\x0b\x64\x65scription\x18\x01 \x01(\x0b\x32,.executor_api_pb.FunctionExecutorDescriptionH\x00\x88\x01\x01\x12<\n\x06status\x18\x02 \x01(\x0e\x32\'.executor_api_pb.FunctionExecutorStatusH\x01\x88\x01\x01\x12S\n\x12termination_reason\x18\x03 \x01(\x0e\x32\x32.executor_api_pb.FunctionExecutorTerminationReasonH\x02\x88\x01\x01\x42\x0e\n\x0c_descriptionB\t\n\x07_statusB\x15\n\x13_termination_reason"\x8c\x02\n\x16\x46unctionExecutorUpdate\x12\x46\n\x0b\x64\x65scription\x18\x01 \x01(\x0b\x32,.executor_api_pb.FunctionExecutorDescriptionH\x00\x88\x01\x01\x12\x39\n\x0estartup_stdout\x18\x02 \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x01\x88\x01\x01\x12\x39\n\x0estartup_stderr\x18\x03 \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x02\x88\x01\x01\x42\x0e\n\x0c_descriptionB\x11\n\x0f_startup_stdoutB\x11\n\x0f_startup_stderr"\xce\x05\n\rExecutorState\x12\x18\n\x0b\x65xecutor_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x15\n\x08hostname\x18\x03 \x01(\tH\x01\x88\x01\x01\x12\x14\n\x07version\x18\x05 \x01(\tH\x02\x88\x01\x01\x12\x34\n\x06status\x18\x06 \x01(\x0e\x32\x1f.executor_api_pb.ExecutorStatusH\x03\x88\x01\x01\x12<\n\x0ftotal_resources\x18\r \x01(\x0b\x32\x1e.executor_api_pb.HostResourcesH\x04\x88\x01\x01\x12N\n!total_function_executor_resources\x18\x07 \x01(\x0b\x32\x1e.executor_api_pb.HostResourcesH\x05\x88\x01\x01\x12;\n\x11\x61llowed_functions\x18\x08 \x03(\x0b\x32 .executor_api_pb.AllowedFunction\x12H\n\x18\x66unction_executor_states\x18\t \x03(\x0b\x32&.executor_api_pb.FunctionExecutorState\x12:\n\x06labels\x18\n \x03(\x0b\x32*.executor_api_pb.ExecutorState.LabelsEntry\x12\x17\n\nstate_hash\x18\x0b \x01(\tH\x06\x88\x01\x01\x12\x19\n\x0cserver_clock\x18\x0c \x01(\x04H\x07\x88\x01\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x42\x0e\n\x0c_executor_idB\x0b\n\t_hostnameB\n\n\x08_versionB\t\n\x07_statusB\x12\n\x10_total_resourcesB$\n"_total_function_executor_resourcesB\r\n\x0b_state_hashB\x0f\n\r_server_clock"\xb9\x01\n\x0e\x45xecutorUpdate\x12\x18\n\x0b\x65xecutor_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x31\n\x0ctask_results\x18\x02 \x03(\x0b\x32\x1b.executor_api_pb.TaskResult\x12J\n\x19\x66unction_executor_updates\x18\x03 \x03(\x0b\x32\'.executor_api_pb.FunctionExecutorUpdateB\x0e\n\x0c_executor_id"\xbf\x01\n\x1aReportExecutorStateRequest\x12;\n\x0e\x65xecutor_state\x18\x01 \x01(\x0b\x32\x1e.executor_api_pb.ExecutorStateH\x00\x88\x01\x01\x12=\n\x0f\x65xecutor_update\x18\x02 \x01(\x0b\x32\x1f.executor_api_pb.ExecutorUpdateH\x01\x88\x01\x01\x42\x11\n\x0f_executor_stateB\x12\n\x10_executor_update"\x1d\n\x1bReportExecutorStateResponse"\xcf\x01\n\x0fTaskRetryPolicy\x12\x18\n\x0bmax_retries\x18\x01 \x01(\rH\x00\x88\x01\x01\x12\x1d\n\x10initial_delay_ms\x18\x02 \x01(\rH\x01\x88\x01\x01\x12\x19\n\x0cmax_delay_ms\x18\x03 \x01(\rH\x02\x88\x01\x01\x12\x1d\n\x10\x64\x65lay_multiplier\x18\x04 \x01(\rH\x03\x88\x01\x01\x42\x0e\n\x0c_max_retriesB\x13\n\x11_initial_delay_msB\x0f\n\r_max_delay_msB\x13\n\x11_delay_multiplier"\xc6\x04\n\x04Task\x12\x0f\n\x02id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x16\n\tnamespace\x18\x02 \x01(\tH\x01\x88\x01\x01\x12\x17\n\ngraph_name\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x1a\n\rgraph_version\x18\x04 \x01(\tH\x03\x88\x01\x01\x12\x1a\n\rfunction_name\x18\x05 \x01(\tH\x04\x88\x01\x01\x12 \n\x13graph_invocation_id\x18\x06 \x01(\tH\x05\x88\x01\x01\x12\x17\n\ntimeout_ms\x18\n \x01(\rH\x06\x88\x01\x01\x12\x30\n\x05input\x18\x0b \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x07\x88\x01\x01\x12\x38\n\rreducer_input\x18\x0c \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x08\x88\x01\x01\x12&\n\x19output_payload_uri_prefix\x18\r \x01(\tH\t\x88\x01\x01\x12;\n\x0cretry_policy\x18\x0e \x01(\x0b\x32 .executor_api_pb.TaskRetryPolicyH\n\x88\x01\x01\x42\x05\n\x03_idB\x0c\n\n_namespaceB\r\n\x0b_graph_nameB\x10\n\x0e_graph_versionB\x10\n\x0e_function_nameB\x16\n\x14_graph_invocation_idB\r\n\x0b_timeout_msB\x08\n\x06_inputB\x10\n\x0e_reducer_inputB\x1c\n\x1a_output_payload_uri_prefixB\x0f\n\r_retry_policy"\xad\x01\n\x0eTaskAllocation\x12!\n\x14\x66unction_executor_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12(\n\x04task\x18\x02 \x01(\x0b\x32\x15.executor_api_pb.TaskH\x01\x88\x01\x01\x12\x1a\n\rallocation_id\x18\x03 \x01(\tH\x02\x88\x01\x01\x42\x17\n\x15_function_executor_idB\x07\n\x05_taskB\x10\n\x0e_allocation_id"K\n\x1fGetDesiredExecutorStatesRequest\x12\x18\n\x0b\x65xecutor_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x42\x0e\n\x0c_executor_id"\xb9\x01\n\x14\x44\x65siredExecutorState\x12H\n\x12\x66unction_executors\x18\x01 \x03(\x0b\x32,.executor_api_pb.FunctionExecutorDescription\x12\x39\n\x10task_allocations\x18\x02 \x03(\x0b\x32\x1f.executor_api_pb.TaskAllocation\x12\x12\n\x05\x63lock\x18\x03 \x01(\x04H\x00\x88\x01\x01\x42\x08\n\x06_clock"\'\n\rResultRouting\x12\x16\n\x0enext_functions\x18\x01 \x03(\t"\x81\x06\n\nTaskResult\x12\x14\n\x07task_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x1a\n\rallocation_id\x18\x02 \x01(\tH\x01\x88\x01\x01\x12\x16\n\tnamespace\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x17\n\ngraph_name\x18\x04 \x01(\tH\x03\x88\x01\x01\x12\x1a\n\rgraph_version\x18\x05 \x01(\tH\x04\x88\x01\x01\x12\x1a\n\rfunction_name\x18\x06 \x01(\tH\x05\x88\x01\x01\x12 \n\x13graph_invocation_id\x18\x07 \x01(\tH\x06\x88\x01\x01\x12\x14\n\x07reducer\x18\x08 \x01(\x08H\x07\x88\x01\x01\x12;\n\x0coutcome_code\x18\t \x01(\x0e\x32 .executor_api_pb.TaskOutcomeCodeH\x08\x88\x01\x01\x12?\n\x0e\x66\x61ilure_reason\x18\n \x01(\x0e\x32".executor_api_pb.TaskFailureReasonH\t\x88\x01\x01\x12\x16\n\x0enext_functions\x18\x0b \x03(\t\x12\x36\n\x10\x66unction_outputs\x18\x0c \x03(\x0b\x32\x1c.executor_api_pb.DataPayload\x12\x31\n\x06stdout\x18\r \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\n\x88\x01\x01\x12\x31\n\x06stderr\x18\x0e \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x0b\x88\x01\x01\x12/\n\x07routing\x18\x0f \x01(\x0b\x32\x1e.executor_api_pb.ResultRoutingB\n\n\x08_task_idB\x10\n\x0e_allocation_idB\x0c\n\n_namespaceB\r\n\x0b_graph_nameB\x10\n\x0e_graph_versionB\x10\n\x0e_function_nameB\x16\n\x14_graph_invocation_idB\n\n\x08_reducerB\x0f\n\r_outcome_codeB\x11\n\x0f_failure_reasonB\t\n\x07_stdoutB\t\n\x07_stderr*\xab\x01\n\x13\x44\x61taPayloadEncoding\x12!\n\x1d\x44\x41TA_PAYLOAD_ENCODING_UNKNOWN\x10\x00\x12#\n\x1f\x44\x41TA_PAYLOAD_ENCODING_UTF8_JSON\x10\x01\x12#\n\x1f\x44\x41TA_PAYLOAD_ENCODING_UTF8_TEXT\x10\x02\x12\'\n#DATA_PAYLOAD_ENCODING_BINARY_PICKLE\x10\x03*\xd6\x01\n\x08GPUModel\x12\x15\n\x11GPU_MODEL_UNKNOWN\x10\x00\x12\x1e\n\x1aGPU_MODEL_NVIDIA_A100_40GB\x10\x01\x12\x1e\n\x1aGPU_MODEL_NVIDIA_A100_80GB\x10\x02\x12\x1e\n\x1aGPU_MODEL_NVIDIA_H100_80GB\x10\x03\x12\x1d\n\x19GPU_MODEL_NVIDIA_TESLA_T4\x10\x04\x12\x1a\n\x16GPU_MODEL_NVIDIA_A6000\x10\x05\x12\x18\n\x14GPU_MODEL_NVIDIA_A10\x10\x06*\xb3\x01\n\x16\x46unctionExecutorStatus\x12$\n FUNCTION_EXECUTOR_STATUS_UNKNOWN\x10\x00\x12$\n FUNCTION_EXECUTOR_STATUS_PENDING\x10\x01\x12$\n FUNCTION_EXECUTOR_STATUS_RUNNING\x10\x02\x12\'\n#FUNCTION_EXECUTOR_STATUS_TERMINATED\x10\x03*\x95\x05\n!FunctionExecutorTerminationReason\x12\x30\n,FUNCTION_EXECUTOR_TERMINATION_REASON_UNKNOWN\x10\x00\x12\x46\nBFUNCTION_EXECUTOR_TERMINATION_REASON_STARTUP_FAILED_INTERNAL_ERROR\x10\x01\x12\x46\nBFUNCTION_EXECUTOR_TERMINATION_REASON_STARTUP_FAILED_FUNCTION_ERROR\x10\x02\x12H\nDFUNCTION_EXECUTOR_TERMINATION_REASON_STARTUP_FAILED_FUNCTION_TIMEOUT\x10\x03\x12:\n6FUNCTION_EXECUTOR_TERMINATION_REASON_EXECUTOR_SHUTDOWN\x10\n\x12\x43\n?FUNCTION_EXECUTOR_TERMINATION_REASON_REMOVED_FROM_DESIRED_STATE\x10\x0b\x12\x32\n.FUNCTION_EXECUTOR_TERMINATION_REASON_UNHEALTHY\x10\x0c\x12\x37\n3FUNCTION_EXECUTOR_TERMINATION_REASON_INTERNAL_ERROR\x10\r\x12\x39\n5FUNCTION_EXECUTOR_TERMINATION_REASON_FUNCTION_TIMEOUT\x10\x0e\x12;\n7FUNCTION_EXECUTOR_TERMINATION_REASON_FUNCTION_CANCELLED\x10\x0f*\xa5\x01\n\x0e\x45xecutorStatus\x12\x1b\n\x17\x45XECUTOR_STATUS_UNKNOWN\x10\x00\x12\x1f\n\x1b\x45XECUTOR_STATUS_STARTING_UP\x10\x01\x12\x1b\n\x17\x45XECUTOR_STATUS_RUNNING\x10\x02\x12\x1b\n\x17\x45XECUTOR_STATUS_DRAINED\x10\x03\x12\x1b\n\x17\x45XECUTOR_STATUS_STOPPED\x10\x04*n\n\x0fTaskOutcomeCode\x12\x1d\n\x19TASK_OUTCOME_CODE_UNKNOWN\x10\x00\x12\x1d\n\x19TASK_OUTCOME_CODE_SUCCESS\x10\x01\x12\x1d\n\x19TASK_OUTCOME_CODE_FAILURE\x10\x02*\x8c\x02\n\x11TaskFailureReason\x12\x1f\n\x1bTASK_FAILURE_REASON_UNKNOWN\x10\x00\x12&\n"TASK_FAILURE_REASON_INTERNAL_ERROR\x10\x01\x12&\n"TASK_FAILURE_REASON_FUNCTION_ERROR\x10\x02\x12(\n$TASK_FAILURE_REASON_FUNCTION_TIMEOUT\x10\x03\x12&\n"TASK_FAILURE_REASON_TASK_CANCELLED\x10\x04\x12\x34\n0TASK_FAILURE_REASON_FUNCTION_EXECUTOR_TERMINATED\x10\x05\x32\xff\x01\n\x0b\x45xecutorAPI\x12t\n\x15report_executor_state\x12+.executor_api_pb.ReportExecutorStateRequest\x1a,.executor_api_pb.ReportExecutorStateResponse"\x00\x12z\n\x1bget_desired_executor_states\x12\x30.executor_api_pb.GetDesiredExecutorStatesRequest\x1a%.executor_api_pb.DesiredExecutorState"\x00\x30\x01\x62\x06proto3'
|
22
|
+
b'\n!indexify/proto/executor_api.proto\x12\x0f\x65xecutor_api_pb"\xeb\x01\n\x0b\x44\x61taPayload\x12\x11\n\x04size\x18\x02 \x01(\x04H\x00\x88\x01\x01\x12\x18\n\x0bsha256_hash\x18\x03 \x01(\tH\x01\x88\x01\x01\x12\x10\n\x03uri\x18\x04 \x01(\tH\x02\x88\x01\x01\x12;\n\x08\x65ncoding\x18\x05 \x01(\x0e\x32$.executor_api_pb.DataPayloadEncodingH\x03\x88\x01\x01\x12\x1d\n\x10\x65ncoding_version\x18\x06 \x01(\x04H\x04\x88\x01\x01\x42\x07\n\x05_sizeB\x0e\n\x0c_sha256_hashB\x06\n\x04_uriB\x0b\n\t_encodingB\x13\n\x11_encoding_version"e\n\x0cGPUResources\x12\x12\n\x05\x63ount\x18\x01 \x01(\rH\x00\x88\x01\x01\x12-\n\x05model\x18\x02 \x01(\x0e\x32\x19.executor_api_pb.GPUModelH\x01\x88\x01\x01\x42\x08\n\x06_countB\x08\n\x06_model"\xc2\x01\n\rHostResources\x12\x16\n\tcpu_count\x18\x01 \x01(\rH\x00\x88\x01\x01\x12\x19\n\x0cmemory_bytes\x18\x02 \x01(\x04H\x01\x88\x01\x01\x12\x17\n\ndisk_bytes\x18\x03 \x01(\x04H\x02\x88\x01\x01\x12/\n\x03gpu\x18\x04 \x01(\x0b\x32\x1d.executor_api_pb.GPUResourcesH\x03\x88\x01\x01\x42\x0c\n\n_cpu_countB\x0f\n\r_memory_bytesB\r\n\x0b_disk_bytesB\x06\n\x04_gpu"\xbb\x01\n\x0f\x41llowedFunction\x12\x16\n\tnamespace\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x17\n\ngraph_name\x18\x02 \x01(\tH\x01\x88\x01\x01\x12\x1a\n\rfunction_name\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x1a\n\rgraph_version\x18\x04 \x01(\tH\x03\x88\x01\x01\x42\x0c\n\n_namespaceB\r\n\x0b_graph_nameB\x10\n\x0e_function_nameB\x10\n\x0e_graph_version"\xd8\x01\n\x19\x46unctionExecutorResources\x12\x1b\n\x0e\x63pu_ms_per_sec\x18\x01 \x01(\rH\x00\x88\x01\x01\x12\x19\n\x0cmemory_bytes\x18\x02 \x01(\x04H\x01\x88\x01\x01\x12\x17\n\ndisk_bytes\x18\x03 \x01(\x04H\x02\x88\x01\x01\x12/\n\x03gpu\x18\x04 \x01(\x0b\x32\x1d.executor_api_pb.GPUResourcesH\x03\x88\x01\x01\x42\x11\n\x0f_cpu_ms_per_secB\x0f\n\r_memory_bytesB\r\n\x0b_disk_bytesB\x06\n\x04_gpu"\xb3\x04\n\x1b\x46unctionExecutorDescription\x12\x0f\n\x02id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x16\n\tnamespace\x18\x02 \x01(\tH\x01\x88\x01\x01\x12\x17\n\ngraph_name\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x1a\n\rgraph_version\x18\x04 \x01(\tH\x03\x88\x01\x01\x12\x1a\n\rfunction_name\x18\x05 \x01(\tH\x04\x88\x01\x01\x12\x16\n\timage_uri\x18\x06 \x01(\tH\x05\x88\x01\x01\x12\x14\n\x0csecret_names\x18\x07 \x03(\t\x12%\n\x18\x63ustomer_code_timeout_ms\x18\t \x01(\rH\x06\x88\x01\x01\x12\x30\n\x05graph\x18\n \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x07\x88\x01\x01\x12\x42\n\tresources\x18\x0b \x01(\x0b\x32*.executor_api_pb.FunctionExecutorResourcesH\x08\x88\x01\x01\x12&\n\x19output_payload_uri_prefix\x18\x0c \x01(\tH\t\x88\x01\x01\x42\x05\n\x03_idB\x0c\n\n_namespaceB\r\n\x0b_graph_nameB\x10\n\x0e_graph_versionB\x10\n\x0e_function_nameB\x0c\n\n_image_uriB\x1b\n\x19_customer_code_timeout_msB\x08\n\x06_graphB\x0c\n\n_resourcesB\x1c\n\x1a_output_payload_uri_prefix"\xa4\x02\n\x15\x46unctionExecutorState\x12\x46\n\x0b\x64\x65scription\x18\x01 \x01(\x0b\x32,.executor_api_pb.FunctionExecutorDescriptionH\x00\x88\x01\x01\x12<\n\x06status\x18\x02 \x01(\x0e\x32\'.executor_api_pb.FunctionExecutorStatusH\x01\x88\x01\x01\x12S\n\x12termination_reason\x18\x03 \x01(\x0e\x32\x32.executor_api_pb.FunctionExecutorTerminationReasonH\x02\x88\x01\x01\x42\x0e\n\x0c_descriptionB\t\n\x07_statusB\x15\n\x13_termination_reason"\x8c\x02\n\x16\x46unctionExecutorUpdate\x12\x46\n\x0b\x64\x65scription\x18\x01 \x01(\x0b\x32,.executor_api_pb.FunctionExecutorDescriptionH\x00\x88\x01\x01\x12\x39\n\x0estartup_stdout\x18\x02 \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x01\x88\x01\x01\x12\x39\n\x0estartup_stderr\x18\x03 \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x02\x88\x01\x01\x42\x0e\n\x0c_descriptionB\x11\n\x0f_startup_stdoutB\x11\n\x0f_startup_stderr"\xce\x05\n\rExecutorState\x12\x18\n\x0b\x65xecutor_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x15\n\x08hostname\x18\x03 \x01(\tH\x01\x88\x01\x01\x12\x14\n\x07version\x18\x05 \x01(\tH\x02\x88\x01\x01\x12\x34\n\x06status\x18\x06 \x01(\x0e\x32\x1f.executor_api_pb.ExecutorStatusH\x03\x88\x01\x01\x12<\n\x0ftotal_resources\x18\r \x01(\x0b\x32\x1e.executor_api_pb.HostResourcesH\x04\x88\x01\x01\x12N\n!total_function_executor_resources\x18\x07 \x01(\x0b\x32\x1e.executor_api_pb.HostResourcesH\x05\x88\x01\x01\x12;\n\x11\x61llowed_functions\x18\x08 \x03(\x0b\x32 .executor_api_pb.AllowedFunction\x12H\n\x18\x66unction_executor_states\x18\t \x03(\x0b\x32&.executor_api_pb.FunctionExecutorState\x12:\n\x06labels\x18\n \x03(\x0b\x32*.executor_api_pb.ExecutorState.LabelsEntry\x12\x17\n\nstate_hash\x18\x0b \x01(\tH\x06\x88\x01\x01\x12\x19\n\x0cserver_clock\x18\x0c \x01(\x04H\x07\x88\x01\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\x42\x0e\n\x0c_executor_idB\x0b\n\t_hostnameB\n\n\x08_versionB\t\n\x07_statusB\x12\n\x10_total_resourcesB$\n"_total_function_executor_resourcesB\r\n\x0b_state_hashB\x0f\n\r_server_clock"\xb9\x01\n\x0e\x45xecutorUpdate\x12\x18\n\x0b\x65xecutor_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x31\n\x0ctask_results\x18\x02 \x03(\x0b\x32\x1b.executor_api_pb.TaskResult\x12J\n\x19\x66unction_executor_updates\x18\x03 \x03(\x0b\x32\'.executor_api_pb.FunctionExecutorUpdateB\x0e\n\x0c_executor_id"\xbf\x01\n\x1aReportExecutorStateRequest\x12;\n\x0e\x65xecutor_state\x18\x01 \x01(\x0b\x32\x1e.executor_api_pb.ExecutorStateH\x00\x88\x01\x01\x12=\n\x0f\x65xecutor_update\x18\x02 \x01(\x0b\x32\x1f.executor_api_pb.ExecutorUpdateH\x01\x88\x01\x01\x42\x11\n\x0f_executor_stateB\x12\n\x10_executor_update"\x1d\n\x1bReportExecutorStateResponse"\xcf\x01\n\x0fTaskRetryPolicy\x12\x18\n\x0bmax_retries\x18\x01 \x01(\rH\x00\x88\x01\x01\x12\x1d\n\x10initial_delay_ms\x18\x02 \x01(\rH\x01\x88\x01\x01\x12\x19\n\x0cmax_delay_ms\x18\x03 \x01(\rH\x02\x88\x01\x01\x12\x1d\n\x10\x64\x65lay_multiplier\x18\x04 \x01(\rH\x03\x88\x01\x01\x42\x0e\n\x0c_max_retriesB\x13\n\x11_initial_delay_msB\x0f\n\r_max_delay_msB\x13\n\x11_delay_multiplier"\xc6\x04\n\x04Task\x12\x0f\n\x02id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x16\n\tnamespace\x18\x02 \x01(\tH\x01\x88\x01\x01\x12\x17\n\ngraph_name\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x1a\n\rgraph_version\x18\x04 \x01(\tH\x03\x88\x01\x01\x12\x1a\n\rfunction_name\x18\x05 \x01(\tH\x04\x88\x01\x01\x12 \n\x13graph_invocation_id\x18\x06 \x01(\tH\x05\x88\x01\x01\x12\x17\n\ntimeout_ms\x18\n \x01(\rH\x06\x88\x01\x01\x12\x30\n\x05input\x18\x0b \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x07\x88\x01\x01\x12\x38\n\rreducer_input\x18\x0c \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x08\x88\x01\x01\x12&\n\x19output_payload_uri_prefix\x18\r \x01(\tH\t\x88\x01\x01\x12;\n\x0cretry_policy\x18\x0e \x01(\x0b\x32 .executor_api_pb.TaskRetryPolicyH\n\x88\x01\x01\x42\x05\n\x03_idB\x0c\n\n_namespaceB\r\n\x0b_graph_nameB\x10\n\x0e_graph_versionB\x10\n\x0e_function_nameB\x16\n\x14_graph_invocation_idB\r\n\x0b_timeout_msB\x08\n\x06_inputB\x10\n\x0e_reducer_inputB\x1c\n\x1a_output_payload_uri_prefixB\x0f\n\r_retry_policy"\xad\x01\n\x0eTaskAllocation\x12!\n\x14\x66unction_executor_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12(\n\x04task\x18\x02 \x01(\x0b\x32\x15.executor_api_pb.TaskH\x01\x88\x01\x01\x12\x1a\n\rallocation_id\x18\x03 \x01(\tH\x02\x88\x01\x01\x42\x17\n\x15_function_executor_idB\x07\n\x05_taskB\x10\n\x0e_allocation_id"K\n\x1fGetDesiredExecutorStatesRequest\x12\x18\n\x0b\x65xecutor_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x42\x0e\n\x0c_executor_id"\xb9\x01\n\x14\x44\x65siredExecutorState\x12H\n\x12\x66unction_executors\x18\x01 \x03(\x0b\x32,.executor_api_pb.FunctionExecutorDescription\x12\x39\n\x10task_allocations\x18\x02 \x03(\x0b\x32\x1f.executor_api_pb.TaskAllocation\x12\x12\n\x05\x63lock\x18\x03 \x01(\x04H\x00\x88\x01\x01\x42\x08\n\x06_clock"\xb0\x06\n\nTaskResult\x12\x14\n\x07task_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x1a\n\rallocation_id\x18\x02 \x01(\tH\x01\x88\x01\x01\x12\x16\n\tnamespace\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x17\n\ngraph_name\x18\x04 \x01(\tH\x03\x88\x01\x01\x12\x1a\n\rgraph_version\x18\x05 \x01(\tH\x04\x88\x01\x01\x12\x1a\n\rfunction_name\x18\x06 \x01(\tH\x05\x88\x01\x01\x12 \n\x13graph_invocation_id\x18\x07 \x01(\tH\x06\x88\x01\x01\x12\x14\n\x07reducer\x18\x08 \x01(\x08H\x07\x88\x01\x01\x12;\n\x0coutcome_code\x18\t \x01(\x0e\x32 .executor_api_pb.TaskOutcomeCodeH\x08\x88\x01\x01\x12?\n\x0e\x66\x61ilure_reason\x18\n \x01(\x0e\x32".executor_api_pb.TaskFailureReasonH\t\x88\x01\x01\x12\x16\n\x0enext_functions\x18\x0b \x03(\t\x12\x36\n\x10\x66unction_outputs\x18\x0c \x03(\x0b\x32\x1c.executor_api_pb.DataPayload\x12\x31\n\x06stdout\x18\r \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\n\x88\x01\x01\x12\x31\n\x06stderr\x18\x0e \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x0b\x88\x01\x01\x12\x42\n\x17invocation_error_output\x18\x0f \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x0c\x88\x01\x01\x42\n\n\x08_task_idB\x10\n\x0e_allocation_idB\x0c\n\n_namespaceB\r\n\x0b_graph_nameB\x10\n\x0e_graph_versionB\x10\n\x0e_function_nameB\x16\n\x14_graph_invocation_idB\n\n\x08_reducerB\x0f\n\r_outcome_codeB\x11\n\x0f_failure_reasonB\t\n\x07_stdoutB\t\n\x07_stderrB\x1a\n\x18_invocation_error_output*\xd1\x01\n\x13\x44\x61taPayloadEncoding\x12!\n\x1d\x44\x41TA_PAYLOAD_ENCODING_UNKNOWN\x10\x00\x12#\n\x1f\x44\x41TA_PAYLOAD_ENCODING_UTF8_JSON\x10\x01\x12#\n\x1f\x44\x41TA_PAYLOAD_ENCODING_UTF8_TEXT\x10\x02\x12\'\n#DATA_PAYLOAD_ENCODING_BINARY_PICKLE\x10\x03\x12$\n DATA_PAYLOAD_ENCODING_BINARY_ZIP\x10\x04*\xd6\x01\n\x08GPUModel\x12\x15\n\x11GPU_MODEL_UNKNOWN\x10\x00\x12\x1e\n\x1aGPU_MODEL_NVIDIA_A100_40GB\x10\x01\x12\x1e\n\x1aGPU_MODEL_NVIDIA_A100_80GB\x10\x02\x12\x1e\n\x1aGPU_MODEL_NVIDIA_H100_80GB\x10\x03\x12\x1d\n\x19GPU_MODEL_NVIDIA_TESLA_T4\x10\x04\x12\x1a\n\x16GPU_MODEL_NVIDIA_A6000\x10\x05\x12\x18\n\x14GPU_MODEL_NVIDIA_A10\x10\x06*\xb3\x01\n\x16\x46unctionExecutorStatus\x12$\n FUNCTION_EXECUTOR_STATUS_UNKNOWN\x10\x00\x12$\n FUNCTION_EXECUTOR_STATUS_PENDING\x10\x01\x12$\n FUNCTION_EXECUTOR_STATUS_RUNNING\x10\x02\x12\'\n#FUNCTION_EXECUTOR_STATUS_TERMINATED\x10\x03*\x95\x05\n!FunctionExecutorTerminationReason\x12\x30\n,FUNCTION_EXECUTOR_TERMINATION_REASON_UNKNOWN\x10\x00\x12\x46\nBFUNCTION_EXECUTOR_TERMINATION_REASON_STARTUP_FAILED_INTERNAL_ERROR\x10\x01\x12\x46\nBFUNCTION_EXECUTOR_TERMINATION_REASON_STARTUP_FAILED_FUNCTION_ERROR\x10\x02\x12H\nDFUNCTION_EXECUTOR_TERMINATION_REASON_STARTUP_FAILED_FUNCTION_TIMEOUT\x10\x03\x12:\n6FUNCTION_EXECUTOR_TERMINATION_REASON_EXECUTOR_SHUTDOWN\x10\n\x12\x43\n?FUNCTION_EXECUTOR_TERMINATION_REASON_REMOVED_FROM_DESIRED_STATE\x10\x0b\x12\x32\n.FUNCTION_EXECUTOR_TERMINATION_REASON_UNHEALTHY\x10\x0c\x12\x37\n3FUNCTION_EXECUTOR_TERMINATION_REASON_INTERNAL_ERROR\x10\r\x12\x39\n5FUNCTION_EXECUTOR_TERMINATION_REASON_FUNCTION_TIMEOUT\x10\x0e\x12;\n7FUNCTION_EXECUTOR_TERMINATION_REASON_FUNCTION_CANCELLED\x10\x0f*\xa5\x01\n\x0e\x45xecutorStatus\x12\x1b\n\x17\x45XECUTOR_STATUS_UNKNOWN\x10\x00\x12\x1f\n\x1b\x45XECUTOR_STATUS_STARTING_UP\x10\x01\x12\x1b\n\x17\x45XECUTOR_STATUS_RUNNING\x10\x02\x12\x1b\n\x17\x45XECUTOR_STATUS_DRAINED\x10\x03\x12\x1b\n\x17\x45XECUTOR_STATUS_STOPPED\x10\x04*n\n\x0fTaskOutcomeCode\x12\x1d\n\x19TASK_OUTCOME_CODE_UNKNOWN\x10\x00\x12\x1d\n\x19TASK_OUTCOME_CODE_SUCCESS\x10\x01\x12\x1d\n\x19TASK_OUTCOME_CODE_FAILURE\x10\x02*\xb6\x02\n\x11TaskFailureReason\x12\x1f\n\x1bTASK_FAILURE_REASON_UNKNOWN\x10\x00\x12&\n"TASK_FAILURE_REASON_INTERNAL_ERROR\x10\x01\x12&\n"TASK_FAILURE_REASON_FUNCTION_ERROR\x10\x02\x12(\n$TASK_FAILURE_REASON_FUNCTION_TIMEOUT\x10\x03\x12(\n$TASK_FAILURE_REASON_INVOCATION_ERROR\x10\x04\x12&\n"TASK_FAILURE_REASON_TASK_CANCELLED\x10\x05\x12\x34\n0TASK_FAILURE_REASON_FUNCTION_EXECUTOR_TERMINATED\x10\x06\x32\xff\x01\n\x0b\x45xecutorAPI\x12t\n\x15report_executor_state\x12+.executor_api_pb.ReportExecutorStateRequest\x1a,.executor_api_pb.ReportExecutorStateResponse"\x00\x12z\n\x1bget_desired_executor_states\x12\x30.executor_api_pb.GetDesiredExecutorStatesRequest\x1a%.executor_api_pb.DesiredExecutorState"\x00\x30\x01\x62\x06proto3'
|
23
23
|
)
|
24
24
|
|
25
25
|
_globals = globals()
|
@@ -31,20 +31,20 @@ if not _descriptor._USE_C_DESCRIPTORS:
|
|
31
31
|
DESCRIPTOR._loaded_options = None
|
32
32
|
_globals["_EXECUTORSTATE_LABELSENTRY"]._loaded_options = None
|
33
33
|
_globals["_EXECUTORSTATE_LABELSENTRY"]._serialized_options = b"8\001"
|
34
|
-
_globals["_DATAPAYLOADENCODING"]._serialized_start =
|
35
|
-
_globals["_DATAPAYLOADENCODING"]._serialized_end =
|
36
|
-
_globals["_GPUMODEL"]._serialized_start =
|
37
|
-
_globals["_GPUMODEL"]._serialized_end =
|
38
|
-
_globals["_FUNCTIONEXECUTORSTATUS"]._serialized_start =
|
39
|
-
_globals["_FUNCTIONEXECUTORSTATUS"]._serialized_end =
|
40
|
-
_globals["_FUNCTIONEXECUTORTERMINATIONREASON"]._serialized_start =
|
41
|
-
_globals["_FUNCTIONEXECUTORTERMINATIONREASON"]._serialized_end =
|
42
|
-
_globals["_EXECUTORSTATUS"]._serialized_start =
|
43
|
-
_globals["_EXECUTORSTATUS"]._serialized_end =
|
44
|
-
_globals["_TASKOUTCOMECODE"]._serialized_start =
|
45
|
-
_globals["_TASKOUTCOMECODE"]._serialized_end =
|
46
|
-
_globals["_TASKFAILUREREASON"]._serialized_start =
|
47
|
-
_globals["_TASKFAILUREREASON"]._serialized_end =
|
34
|
+
_globals["_DATAPAYLOADENCODING"]._serialized_start = 5323
|
35
|
+
_globals["_DATAPAYLOADENCODING"]._serialized_end = 5532
|
36
|
+
_globals["_GPUMODEL"]._serialized_start = 5535
|
37
|
+
_globals["_GPUMODEL"]._serialized_end = 5749
|
38
|
+
_globals["_FUNCTIONEXECUTORSTATUS"]._serialized_start = 5752
|
39
|
+
_globals["_FUNCTIONEXECUTORSTATUS"]._serialized_end = 5931
|
40
|
+
_globals["_FUNCTIONEXECUTORTERMINATIONREASON"]._serialized_start = 5934
|
41
|
+
_globals["_FUNCTIONEXECUTORTERMINATIONREASON"]._serialized_end = 6595
|
42
|
+
_globals["_EXECUTORSTATUS"]._serialized_start = 6598
|
43
|
+
_globals["_EXECUTORSTATUS"]._serialized_end = 6763
|
44
|
+
_globals["_TASKOUTCOMECODE"]._serialized_start = 6765
|
45
|
+
_globals["_TASKOUTCOMECODE"]._serialized_end = 6875
|
46
|
+
_globals["_TASKFAILUREREASON"]._serialized_start = 6878
|
47
|
+
_globals["_TASKFAILUREREASON"]._serialized_end = 7188
|
48
48
|
_globals["_DATAPAYLOAD"]._serialized_start = 55
|
49
49
|
_globals["_DATAPAYLOAD"]._serialized_end = 290
|
50
50
|
_globals["_GPURESOURCES"]._serialized_start = 292
|
@@ -81,10 +81,8 @@ if not _descriptor._USE_C_DESCRIPTORS:
|
|
81
81
|
_globals["_GETDESIREDEXECUTORSTATESREQUEST"]._serialized_end = 4313
|
82
82
|
_globals["_DESIREDEXECUTORSTATE"]._serialized_start = 4316
|
83
83
|
_globals["_DESIREDEXECUTORSTATE"]._serialized_end = 4501
|
84
|
-
_globals["
|
85
|
-
_globals["
|
86
|
-
_globals["
|
87
|
-
_globals["
|
88
|
-
_globals["_EXECUTORAPI"]._serialized_start = 7105
|
89
|
-
_globals["_EXECUTORAPI"]._serialized_end = 7360
|
84
|
+
_globals["_TASKRESULT"]._serialized_start = 4504
|
85
|
+
_globals["_TASKRESULT"]._serialized_end = 5320
|
86
|
+
_globals["_EXECUTORAPI"]._serialized_start = 7191
|
87
|
+
_globals["_EXECUTORAPI"]._serialized_end = 7446
|
90
88
|
# @@protoc_insertion_point(module_scope)
|
@@ -17,6 +17,7 @@ class DataPayloadEncoding(int, metaclass=_enum_type_wrapper.EnumTypeWrapper):
|
|
17
17
|
DATA_PAYLOAD_ENCODING_UTF8_JSON: _ClassVar[DataPayloadEncoding]
|
18
18
|
DATA_PAYLOAD_ENCODING_UTF8_TEXT: _ClassVar[DataPayloadEncoding]
|
19
19
|
DATA_PAYLOAD_ENCODING_BINARY_PICKLE: _ClassVar[DataPayloadEncoding]
|
20
|
+
DATA_PAYLOAD_ENCODING_BINARY_ZIP: _ClassVar[DataPayloadEncoding]
|
20
21
|
|
21
22
|
class GPUModel(int, metaclass=_enum_type_wrapper.EnumTypeWrapper):
|
22
23
|
__slots__ = ()
|
@@ -90,6 +91,7 @@ class TaskFailureReason(int, metaclass=_enum_type_wrapper.EnumTypeWrapper):
|
|
90
91
|
TASK_FAILURE_REASON_INTERNAL_ERROR: _ClassVar[TaskFailureReason]
|
91
92
|
TASK_FAILURE_REASON_FUNCTION_ERROR: _ClassVar[TaskFailureReason]
|
92
93
|
TASK_FAILURE_REASON_FUNCTION_TIMEOUT: _ClassVar[TaskFailureReason]
|
94
|
+
TASK_FAILURE_REASON_INVOCATION_ERROR: _ClassVar[TaskFailureReason]
|
93
95
|
TASK_FAILURE_REASON_TASK_CANCELLED: _ClassVar[TaskFailureReason]
|
94
96
|
TASK_FAILURE_REASON_FUNCTION_EXECUTOR_TERMINATED: _ClassVar[TaskFailureReason]
|
95
97
|
|
@@ -97,6 +99,7 @@ DATA_PAYLOAD_ENCODING_UNKNOWN: DataPayloadEncoding
|
|
97
99
|
DATA_PAYLOAD_ENCODING_UTF8_JSON: DataPayloadEncoding
|
98
100
|
DATA_PAYLOAD_ENCODING_UTF8_TEXT: DataPayloadEncoding
|
99
101
|
DATA_PAYLOAD_ENCODING_BINARY_PICKLE: DataPayloadEncoding
|
102
|
+
DATA_PAYLOAD_ENCODING_BINARY_ZIP: DataPayloadEncoding
|
100
103
|
GPU_MODEL_UNKNOWN: GPUModel
|
101
104
|
GPU_MODEL_NVIDIA_A100_40GB: GPUModel
|
102
105
|
GPU_MODEL_NVIDIA_A100_80GB: GPUModel
|
@@ -142,6 +145,7 @@ TASK_FAILURE_REASON_UNKNOWN: TaskFailureReason
|
|
142
145
|
TASK_FAILURE_REASON_INTERNAL_ERROR: TaskFailureReason
|
143
146
|
TASK_FAILURE_REASON_FUNCTION_ERROR: TaskFailureReason
|
144
147
|
TASK_FAILURE_REASON_FUNCTION_TIMEOUT: TaskFailureReason
|
148
|
+
TASK_FAILURE_REASON_INVOCATION_ERROR: TaskFailureReason
|
145
149
|
TASK_FAILURE_REASON_TASK_CANCELLED: TaskFailureReason
|
146
150
|
TASK_FAILURE_REASON_FUNCTION_EXECUTOR_TERMINATED: TaskFailureReason
|
147
151
|
|
@@ -527,12 +531,6 @@ class DesiredExecutorState(_message.Message):
|
|
527
531
|
clock: _Optional[int] = ...,
|
528
532
|
) -> None: ...
|
529
533
|
|
530
|
-
class ResultRouting(_message.Message):
|
531
|
-
__slots__ = ("next_functions",)
|
532
|
-
NEXT_FUNCTIONS_FIELD_NUMBER: _ClassVar[int]
|
533
|
-
next_functions: _containers.RepeatedScalarFieldContainer[str]
|
534
|
-
def __init__(self, next_functions: _Optional[_Iterable[str]] = ...) -> None: ...
|
535
|
-
|
536
534
|
class TaskResult(_message.Message):
|
537
535
|
__slots__ = (
|
538
536
|
"task_id",
|
@@ -549,7 +547,7 @@ class TaskResult(_message.Message):
|
|
549
547
|
"function_outputs",
|
550
548
|
"stdout",
|
551
549
|
"stderr",
|
552
|
-
"
|
550
|
+
"invocation_error_output",
|
553
551
|
)
|
554
552
|
TASK_ID_FIELD_NUMBER: _ClassVar[int]
|
555
553
|
ALLOCATION_ID_FIELD_NUMBER: _ClassVar[int]
|
@@ -565,7 +563,7 @@ class TaskResult(_message.Message):
|
|
565
563
|
FUNCTION_OUTPUTS_FIELD_NUMBER: _ClassVar[int]
|
566
564
|
STDOUT_FIELD_NUMBER: _ClassVar[int]
|
567
565
|
STDERR_FIELD_NUMBER: _ClassVar[int]
|
568
|
-
|
566
|
+
INVOCATION_ERROR_OUTPUT_FIELD_NUMBER: _ClassVar[int]
|
569
567
|
task_id: str
|
570
568
|
allocation_id: str
|
571
569
|
namespace: str
|
@@ -580,7 +578,7 @@ class TaskResult(_message.Message):
|
|
580
578
|
function_outputs: _containers.RepeatedCompositeFieldContainer[DataPayload]
|
581
579
|
stdout: DataPayload
|
582
580
|
stderr: DataPayload
|
583
|
-
|
581
|
+
invocation_error_output: DataPayload
|
584
582
|
def __init__(
|
585
583
|
self,
|
586
584
|
task_id: _Optional[str] = ...,
|
@@ -597,5 +595,5 @@ class TaskResult(_message.Message):
|
|
597
595
|
function_outputs: _Optional[_Iterable[_Union[DataPayload, _Mapping]]] = ...,
|
598
596
|
stdout: _Optional[_Union[DataPayload, _Mapping]] = ...,
|
599
597
|
stderr: _Optional[_Union[DataPayload, _Mapping]] = ...,
|
600
|
-
|
598
|
+
invocation_error_output: _Optional[_Union[DataPayload, _Mapping]] = ...,
|
601
599
|
) -> None: ...
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/health_checker.py
RENAMED
File without changes
|
File without changes
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor/metrics/health_checker.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/__init__.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/events.py
RENAMED
File without changes
|
File without changes
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/loggers.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/function_executor_controller/task_info.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/host_resources/nvidia_gpu_allocator.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/monitoring/health_checker/health_checker.py
RENAMED
File without changes
|
File without changes
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/monitoring/prometheus_metrics_handler.py
RENAMED
File without changes
|
File without changes
|
{indexify-0.4.9 → indexify-0.4.10}/src/indexify/executor/monitoring/startup_probe_handler.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|