You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
return MyOutput(message=f"Hello {input.name} from sync operation!")
157
155
```
158
156
157
+
158
+
A synchronous operation handler must return quickly (less than `10s`).
159
+
In addition to performing simple CPU-bound computations such as the one above, implementations are free to make arbitrary calls to other services or databases.
160
+
The handler function can access an SDK client that can be used to execute Signals, Updates, or Queries against a Workflow, or to do other client operations such as listing Workflows.
161
+
The [nexus_sync_operations](https://github.com/temporalio/samples-python/blob/main/nexus_sync_operations) shows how to create a Nexus Service uses synchronous operations to send Updates and Queries:
In addition to `nexus.client()`, you can use `nexus.info()` to access information about the currently-executing Nexus Operation including its Task Queue.
182
+
183
+
159
184
### Develop an Asynchronous Nexus Operation handler to start a Workflow
160
185
161
186
Use the `@nexus.workflow_run_operation` decorator, which is the easiest way to expose a Workflow as an operation.
0 commit comments