indexify 0.3.21__tar.gz → 0.3.23__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.
Files changed (65) hide show
  1. {indexify-0.3.21 → indexify-0.3.23}/PKG-INFO +1 -1
  2. {indexify-0.3.21 → indexify-0.3.23}/pyproject.toml +1 -1
  3. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/cli/cli.py +1 -10
  4. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/api_objects.py +22 -0
  5. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/downloader.py +1 -3
  6. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/server/function_executor_server_factory.py +7 -0
  7. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/single_task_runner.py +24 -3
  8. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/grpc/function_executor_controller.py +21 -0
  9. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/grpc/state_reconciler.py +1 -3
  10. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/grpc/state_reporter.py +1 -3
  11. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/proto/executor_api.proto +19 -0
  12. indexify-0.3.23/src/indexify/proto/executor_api_pb2.py +86 -0
  13. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/proto/executor_api_pb2.pyi +44 -0
  14. indexify-0.3.21/src/indexify/proto/executor_api_pb2.py +0 -82
  15. {indexify-0.3.21 → indexify-0.3.23}/README.md +0 -0
  16. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/README.md +0 -0
  17. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/blob_store/blob_store.py +0 -0
  18. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/blob_store/local_fs_blob_store.py +0 -0
  19. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/blob_store/metrics/blob_store.py +0 -0
  20. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/blob_store/s3_blob_store.py +0 -0
  21. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/executor.py +0 -0
  22. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/executor_flavor.py +0 -0
  23. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/function_executor.py +0 -0
  24. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/function_executor_state.py +0 -0
  25. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/function_executor_states_container.py +0 -0
  26. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/function_executor_status.py +0 -0
  27. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/health_checker.py +0 -0
  28. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/invocation_state_client.py +0 -0
  29. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/metrics/function_executor.py +0 -0
  30. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/metrics/function_executor_state.py +0 -0
  31. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/metrics/function_executor_state_container.py +0 -0
  32. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/metrics/health_checker.py +0 -0
  33. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/metrics/invocation_state_client.py +0 -0
  34. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/metrics/single_task_runner.py +0 -0
  35. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/server/client_configuration.py +0 -0
  36. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/server/function_executor_server.py +0 -0
  37. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/server/subprocess_function_executor_server.py +0 -0
  38. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/server/subprocess_function_executor_server_factory.py +0 -0
  39. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/task_input.py +0 -0
  40. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/function_executor/task_output.py +0 -0
  41. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/grpc/channel_manager.py +0 -0
  42. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/grpc/metrics/channel_manager.py +0 -0
  43. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/grpc/metrics/state_reconciler.py +0 -0
  44. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/grpc/metrics/state_reporter.py +0 -0
  45. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/grpc/metrics/task_controller.py +0 -0
  46. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/grpc/task_controller.py +0 -0
  47. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/metrics/downloader.py +0 -0
  48. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/metrics/executor.py +0 -0
  49. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/metrics/task_fetcher.py +0 -0
  50. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/metrics/task_reporter.py +0 -0
  51. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/metrics/task_runner.py +0 -0
  52. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/monitoring/function_allowlist.py +0 -0
  53. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/monitoring/handler.py +0 -0
  54. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/monitoring/health_check_handler.py +0 -0
  55. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/monitoring/health_checker/generic_health_checker.py +0 -0
  56. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/monitoring/health_checker/health_checker.py +0 -0
  57. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/monitoring/metrics.py +0 -0
  58. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/monitoring/prometheus_metrics_handler.py +0 -0
  59. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/monitoring/server.py +0 -0
  60. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/monitoring/startup_probe_handler.py +0 -0
  61. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/runtime_probes.py +0 -0
  62. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/task_fetcher.py +0 -0
  63. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/task_reporter.py +0 -0
  64. {indexify-0.3.21 → indexify-0.3.23}/src/indexify/executor/task_runner.py +0 -0
  65. {indexify-0.3.21 → indexify-0.3.23}/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.3.21
3
+ Version: 0.3.23
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
@@ -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.3.21"
4
+ version = "0.3.23"
5
5
  description = "Open Source Indexify components and helper tools"
6
6
  authors = ["Tensorlake Inc. <support@tensorlake.ai>"]
7
7
  license = "Apache 2.0"
