Expand description
Shared workflow operation handlers used by transports. Shared handler layer over Engine.
Module layout:
deploy— operator deploy (load/list/route/unload) handlers.workflows— start/signal/query/cancel workflow operation handlers.visibility— the shared list handler.describe— describe-workflow handler.runs— run-id resolution and terminal-status reads.payload— required-field and envelope encode/decode helpers.managed_workers— the managed-worker projection and failure mapping shared byGET /workers/managedandDeployService.error— engine-error-to-wire-error mapping.
Modules§
- deploy
- Operator deploy handlers shared by both transports. Shared operator-deploy handlers used by both transports.
Structs§
- RunDocument
Access - An authorized read of one workflow’s document under one package hash: the caller is scoped, the workflow is theirs, and the hash is one the workflow’s own history recorded. Holds the scoped engine so the archive read that follows happens in the same scope the check ran in.
Constants§
- RUN_
PACKAGE_ NOT_ RECORDED - The error type of a well-formed hash no generation of the workflow started
under. Distinct from
WorkflowNotFound(the workflow itself) and from the archive refusals (DeployedVersionNotFound,DeployedAwlSourceAbsent).
Functions§
- authorize_
run_ document - Authorizes a run-document read: scopes the caller to
namespaceand verifies the workflow exactly asdescribedoes, then requirescontent_hashto be recorded on one of the workflow’sWorkflowStartedevents (any generation of its continue-as-new chain). - cancel
- Handles a decoded cancel request.
- describe
- Handles a decoded describe-workflow request.
- list
- Handles a list-workflows request: one page of the contract, read from the visibility projection through the scoped engine.
- pause
- Handles a decoded pause request (#204).
- query
- Handles a decoded query request.
- rename
- Handles a decoded rename request (#211).
- reopen
- Handles a decoded reopen request.
- resume
- Handles a decoded resume request (#204).
- retire_
workloop - Retires a WORKLOOP: runs its declared
retirebody (when its deployed document declares one), recordsLoopRetired+ itsWorkflowCompletedterminal in one atomic batch, and removes the loop from the sweep set. - signal
- Handles a decoded signal request.
- start
- Handles a decoded start-workflow request.
- start_
with_ placement - Start a workflow, optionally with a
placementid chosen by the routing edge so the new execution lands on a locally-owned shard (R-1 unsteered-start remint).placement = Noneis the default path: the engine mints the id, so the single-node / non-clustered behaviour is unchanged.