durabletask 0.0.0.dev28__tar.gz → 0.0.0.dev30__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.
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/PKG-INFO +1 -1
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/client.py +4 -1
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/task.py +3 -3
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/worker.py +8 -8
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask.egg-info/PKG-INFO +1 -1
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/pyproject.toml +1 -1
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/LICENSE +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/README.md +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/__init__.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/entities/__init__.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/entities/durable_entity.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/entities/entity_context.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/entities/entity_instance_id.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/entities/entity_lock.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/entities/entity_metadata.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/entity_state_shim.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/exceptions.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/grpc_interceptor.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/helpers.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/orchestration_entity_context.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/orchestrator_service_pb2.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/orchestrator_service_pb2.pyi +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/orchestrator_service_pb2_grpc.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/proto_task_hub_sidecar_service_stub.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/shared.py +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/py.typed +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask.egg-info/SOURCES.txt +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask.egg-info/dependency_links.txt +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask.egg-info/requires.txt +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask.egg-info/top_level.txt +0 -0
- {durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/setup.cfg +0 -0
|
@@ -230,7 +230,10 @@ class TaskHubGrpcClient:
|
|
|
230
230
|
self._logger.info(f"Purging instance '{instance_id}'.")
|
|
231
231
|
self._stub.PurgeInstances(req)
|
|
232
232
|
|
|
233
|
-
def signal_entity(self,
|
|
233
|
+
def signal_entity(self,
|
|
234
|
+
entity_instance_id: EntityInstanceId,
|
|
235
|
+
operation_name: str,
|
|
236
|
+
input: Optional[Any] = None) -> None:
|
|
234
237
|
req = pb.SignalEntityRequest(
|
|
235
238
|
instanceId=str(entity_instance_id),
|
|
236
239
|
name=operation_name,
|
|
@@ -142,7 +142,7 @@ class OrchestrationContext(ABC):
|
|
|
142
142
|
def call_entity(self,
|
|
143
143
|
entity: EntityInstanceId,
|
|
144
144
|
operation: str,
|
|
145
|
-
input: Optional[TInput] = None) -> CompletableTask:
|
|
145
|
+
input: Optional[TInput] = None) -> CompletableTask[Any]:
|
|
146
146
|
"""Schedule entity function for execution.
|
|
147
147
|
|
|
148
148
|
Parameters
|
|
@@ -538,8 +538,8 @@ class ActivityContext:
|
|
|
538
538
|
return self._task_id
|
|
539
539
|
|
|
540
540
|
|
|
541
|
-
# Orchestrators are generators that yield tasks
|
|
542
|
-
Orchestrator = Callable[[OrchestrationContext, TInput], Union[Generator[Task, Any,
|
|
541
|
+
# Orchestrators are generators that yield tasks, receive any type, and return TOutput
|
|
542
|
+
Orchestrator = Callable[[OrchestrationContext, TInput], Union[Generator[Task[Any], Any, TOutput], TOutput]]
|
|
543
543
|
|
|
544
544
|
# Activities are simple functions that can be scheduled by orchestrators
|
|
545
545
|
Activity = Callable[[ActivityContext, TInput], TOutput]
|
|
@@ -150,7 +150,7 @@ class _Registry:
|
|
|
150
150
|
self.entities = {}
|
|
151
151
|
self.entity_instances = {}
|
|
152
152
|
|
|
153
|
-
def add_orchestrator(self, fn: task.Orchestrator) -> str:
|
|
153
|
+
def add_orchestrator(self, fn: task.Orchestrator[TInput, TOutput]) -> str:
|
|
154
154
|
if fn is None:
|
|
155
155
|
raise ValueError("An orchestrator function argument is required.")
|
|
156
156
|
|
|
@@ -158,7 +158,7 @@ class _Registry:
|
|
|
158
158
|
self.add_named_orchestrator(name, fn)
|
|
159
159
|
return name
|
|
160
160
|
|
|
161
|
-
def add_named_orchestrator(self, name: str, fn: task.Orchestrator) -> None:
|
|
161
|
+
def add_named_orchestrator(self, name: str, fn: task.Orchestrator[TInput, TOutput]) -> None:
|
|
162
162
|
if not name:
|
|
163
163
|
raise ValueError("A non-empty orchestrator name is required.")
|
|
164
164
|
if name in self.orchestrators:
|
|
@@ -166,10 +166,10 @@ class _Registry:
|
|
|
166
166
|
|
|
167
167
|
self.orchestrators[name] = fn
|
|
168
168
|
|
|
169
|
-
def get_orchestrator(self, name: str) -> Optional[task.Orchestrator]:
|
|
169
|
+
def get_orchestrator(self, name: str) -> Optional[task.Orchestrator[Any, Any]]:
|
|
170
170
|
return self.orchestrators.get(name)
|
|
171
171
|
|
|
172
|
-
def add_activity(self, fn: task.Activity) -> str:
|
|
172
|
+
def add_activity(self, fn: task.Activity[TInput, TOutput]) -> str:
|
|
173
173
|
if fn is None:
|
|
174
174
|
raise ValueError("An activity function argument is required.")
|
|
175
175
|
|
|
@@ -177,7 +177,7 @@ class _Registry:
|
|
|
177
177
|
self.add_named_activity(name, fn)
|
|
178
178
|
return name
|
|
179
179
|
|
|
180
|
-
def add_named_activity(self, name: str, fn: task.Activity) -> None:
|
|
180
|
+
def add_named_activity(self, name: str, fn: task.Activity[TInput, TOutput]) -> None:
|
|
181
181
|
if not name:
|
|
182
182
|
raise ValueError("A non-empty activity name is required.")
|
|
183
183
|
if name in self.activities:
|
|
@@ -185,7 +185,7 @@ class _Registry:
|
|
|
185
185
|
|
|
186
186
|
self.activities[name] = fn
|
|
187
187
|
|
|
188
|
-
def get_activity(self, name: str) -> Optional[task.Activity]:
|
|
188
|
+
def get_activity(self, name: str) -> Optional[task.Activity[Any, Any]]:
|
|
189
189
|
return self.activities.get(name)
|
|
190
190
|
|
|
191
191
|
def add_entity(self, fn: task.Entity, name: Optional[str] = None) -> str:
|
|
@@ -360,7 +360,7 @@ class TaskHubGrpcWorker:
|
|
|
360
360
|
def __exit__(self, type, value, traceback):
|
|
361
361
|
self.stop()
|
|
362
362
|
|
|
363
|
-
def add_orchestrator(self, fn: task.Orchestrator) -> str:
|
|
363
|
+
def add_orchestrator(self, fn: task.Orchestrator[TInput, TOutput]) -> str:
|
|
364
364
|
"""Registers an orchestrator function with the worker."""
|
|
365
365
|
if self._is_running:
|
|
366
366
|
raise RuntimeError(
|
|
@@ -1045,7 +1045,7 @@ class _RuntimeOrchestrationContext(task.OrchestrationContext):
|
|
|
1045
1045
|
entity: EntityInstanceId,
|
|
1046
1046
|
operation: str,
|
|
1047
1047
|
input: Optional[TInput] = None,
|
|
1048
|
-
) -> task.CompletableTask:
|
|
1048
|
+
) -> task.CompletableTask[Any]:
|
|
1049
1049
|
id = self.next_sequence_number()
|
|
1050
1050
|
|
|
1051
1051
|
self.call_entity_function_helper(
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/entities/entity_instance_id.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/entity_state_shim.py
RENAMED
|
File without changes
|
|
File without changes
|
{durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/grpc_interceptor.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask/internal/orchestrator_service_pb2.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{durabletask-0.0.0.dev28 → durabletask-0.0.0.dev30}/durabletask.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|