@@ -102,9 +102,6 @@ def executor(
102
102
  executor_cache: Optional[str] = typer.Option(
103
103
  "~/.indexify/executor_cache", help="Path to the executor cache directory"
104
104
  ),
105
- executor_id: Optional[str] = typer.Option(
106
- None, help="ID of the executor, if not provided, a random ID will be generated"
107
- ),
108
105
  # Registred ports range ends at 49151.
109
106
  ports: Tuple[int, int] = typer.Option(
110
107
  (50000, 51000),
@@ -153,18 +150,12 @@ def executor(
153
150
  "At least one function must be specified when not running in development mode"
154
151
  )
155
152
 
156
- if executor_id is None:
157
- executor_id = nanoid.generate()
158
- elif not re.compile(r"^[a-zA-Z0-9_-]{10,}$").match(executor_id):
159
- raise typer.BadParameter(
160
- "--executor-id should be at least 10 characters long and only include characters _-[0-9][a-z][A-Z]"
161
- )
162
-
163
153
  kv_labels: Dict[str, str] = {}
164
154
  for label in labels:
165
155
  key, value = label.split("=")
166
156
  kv_labels[key] = value
167
157
 
158
+ executor_id: str = nanoid.generate()
168
159
  executor_version = version("indexify")
169
160
  logger = structlog.get_logger(module=__name__, executor_id=executor_id)
170
161
 
@@ -10,6 +10,25 @@ class DataPayload(BaseModel):
10
10
  content_type: Optional[str] = None
11
11
 
12
12
 
13
+ class NodeGPU(BaseModel):
14
+ count: int
15
+ model: str
16
+
17
+
18
+ class TaskResources(BaseModel):
19
+ cpus: float
20
+ memory_mb: int
21
+ ephemeral_disk_mb: int
22
+ gpu: Optional[NodeGPU] = None
23
+
24
+
25
+ class TaskRetryPolicy(BaseModel):
26
+ max_retries: int
27
+ initial_delay_sec: float
28
+ max_delay_sec: float
29
+ delay_multiplier: float
30
+
31
+
13
32
  class Task(BaseModel):
14
33
  id: str
15
34
  namespace: str
@@ -27,6 +46,9 @@ class Task(BaseModel):
27
46
  input_payload: Optional[DataPayload] = None
28
47
  reducer_input_payload: Optional[DataPayload] = None
29
48
  output_payload_uri_prefix: Optional[str] = None
49
+ timeout: Optional[int] = None # in seconds
50
+ resources: Optional[TaskResources] = None
51
+ retry_policy: Optional[TaskRetryPolicy] = None
30
52
 
31
53
 
32
54
  class FunctionURI(BaseModel):
@@ -9,9 +9,7 @@ from tensorlake.function_executor.proto.message_validator import MessageValidato
9
9
  from tensorlake.utils.http_client import get_httpx_client
10
10
 
11
11
  from indexify.proto.executor_api_pb2 import DataPayload as DataPayloadProto
12
- from indexify.proto.executor_api_pb2 import (
13
- DataPayloadEncoding,
14
- )
12
+ from indexify.proto.executor_api_pb2 import DataPayloadEncoding
15
13
 
16
14
  from .api_objects import DataPayload
17
15
  from .blob_store.blob_store import BLOBStore
@@ -19,8 +19,15 @@ class FunctionExecutorServerConfiguration:
19
19
  executor_id: str
20
20
  function_executor_id: str
21
21
  namespace: str
22
+ graph_name: str
23
+ function_name: str
24
+ graph_version: str
22
25
  image_uri: Optional[str]
23
26
  secret_names: List[str]
27
+ cpu_ms_per_sec: Optional[int]
28
+ memory_bytes: Optional[int]
29
+ disk_bytes: Optional[int]
30
+ gpu_count: int
24
31
 
25
32
 
26
33
  class FunctionExecutorServerFactory:
@@ -1,4 +1,5 @@
1
1
  from collections.abc import Awaitable, Callable
2
+ from math import ceil
2
3
  from typing import Any, Optional
3
4
 
4
5
  import grpc
@@ -131,13 +132,33 @@ class SingleTaskRunner:
131
132
  self._function_executor_state.function_executor = FunctionExecutor(
132
133
  server_factory=self._function_executor_server_factory, logger=self._logger
133
134
  )
135
+ task: Task = self._task_input.task
134
136
  config: FunctionExecutorServerConfiguration = (
135
137
  FunctionExecutorServerConfiguration(
136
138
  executor_id=self._executor_id,
137
139
  function_executor_id=self._function_executor_state.id,
138
- namespace=self._task_input.task.namespace,
139
- image_uri=self._task_input.task.image_uri,
140
- secret_names=self._task_input.task.secret_names or [],
140
+ namespace=task.namespace,
141
+ graph_name=task.compute_graph,
142
+ graph_version=task.graph_version,
143
+ function_name=task.compute_fn,
144
+ image_uri=task.image_uri,
145
+ secret_names=task.secret_names or [],
146
+ cpu_ms_per_sec=(
147
+ None
148
+ if task.resources.cpus is None
149
+ else ceil(task.resources.cpus * 1000)
150
+ ),
151
+ memory_bytes=(
152
+ None
153
+ if task.resources.memory_mb is None
154
+ else task.resources.memory_mb * 1024 * 1024
155
+ ),
156
+ disk_bytes=(
157
+ None
158
+ if task.resources.ephemeral_disk_mb is None
159
+ else task.resources.ephemeral_disk_mb * 1024 * 1024
160
+ ),
161
+ gpu_count=0 if task.resources.gpu is None else task.resources.gpu.count,
141
162
  )
142
163
  )
143
164
  initialize_request: InitializeRequest = InitializeRequest(
@@ -9,6 +9,7 @@ from tensorlake.function_executor.proto.message_validator import MessageValidato
9
9
 
10
10
  from indexify.proto.executor_api_pb2 import (
11
11
  FunctionExecutorDescription,
12
+ FunctionExecutorResources,
12
13
  )
13
14
  from indexify.proto.executor_api_pb2 import (
14
15
  FunctionExecutorStatus as FunctionExecutorStatusProto,
@@ -42,6 +43,13 @@ def validate_function_executor_description(
42
43
  # image_uri is optional.
43
44
  # secret_names can be empty.
44
45
  # resource_limits is optional.
46
+ # TODO: Make resources required after we migrate Server to them.
47
+ # validator.required_field("resources")
48
+ # validator = MessageValidator(function_executor_description.resources)
49
+ # validator.required_field("cpu_ms_per_sec")
50
+ # validator.required_field("memory_bytes")
51
+ # validator.required_field("disk_bytes")
52
+ # validator.required_field("gpu_count")
45
53
 
46
54
 
47
55
  def function_executor_logger(
@@ -333,11 +341,24 @@ async def _create_function_executor(
333
341
  executor_id=executor_id,
334
342
  function_executor_id=function_executor_description.id,
335
343
  namespace=function_executor_description.namespace,
344
+ graph_name=function_executor_description.graph_name,
345
+ graph_version=function_executor_description.graph_version,
346
+ function_name=function_executor_description.function_name,
336
347
  image_uri=None,
337
348
  secret_names=list(function_executor_description.secret_names),
349
+ cpu_ms_per_sec=None,
350
+ memory_bytes=None,
351
+ disk_bytes=None,
352
+ gpu_count=0,
338
353
  )
339
354
  if function_executor_description.HasField("image_uri"):
340
355
  config.image_uri = function_executor_description.image_uri
356
+ if function_executor_description.HasField("resources"):
357
+ resources: FunctionExecutorResources = function_executor_description.resources
358
+ config.cpu_ms_per_sec = resources.cpu_ms_per_sec
359
+ config.memory_bytes = resources.memory_bytes
360
+ config.disk_bytes = resources.disk_bytes
361
+ config.gpu_count = resources.gpu_count
341
362
 
342
363
  initialize_request: InitializeRequest = InitializeRequest(
343
364
  namespace=function_executor_description.namespace,
@@ -9,9 +9,7 @@ from indexify.proto.executor_api_pb2 import (
9
9
  GetDesiredExecutorStatesRequest,
10
10
  TaskAllocation,
11
11
  )
12
- from indexify.proto.executor_api_pb2_grpc import (
13
- ExecutorAPIStub,
14
- )
12
+ from indexify.proto.executor_api_pb2_grpc import ExecutorAPIStub
15
13
 
16
14
  from ..downloader import Downloader
17
15
  from ..function_executor.function_executor_state import FunctionExecutorState
@@ -24,9 +24,7 @@ from indexify.proto.executor_api_pb2 import (
24
24
  HostResources,
25
25
  ReportExecutorStateRequest,
26
26
  )
27
- from indexify.proto.executor_api_pb2_grpc import (
28
- ExecutorAPIStub,
29
- )
27
+ from indexify.proto.executor_api_pb2_grpc import ExecutorAPIStub
30
28
 
31
29
  from ..api_objects import FunctionURI
32
30
  from ..executor_flavor import ExecutorFlavor
@@ -83,6 +83,15 @@ enum FunctionExecutorStatus {
83
83
  }
84
84
 
85
85
  // Immutable information that identifies and describes a Function Executor.
86
+ message FunctionExecutorResources {
87
+ // 1000 CPU ms per sec is one full CPU core.
88
+ // 2000 CPU ms per sec is two full CPU cores.
89
+ optional uint32 cpu_ms_per_sec = 1;
90
+ optional uint64 memory_bytes = 2;
91
+ optional uint64 disk_bytes = 3;
92
+ optional uint32 gpu_count = 4;
93
+ }
94
+
86
95
  message FunctionExecutorDescription {
87
96
  optional string id = 1;
88
97
  optional string namespace = 2;
@@ -95,6 +104,7 @@ message FunctionExecutorDescription {
95
104
  // Timeout for customer code duration during FE creation.
96
105
  optional uint32 customer_code_timeout_ms = 9;
97
106
  optional DataPayload graph = 10;
107
+ optional FunctionExecutorResources resources = 11;
98
108
  }
99
109
 
100
110
  message FunctionExecutorState {
@@ -150,6 +160,14 @@ message ReportExecutorStateResponse {
150
160
  }
151
161
 
152
162
  // ===== get_desired_executor_states RPC =====
163
+ message TaskRetryPolicy {
164
+ optional uint32 max_retries = 1;
165
+ optional uint32 initial_delay_ms = 2;
166
+ optional uint32 max_delay_ms = 3;
167
+ // The multiplier value is 1000x of the actual value to avoid working with floating point.
168
+ optional uint32 delay_multiplier = 4;
169
+ }
170
+
153
171
  message Task {
154
172
  optional string id = 1;
155
173
  optional string namespace = 2;
@@ -166,6 +184,7 @@ message Task {
166
184
  // S3 URI if the data is stored in S3.
167
185
  // Starts with "file://"" prefix followed by an absolute directory path if the data is stored on a local file system.
168
186
  optional string output_payload_uri_prefix = 13;
187
+ optional TaskRetryPolicy retry_policy = 14;
169
188
  }
170
189
 
171
190
  message TaskAllocation {
@@ -0,0 +1,86 @@
1
+ # -*- coding: utf-8 -*-
2
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
3
+ # NO CHECKED-IN PROTOBUF GENCODE
4
+ # source: indexify/proto/executor_api.proto
5
+ # Protobuf Python Version: 5.29.0
6
+ """Generated protocol buffer code."""
7
+ from google.protobuf import descriptor as _descriptor
8
+ from google.protobuf import descriptor_pool as _descriptor_pool
9
+ from google.protobuf import runtime_version as _runtime_version
10
+ from google.protobuf import symbol_database as _symbol_database
11
+ from google.protobuf.internal import builder as _builder
12
+
13
+ _runtime_version.ValidateProtobufRuntimeVersion(
14
+ _runtime_version.Domain.PUBLIC, 5, 29, 0, "", "indexify/proto/executor_api.proto"
15
+ )
16
+ # @@protoc_insertion_point(imports)
17
+
18
+ _sym_db = _symbol_database.Default()
19
+
20
+
21
+ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(
22
+ b'\n!indexify/proto/executor_api.proto\x12\x0f\x65xecutor_api_pb"\x87\x02\n\x0b\x44\x61taPayload\x12\x11\n\x04path\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x11\n\x04size\x18\x02 \x01(\x04H\x01\x88\x01\x01\x12\x18\n\x0bsha256_hash\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x10\n\x03uri\x18\x04 \x01(\tH\x03\x88\x01\x01\x12;\n\x08\x65ncoding\x18\x05 \x01(\x0e\x32$.executor_api_pb.DataPayloadEncodingH\x04\x88\x01\x01\x12\x1d\n\x10\x65ncoding_version\x18\x06 \x01(\x04H\x05\x88\x01\x01\x42\x07\n\x05_pathB\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"\xc5\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\x16\n\tgpu_count\x18\x04 \x01(\rH\x03\x88\x01\x01\x42\x11\n\x0f_cpu_ms_per_secB\x0f\n\r_memory_bytesB\r\n\x0b_disk_bytesB\x0c\n\n_gpu_count"\xbf\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\x0fresource_limits\x18\x08 \x01(\x0b\x32\x1e.executor_api_pb.HostResourcesH\x06\x88\x01\x01\x12%\n\x18\x63ustomer_code_timeout_ms\x18\t \x01(\rH\x07\x88\x01\x01\x12\x30\n\x05graph\x18\n \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x08\x88\x01\x01\x12\x42\n\tresources\x18\x0b \x01(\x0b\x32*.executor_api_pb.FunctionExecutorResourcesH\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\x12\n\x10_resource_limitsB\x1b\n\x19_customer_code_timeout_msB\x08\n\x06_graphB\x0c\n\n_resources"\xe8\x01\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\x12\x1b\n\x0estatus_message\x18\x03 \x01(\tH\x02\x88\x01\x01\x42\x0e\n\x0c_descriptionB\t\n\x07_statusB\x11\n\x0f_status_message"\xcb\x05\n\rExecutorState\x12\x18\n\x0b\x65xecutor_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x1d\n\x10\x64\x65velopment_mode\x18\x02 \x01(\x08H\x01\x88\x01\x01\x12\x15\n\x08hostname\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x34\n\x06\x66lavor\x18\x04 \x01(\x0e\x32\x1f.executor_api_pb.ExecutorFlavorH\x03\x88\x01\x01\x12\x14\n\x07version\x18\x05 \x01(\tH\x04\x88\x01\x01\x12\x34\n\x06status\x18\x06 \x01(\x0e\x32\x1f.executor_api_pb.ExecutorStatusH\x05\x88\x01\x01\x12;\n\x0e\x66ree_resources\x18\x07 \x01(\x0b\x32\x1e.executor_api_pb.HostResourcesH\x06\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\x07\x88\x01\x01\x12\x19\n\x0cserver_clock\x18\x0c \x01(\x04H\x08\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\x13\n\x11_development_modeB\x0b\n\t_hostnameB\t\n\x07_flavorB\n\n\x08_versionB\t\n\x07_statusB\x11\n\x0f_free_resourcesB\r\n\x0b_state_hashB\x0f\n\r_server_clock"l\n\x1aReportExecutorStateRequest\x12;\n\x0e\x65xecutor_state\x18\x01 \x01(\x0b\x32\x1e.executor_api_pb.ExecutorStateH\x00\x88\x01\x01\x42\x11\n\x0f_executor_state"\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"\xa4\x05\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\x16\n\tinput_key\x18\x08 \x01(\tH\x06\x88\x01\x01\x12\x1f\n\x12reducer_output_key\x18\t \x01(\tH\x07\x88\x01\x01\x12\x17\n\ntimeout_ms\x18\n \x01(\rH\x08\x88\x01\x01\x12\x30\n\x05input\x18\x0b \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\t\x88\x01\x01\x12\x38\n\rreducer_input\x18\x0c \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\n\x88\x01\x01\x12&\n\x19output_payload_uri_prefix\x18\r \x01(\tH\x0b\x88\x01\x01\x12;\n\x0cretry_policy\x18\x0e \x01(\x0b\x32 .executor_api_pb.TaskRetryPolicyH\x0c\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\x0c\n\n_input_keyB\x15\n\x13_reducer_output_keyB\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"\x7f\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\x42\x17\n\x15_function_executor_idB\x07\n\x05_task"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"\x87\x06\n\x18ReportTaskOutcomeRequest\x12\x14\n\x07task_id\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\rfunction_name\x18\x04 \x01(\tH\x03\x88\x01\x01\x12 \n\x13graph_invocation_id\x18\x06 \x01(\tH\x04\x88\x01\x01\x12\x32\n\x07outcome\x18\x07 \x01(\x0e\x32\x1c.executor_api_pb.TaskOutcomeH\x05\x88\x01\x01\x12\x1a\n\rinvocation_id\x18\x08 \x01(\tH\x06\x88\x01\x01\x12\x18\n\x0b\x65xecutor_id\x18\t \x01(\tH\x07\x88\x01\x01\x12\x14\n\x07reducer\x18\n \x01(\x08H\x08\x88\x01\x01\x12\x16\n\x0enext_functions\x18\x0b \x03(\t\x12\x30\n\nfn_outputs\x18\x0c \x03(\x0b\x32\x1c.executor_api_pb.DataPayload\x12\x31\n\x06stdout\x18\x0e \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\t\x88\x01\x01\x12\x31\n\x06stderr\x18\x0f \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\n\x88\x01\x01\x12=\n\x0foutput_encoding\x18\r \x01(\x0e\x32\x1f.executor_api_pb.OutputEncodingH\x0b\x88\x01\x01\x12$\n\x17output_encoding_version\x18\x05 \x01(\x04H\x0c\x88\x01\x01\x42\n\n\x08_task_idB\x0c\n\n_namespaceB\r\n\x0b_graph_nameB\x10\n\x0e_function_nameB\x16\n\x14_graph_invocation_idB\n\n\x08_outcomeB\x10\n\x0e_invocation_idB\x0e\n\x0c_executor_idB\n\n\x08_reducerB\t\n\x07_stdoutB\t\n\x07_stderrB\x12\n\x10_output_encodingB\x1a\n\x18_output_encoding_version"\x1b\n\x19ReportTaskOutcomeResponse*\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*\x86\x03\n\x08GPUModel\x12\x15\n\x11GPU_MODEL_UNKNOWN\x10\x00\x12"\n\x1eGPU_MODEL_NVIDIA_TESLA_T4_16GB\x10\n\x12$\n GPU_MODEL_NVIDIA_TESLA_V100_16GB\x10\x14\x12\x1d\n\x19GPU_MODEL_NVIDIA_A10_24GB\x10\x1e\x12\x1f\n\x1bGPU_MODEL_NVIDIA_A6000_48GB\x10(\x12#\n\x1fGPU_MODEL_NVIDIA_A100_SXM4_40GB\x10\x32\x12#\n\x1fGPU_MODEL_NVIDIA_A100_SXM4_80GB\x10\x33\x12"\n\x1eGPU_MODEL_NVIDIA_A100_PCI_40GB\x10\x34\x12#\n\x1fGPU_MODEL_NVIDIA_H100_SXM5_80GB\x10<\x12"\n\x1eGPU_MODEL_NVIDIA_H100_PCI_80GB\x10=\x12"\n\x1eGPU_MODEL_NVIDIA_RTX_6000_24GB\x10>*\xca\x03\n\x16\x46unctionExecutorStatus\x12$\n FUNCTION_EXECUTOR_STATUS_UNKNOWN\x10\x00\x12(\n$FUNCTION_EXECUTOR_STATUS_STARTING_UP\x10\x01\x12:\n6FUNCTION_EXECUTOR_STATUS_STARTUP_FAILED_CUSTOMER_ERROR\x10\x02\x12:\n6FUNCTION_EXECUTOR_STATUS_STARTUP_FAILED_PLATFORM_ERROR\x10\x03\x12!\n\x1d\x46UNCTION_EXECUTOR_STATUS_IDLE\x10\x04\x12)\n%FUNCTION_EXECUTOR_STATUS_RUNNING_TASK\x10\x05\x12&\n"FUNCTION_EXECUTOR_STATUS_UNHEALTHY\x10\x06\x12%\n!FUNCTION_EXECUTOR_STATUS_STOPPING\x10\x07\x12$\n FUNCTION_EXECUTOR_STATUS_STOPPED\x10\x08\x12%\n!FUNCTION_EXECUTOR_STATUS_SHUTDOWN\x10\t*\xc3\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\x1c\n\x18\x45XECUTOR_STATUS_STOPPING\x10\x04\x12\x1b\n\x17\x45XECUTOR_STATUS_STOPPED\x10\x05*d\n\x0e\x45xecutorFlavor\x12\x1b\n\x17\x45XECUTOR_FLAVOR_UNKNOWN\x10\x00\x12\x17\n\x13\x45XECUTOR_FLAVOR_OSS\x10\x01\x12\x1c\n\x18\x45XECUTOR_FLAVOR_PLATFORM\x10\x02*[\n\x0bTaskOutcome\x12\x18\n\x14TASK_OUTCOME_UNKNOWN\x10\x00\x12\x18\n\x14TASK_OUTCOME_SUCCESS\x10\x01\x12\x18\n\x14TASK_OUTCOME_FAILURE\x10\x02*\x7f\n\x0eOutputEncoding\x12\x1b\n\x17OUTPUT_ENCODING_UNKNOWN\x10\x00\x12\x18\n\x14OUTPUT_ENCODING_JSON\x10\x01\x12\x1a\n\x16OUTPUT_ENCODING_PICKLE\x10\x02\x12\x1a\n\x16OUTPUT_ENCODING_BINARY\x10\x03\x32\xef\x02\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\x12n\n\x13report_task_outcome\x12).executor_api_pb.ReportTaskOutcomeRequest\x1a*.executor_api_pb.ReportTaskOutcomeResponse"\x00\x62\x06proto3'
23
+ )
24
+
25
+ _globals = globals()
26
+ _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
27
+ _builder.BuildTopDescriptorsAndMessages(
28
+ DESCRIPTOR, "indexify.proto.executor_api_pb2", _globals
29
+ )
30
+ if not _descriptor._USE_C_DESCRIPTORS:
31
+ DESCRIPTOR._loaded_options = None
32
+ _globals["_EXECUTORSTATE_LABELSENTRY"]._loaded_options = None
33
+ _globals["_EXECUTORSTATE_LABELSENTRY"]._serialized_options = b"8\001"
34
+ _globals["_DATAPAYLOADENCODING"]._serialized_start = 4773
35
+ _globals["_DATAPAYLOADENCODING"]._serialized_end = 4944
36
+ _globals["_GPUMODEL"]._serialized_start = 4947
37
+ _globals["_GPUMODEL"]._serialized_end = 5337
38
+ _globals["_FUNCTIONEXECUTORSTATUS"]._serialized_start = 5340
39
+ _globals["_FUNCTIONEXECUTORSTATUS"]._serialized_end = 5798
40
+ _globals["_EXECUTORSTATUS"]._serialized_start = 5801
41
+ _globals["_EXECUTORSTATUS"]._serialized_end = 5996
42
+ _globals["_EXECUTORFLAVOR"]._serialized_start = 5998
43
+ _globals["_EXECUTORFLAVOR"]._serialized_end = 6098
44
+ _globals["_TASKOUTCOME"]._serialized_start = 6100
45
+ _globals["_TASKOUTCOME"]._serialized_end = 6191
46
+ _globals["_OUTPUTENCODING"]._serialized_start = 6193
47
+ _globals["_OUTPUTENCODING"]._serialized_end = 6320
48
+ _globals["_DATAPAYLOAD"]._serialized_start = 55
49
+ _globals["_DATAPAYLOAD"]._serialized_end = 318
50
+ _globals["_GPURESOURCES"]._serialized_start = 320
51
+ _globals["_GPURESOURCES"]._serialized_end = 421
52
+ _globals["_HOSTRESOURCES"]._serialized_start = 424
53
+ _globals["_HOSTRESOURCES"]._serialized_end = 618
54
+ _globals["_ALLOWEDFUNCTION"]._serialized_start = 621
55
+ _globals["_ALLOWEDFUNCTION"]._serialized_end = 808
56
+ _globals["_FUNCTIONEXECUTORRESOURCES"]._serialized_start = 811
57
+ _globals["_FUNCTIONEXECUTORRESOURCES"]._serialized_end = 1008
58
+ _globals["_FUNCTIONEXECUTORDESCRIPTION"]._serialized_start = 1011
59
+ _globals["_FUNCTIONEXECUTORDESCRIPTION"]._serialized_end = 1586
60
+ _globals["_FUNCTIONEXECUTORSTATE"]._serialized_start = 1589
61
+ _globals["_FUNCTIONEXECUTORSTATE"]._serialized_end = 1821
62
+ _globals["_EXECUTORSTATE"]._serialized_start = 1824
63
+ _globals["_EXECUTORSTATE"]._serialized_end = 2539
64
+ _globals["_EXECUTORSTATE_LABELSENTRY"]._serialized_start = 2359
65
+ _globals["_EXECUTORSTATE_LABELSENTRY"]._serialized_end = 2404
66
+ _globals["_REPORTEXECUTORSTATEREQUEST"]._serialized_start = 2541
67
+ _globals["_REPORTEXECUTORSTATEREQUEST"]._serialized_end = 2649
68
+ _globals["_REPORTEXECUTORSTATERESPONSE"]._serialized_start = 2651
69
+ _globals["_REPORTEXECUTORSTATERESPONSE"]._serialized_end = 2680
70
+ _globals["_TASKRETRYPOLICY"]._serialized_start = 2683
71
+ _globals["_TASKRETRYPOLICY"]._serialized_end = 2890
72
+ _globals["_TASK"]._serialized_start = 2893
73
+ _globals["_TASK"]._serialized_end = 3569
74
+ _globals["_TASKALLOCATION"]._serialized_start = 3571
75
+ _globals["_TASKALLOCATION"]._serialized_end = 3698
76
+ _globals["_GETDESIREDEXECUTORSTATESREQUEST"]._serialized_start = 3700
77
+ _globals["_GETDESIREDEXECUTORSTATESREQUEST"]._serialized_end = 3775
78
+ _globals["_DESIREDEXECUTORSTATE"]._serialized_start = 3778
79
+ _globals["_DESIREDEXECUTORSTATE"]._serialized_end = 3963
80
+ _globals["_REPORTTASKOUTCOMEREQUEST"]._serialized_start = 3966
81
+ _globals["_REPORTTASKOUTCOMEREQUEST"]._serialized_end = 4741
82
+ _globals["_REPORTTASKOUTCOMERESPONSE"]._serialized_start = 4743
83
+ _globals["_REPORTTASKOUTCOMERESPONSE"]._serialized_end = 4770
84
+ _globals["_EXECUTORAPI"]._serialized_start = 6323
85
+ _globals["_EXECUTORAPI"]._serialized_end = 6690
86
+ # @@protoc_insertion_point(module_scope)
@@ -189,6 +189,24 @@ class AllowedFunction(_message.Message):
189
189
  graph_version: _Optional[str] = ...,
190
190
  ) -> None: ...
191
191
 
192
+ class FunctionExecutorResources(_message.Message):
193
+ __slots__ = ("cpu_ms_per_sec", "memory_bytes", "disk_bytes", "gpu_count")
194
+ CPU_MS_PER_SEC_FIELD_NUMBER: _ClassVar[int]
195
+ MEMORY_BYTES_FIELD_NUMBER: _ClassVar[int]
196
+ DISK_BYTES_FIELD_NUMBER: _ClassVar[int]
197
+ GPU_COUNT_FIELD_NUMBER: _ClassVar[int]
198
+ cpu_ms_per_sec: int
199
+ memory_bytes: int
200
+ disk_bytes: int
201
+ gpu_count: int
202
+ def __init__(
203
+ self,
204
+ cpu_ms_per_sec: _Optional[int] = ...,
205
+ memory_bytes: _Optional[int] = ...,
206
+ disk_bytes: _Optional[int] = ...,
207
+ gpu_count: _Optional[int] = ...,
208
+ ) -> None: ...
209
+
192
210
  class FunctionExecutorDescription(_message.Message):
193
211
  __slots__ = (
194
212
  "id",
@@ -201,6 +219,7 @@ class FunctionExecutorDescription(_message.Message):
201
219
  "resource_limits",
202
220
  "customer_code_timeout_ms",
203
221
  "graph",
222
+ "resources",
204
223
  )
205
224
  ID_FIELD_NUMBER: _ClassVar[int]
206
225
  NAMESPACE_FIELD_NUMBER: _ClassVar[int]
@@ -212,6 +231,7 @@ class FunctionExecutorDescription(_message.Message):
212
231
  RESOURCE_LIMITS_FIELD_NUMBER: _ClassVar[int]
213
232
  CUSTOMER_CODE_TIMEOUT_MS_FIELD_NUMBER: _ClassVar[int]
214
233
  GRAPH_FIELD_NUMBER: _ClassVar[int]
234
+ RESOURCES_FIELD_NUMBER: _ClassVar[int]
215
235
  id: str
216
236
  namespace: str
217
237
  graph_name: str
@@ -222,6 +242,7 @@ class FunctionExecutorDescription(_message.Message):
222
242
  resource_limits: HostResources
223
243
  customer_code_timeout_ms: int
224
244
  graph: DataPayload
245
+ resources: FunctionExecutorResources
225
246
  def __init__(
226
247
  self,
227
248
  id: _Optional[str] = ...,
@@ -234,6 +255,7 @@ class FunctionExecutorDescription(_message.Message):
234
255
  resource_limits: _Optional[_Union[HostResources, _Mapping]] = ...,
235
256
  customer_code_timeout_ms: _Optional[int] = ...,
236
257
  graph: _Optional[_Union[DataPayload, _Mapping]] = ...,
258
+ resources: _Optional[_Union[FunctionExecutorResources, _Mapping]] = ...,
237
259
  ) -> None: ...
238
260
 
239
261
  class FunctionExecutorState(_message.Message):
@@ -335,6 +357,24 @@ class ReportExecutorStateResponse(_message.Message):
335
357
  __slots__ = ()
336
358
  def __init__(self) -> None: ...
337
359
 
360
+ class TaskRetryPolicy(_message.Message):
361
+ __slots__ = ("max_retries", "initial_delay_ms", "max_delay_ms", "delay_multiplier")
362
+ MAX_RETRIES_FIELD_NUMBER: _ClassVar[int]
363
+ INITIAL_DELAY_MS_FIELD_NUMBER: _ClassVar[int]
364
+ MAX_DELAY_MS_FIELD_NUMBER: _ClassVar[int]
365
+ DELAY_MULTIPLIER_FIELD_NUMBER: _ClassVar[int]
366
+ max_retries: int
367
+ initial_delay_ms: int
368
+ max_delay_ms: int
369
+ delay_multiplier: int
370
+ def __init__(
371
+ self,
372
+ max_retries: _Optional[int] = ...,
373
+ initial_delay_ms: _Optional[int] = ...,
374
+ max_delay_ms: _Optional[int] = ...,
375
+ delay_multiplier: _Optional[int] = ...,
376
+ ) -> None: ...
377
+
338
378
  class Task(_message.Message):
339
379
  __slots__ = (
340
380
  "id",
@@ -349,6 +389,7 @@ class Task(_message.Message):
349
389
  "input",
350
390
  "reducer_input",
351
391
  "output_payload_uri_prefix",
392
+ "retry_policy",
352
393
  )
353
394
  ID_FIELD_NUMBER: _ClassVar[int]
354
395
  NAMESPACE_FIELD_NUMBER: _ClassVar[int]
@@ -362,6 +403,7 @@ class Task(_message.Message):
362
403
  INPUT_FIELD_NUMBER: _ClassVar[int]
363
404
  REDUCER_INPUT_FIELD_NUMBER: _ClassVar[int]
364
405
  OUTPUT_PAYLOAD_URI_PREFIX_FIELD_NUMBER: _ClassVar[int]
406
+ RETRY_POLICY_FIELD_NUMBER: _ClassVar[int]
365
407
  id: str
366
408
  namespace: str
367
409
  graph_name: str
@@ -374,6 +416,7 @@ class Task(_message.Message):
374
416
  input: DataPayload
375
417
  reducer_input: DataPayload
376
418
  output_payload_uri_prefix: str
419
+ retry_policy: TaskRetryPolicy
377
420
  def __init__(
378
421
  self,
379
422
  id: _Optional[str] = ...,
@@ -388,6 +431,7 @@ class Task(_message.Message):
388
431
  input: _Optional[_Union[DataPayload, _Mapping]] = ...,
389
432
  reducer_input: _Optional[_Union[DataPayload, _Mapping]] = ...,
390
433
  output_payload_uri_prefix: _Optional[str] = ...,
434
+ retry_policy: _Optional[_Union[TaskRetryPolicy, _Mapping]] = ...,
391
435
  ) -> None: ...
392
436
 
393
437
  class TaskAllocation(_message.Message):
@@ -1,82 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
- # Generated by the protocol buffer compiler. DO NOT EDIT!
3
- # NO CHECKED-IN PROTOBUF GENCODE
4
- # source: indexify/proto/executor_api.proto
5
- # Protobuf Python Version: 5.29.0
6
- """Generated protocol buffer code."""
7
- from google.protobuf import descriptor as _descriptor
8
- from google.protobuf import descriptor_pool as _descriptor_pool
9
- from google.protobuf import runtime_version as _runtime_version
10
- from google.protobuf import symbol_database as _symbol_database
11
- from google.protobuf.internal import builder as _builder
12
-
13
- _runtime_version.ValidateProtobufRuntimeVersion(
14
- _runtime_version.Domain.PUBLIC, 5, 29, 0, "", "indexify/proto/executor_api.proto"
15
- )
16
- # @@protoc_insertion_point(imports)
17
-
18
- _sym_db = _symbol_database.Default()
19
-
20
-
21
- DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(
22
- b'\n!indexify/proto/executor_api.proto\x12\x0f\x65xecutor_api_pb"\x87\x02\n\x0b\x44\x61taPayload\x12\x11\n\x04path\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x11\n\x04size\x18\x02 \x01(\x04H\x01\x88\x01\x01\x12\x18\n\x0bsha256_hash\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x10\n\x03uri\x18\x04 \x01(\tH\x03\x88\x01\x01\x12;\n\x08\x65ncoding\x18\x05 \x01(\x0e\x32$.executor_api_pb.DataPayloadEncodingH\x04\x88\x01\x01\x12\x1d\n\x10\x65ncoding_version\x18\x06 \x01(\x04H\x05\x88\x01\x01\x42\x07\n\x05_pathB\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"\xed\x03\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\x0fresource_limits\x18\x08 \x01(\x0b\x32\x1e.executor_api_pb.HostResourcesH\x06\x88\x01\x01\x12%\n\x18\x63ustomer_code_timeout_ms\x18\t \x01(\rH\x07\x88\x01\x01\x12\x30\n\x05graph\x18\n \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\x08\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\x12\n\x10_resource_limitsB\x1b\n\x19_customer_code_timeout_msB\x08\n\x06_graph"\xe8\x01\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\x12\x1b\n\x0estatus_message\x18\x03 \x01(\tH\x02\x88\x01\x01\x42\x0e\n\x0c_descriptionB\t\n\x07_statusB\x11\n\x0f_status_message"\xcb\x05\n\rExecutorState\x12\x18\n\x0b\x65xecutor_id\x18\x01 \x01(\tH\x00\x88\x01\x01\x12\x1d\n\x10\x64\x65velopment_mode\x18\x02 \x01(\x08H\x01\x88\x01\x01\x12\x15\n\x08hostname\x18\x03 \x01(\tH\x02\x88\x01\x01\x12\x34\n\x06\x66lavor\x18\x04 \x01(\x0e\x32\x1f.executor_api_pb.ExecutorFlavorH\x03\x88\x01\x01\x12\x14\n\x07version\x18\x05 \x01(\tH\x04\x88\x01\x01\x12\x34\n\x06status\x18\x06 \x01(\x0e\x32\x1f.executor_api_pb.ExecutorStatusH\x05\x88\x01\x01\x12;\n\x0e\x66ree_resources\x18\x07 \x01(\x0b\x32\x1e.executor_api_pb.HostResourcesH\x06\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\x07\x88\x01\x01\x12\x19\n\x0cserver_clock\x18\x0c \x01(\x04H\x08\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\x13\n\x11_development_modeB\x0b\n\t_hostnameB\t\n\x07_flavorB\n\n\x08_versionB\t\n\x07_statusB\x11\n\x0f_free_resourcesB\r\n\x0b_state_hashB\x0f\n\r_server_clock"l\n\x1aReportExecutorStateRequest\x12;\n\x0e\x65xecutor_state\x18\x01 \x01(\x0b\x32\x1e.executor_api_pb.ExecutorStateH\x00\x88\x01\x01\x42\x11\n\x0f_executor_state"\x1d\n\x1bReportExecutorStateResponse"\xd6\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\x16\n\tinput_key\x18\x08 \x01(\tH\x06\x88\x01\x01\x12\x1f\n\x12reducer_output_key\x18\t \x01(\tH\x07\x88\x01\x01\x12\x17\n\ntimeout_ms\x18\n \x01(\rH\x08\x88\x01\x01\x12\x30\n\x05input\x18\x0b \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\t\x88\x01\x01\x12\x38\n\rreducer_input\x18\x0c \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\n\x88\x01\x01\x12&\n\x19output_payload_uri_prefix\x18\r \x01(\tH\x0b\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\x0c\n\n_input_keyB\x15\n\x13_reducer_output_keyB\r\n\x0b_timeout_msB\x08\n\x06_inputB\x10\n\x0e_reducer_inputB\x1c\n\x1a_output_payload_uri_prefix"\x7f\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\x42\x17\n\x15_function_executor_idB\x07\n\x05_task"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"\x87\x06\n\x18ReportTaskOutcomeRequest\x12\x14\n\x07task_id\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\rfunction_name\x18\x04 \x01(\tH\x03\x88\x01\x01\x12 \n\x13graph_invocation_id\x18\x06 \x01(\tH\x04\x88\x01\x01\x12\x32\n\x07outcome\x18\x07 \x01(\x0e\x32\x1c.executor_api_pb.TaskOutcomeH\x05\x88\x01\x01\x12\x1a\n\rinvocation_id\x18\x08 \x01(\tH\x06\x88\x01\x01\x12\x18\n\x0b\x65xecutor_id\x18\t \x01(\tH\x07\x88\x01\x01\x12\x14\n\x07reducer\x18\n \x01(\x08H\x08\x88\x01\x01\x12\x16\n\x0enext_functions\x18\x0b \x03(\t\x12\x30\n\nfn_outputs\x18\x0c \x03(\x0b\x32\x1c.executor_api_pb.DataPayload\x12\x31\n\x06stdout\x18\x0e \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\t\x88\x01\x01\x12\x31\n\x06stderr\x18\x0f \x01(\x0b\x32\x1c.executor_api_pb.DataPayloadH\n\x88\x01\x01\x12=\n\x0foutput_encoding\x18\r \x01(\x0e\x32\x1f.executor_api_pb.OutputEncodingH\x0b\x88\x01\x01\x12$\n\x17output_encoding_version\x18\x05 \x01(\x04H\x0c\x88\x01\x01\x42\n\n\x08_task_idB\x0c\n\n_namespaceB\r\n\x0b_graph_nameB\x10\n\x0e_function_nameB\x16\n\x14_graph_invocation_idB\n\n\x08_outcomeB\x10\n\x0e_invocation_idB\x0e\n\x0c_executor_idB\n\n\x08_reducerB\t\n\x07_stdoutB\t\n\x07_stderrB\x12\n\x10_output_encodingB\x1a\n\x18_output_encoding_version"\x1b\n\x19ReportTaskOutcomeResponse*\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*\x86\x03\n\x08GPUModel\x12\x15\n\x11GPU_MODEL_UNKNOWN\x10\x00\x12"\n\x1eGPU_MODEL_NVIDIA_TESLA_T4_16GB\x10\n\x12$\n GPU_MODEL_NVIDIA_TESLA_V100_16GB\x10\x14\x12\x1d\n\x19GPU_MODEL_NVIDIA_A10_24GB\x10\x1e\x12\x1f\n\x1bGPU_MODEL_NVIDIA_A6000_48GB\x10(\x12#\n\x1fGPU_MODEL_NVIDIA_A100_SXM4_40GB\x10\x32\x12#\n\x1fGPU_MODEL_NVIDIA_A100_SXM4_80GB\x10\x33\x12"\n\x1eGPU_MODEL_NVIDIA_A100_PCI_40GB\x10\x34\x12#\n\x1fGPU_MODEL_NVIDIA_H100_SXM5_80GB\x10<\x12"\n\x1eGPU_MODEL_NVIDIA_H100_PCI_80GB\x10=\x12"\n\x1eGPU_MODEL_NVIDIA_RTX_6000_24GB\x10>*\xca\x03\n\x16\x46unctionExecutorStatus\x12$\n FUNCTION_EXECUTOR_STATUS_UNKNOWN\x10\x00\x12(\n$FUNCTION_EXECUTOR_STATUS_STARTING_UP\x10\x01\x12:\n6FUNCTION_EXECUTOR_STATUS_STARTUP_FAILED_CUSTOMER_ERROR\x10\x02\x12:\n6FUNCTION_EXECUTOR_STATUS_STARTUP_FAILED_PLATFORM_ERROR\x10\x03\x12!\n\x1d\x46UNCTION_EXECUTOR_STATUS_IDLE\x10\x04\x12)\n%FUNCTION_EXECUTOR_STATUS_RUNNING_TASK\x10\x05\x12&\n"FUNCTION_EXECUTOR_STATUS_UNHEALTHY\x10\x06\x12%\n!FUNCTION_EXECUTOR_STATUS_STOPPING\x10\x07\x12$\n FUNCTION_EXECUTOR_STATUS_STOPPED\x10\x08\x12%\n!FUNCTION_EXECUTOR_STATUS_SHUTDOWN\x10\t*\xc3\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\x1c\n\x18\x45XECUTOR_STATUS_STOPPING\x10\x04\x12\x1b\n\x17\x45XECUTOR_STATUS_STOPPED\x10\x05*d\n\x0e\x45xecutorFlavor\x12\x1b\n\x17\x45XECUTOR_FLAVOR_UNKNOWN\x10\x00\x12\x17\n\x13\x45XECUTOR_FLAVOR_OSS\x10\x01\x12\x1c\n\x18\x45XECUTOR_FLAVOR_PLATFORM\x10\x02*[\n\x0bTaskOutcome\x12\x18\n\x14TASK_OUTCOME_UNKNOWN\x10\x00\x12\x18\n\x14TASK_OUTCOME_SUCCESS\x10\x01\x12\x18\n\x14TASK_OUTCOME_FAILURE\x10\x02*\x7f\n\x0eOutputEncoding\x12\x1b\n\x17OUTPUT_ENCODING_UNKNOWN\x10\x00\x12\x18\n\x14OUTPUT_ENCODING_JSON\x10\x01\x12\x1a\n\x16OUTPUT_ENCODING_PICKLE\x10\x02\x12\x1a\n\x16OUTPUT_ENCODING_BINARY\x10\x03\x32\xef\x02\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\x12n\n\x13report_task_outcome\x12).executor_api_pb.ReportTaskOutcomeRequest\x1a*.executor_api_pb.ReportTaskOutcomeResponse"\x00\x62\x06proto3'
23
- )
24
-
25
- _globals = globals()
26
- _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
27
- _builder.BuildTopDescriptorsAndMessages(
28
- DESCRIPTOR, "indexify.proto.executor_api_pb2", _globals
29
- )
30
- if not _descriptor._USE_C_DESCRIPTORS:
31
- DESCRIPTOR._loaded_options = None
32
- _globals["_EXECUTORSTATE_LABELSENTRY"]._loaded_options = None
33
- _globals["_EXECUTORSTATE_LABELSENTRY"]._serialized_options = b"8\001"
34
- _globals["_DATAPAYLOADENCODING"]._serialized_start = 4203
35
- _globals["_DATAPAYLOADENCODING"]._serialized_end = 4374
36
- _globals["_GPUMODEL"]._serialized_start = 4377
37
- _globals["_GPUMODEL"]._serialized_end = 4767
38
- _globals["_FUNCTIONEXECUTORSTATUS"]._serialized_start = 4770
39
- _globals["_FUNCTIONEXECUTORSTATUS"]._serialized_end = 5228
40
- _globals["_EXECUTORSTATUS"]._serialized_start = 5231
41
- _globals["_EXECUTORSTATUS"]._serialized_end = 5426
42
- _globals["_EXECUTORFLAVOR"]._serialized_start = 5428
43
- _globals["_EXECUTORFLAVOR"]._serialized_end = 5528
44
- _globals["_TASKOUTCOME"]._serialized_start = 5530
45
- _globals["_TASKOUTCOME"]._serialized_end = 5621
46
- _globals["_OUTPUTENCODING"]._serialized_start = 5623
47
- _globals["_OUTPUTENCODING"]._serialized_end = 5750
48
- _globals["_DATAPAYLOAD"]._serialized_start = 55
49
- _globals["_DATAPAYLOAD"]._serialized_end = 318
50
- _globals["_GPURESOURCES"]._serialized_start = 320
51
- _globals["_GPURESOURCES"]._serialized_end = 421
52
- _globals["_HOSTRESOURCES"]._serialized_start = 424
53
- _globals["_HOSTRESOURCES"]._serialized_end = 618
54
- _globals["_ALLOWEDFUNCTION"]._serialized_start = 621
55
- _globals["_ALLOWEDFUNCTION"]._serialized_end = 808
56
- _globals["_FUNCTIONEXECUTORDESCRIPTION"]._serialized_start = 811
57
- _globals["_FUNCTIONEXECUTORDESCRIPTION"]._serialized_end = 1304
58
- _globals["_FUNCTIONEXECUTORSTATE"]._serialized_start = 1307
59
- _globals["_FUNCTIONEXECUTORSTATE"]._serialized_end = 1539
60
- _globals["_EXECUTORSTATE"]._serialized_start = 1542
61
- _globals["_EXECUTORSTATE"]._serialized_end = 2257
62
- _globals["_EXECUTORSTATE_LABELSENTRY"]._serialized_start = 2077
63
- _globals["_EXECUTORSTATE_LABELSENTRY"]._serialized_end = 2122
64
- _globals["_REPORTEXECUTORSTATEREQUEST"]._serialized_start = 2259
65
- _globals["_REPORTEXECUTORSTATEREQUEST"]._serialized_end = 2367
66
- _globals["_REPORTEXECUTORSTATERESPONSE"]._serialized_start = 2369
67
- _globals["_REPORTEXECUTORSTATERESPONSE"]._serialized_end = 2398
68
- _globals["_TASK"]._serialized_start = 2401
69
- _globals["_TASK"]._serialized_end = 2999
70
- _globals["_TASKALLOCATION"]._serialized_start = 3001
71
- _globals["_TASKALLOCATION"]._serialized_end = 3128
72
- _globals["_GETDESIREDEXECUTORSTATESREQUEST"]._serialized_start = 3130
73
- _globals["_GETDESIREDEXECUTORSTATESREQUEST"]._serialized_end = 3205
74
- _globals["_DESIREDEXECUTORSTATE"]._serialized_start = 3208
75
- _globals["_DESIREDEXECUTORSTATE"]._serialized_end = 3393
76
- _globals["_REPORTTASKOUTCOMEREQUEST"]._serialized_start = 3396
77
- _globals["_REPORTTASKOUTCOMEREQUEST"]._serialized_end = 4171
78
- _globals["_REPORTTASKOUTCOMERESPONSE"]._serialized_start = 4173
79
- _globals["_REPORTTASKOUTCOMERESPONSE"]._serialized_end = 4200
80
- _globals["_EXECUTORAPI"]._serialized_start = 5753
81
- _globals["_EXECUTORAPI"]._serialized_end = 6120
82
- # @@protoc_insertion_point(module_scope)
File without changes