Workflow-side stream object for Workflow Streams.
Instantiate WorkflowStream once from your workflow's @workflow.init
method. The constructor registers the stream signal, update, and query
handlers on the current workflow via
temporalio.workflow.set_signal_handler,
temporalio.workflow.set_update_handler, and
temporalio.workflow.set_query_handler.
For workflows that support continue-as-new, include a WorkflowStreamState | None field on the workflow input and pass it as prior_state — it is None on fresh starts and carries accumulated state on continue-as-new.
Workflow-side and client-side topic handles
(WorkflowTopicHandle.publish and
TopicHandle.publish) both use the synchronous payload
converter for per-item Payload construction. The codec chain
(e.g. encryption, compression) is not run per item on either
side — it runs once at the envelope level when Temporal's SDK
encodes the signal/update that carries the batch. Running it per
item as well would double-encrypt, because every signal arg
already goes through the client's DataConverter.encode at
dispatch time.
| Type Variable | T |
Undocumented |
| Function | _payload |
Approximate poll-response contribution of a single item. |
| Constant | _MAX |
Undocumented |
| Constant | _OFFSET |
Undocumented |
| Constant | _POLL |
Undocumented |
| Constant | _PUBLISH |
Undocumented |