Skip to content

@workflowbuilder/temporal@0.2.0

Latest

Choose a tag to compare

@github-actions github-actions released this 02 Oct 15:09
· 32 commits to main since this release
4848114

A node can park the run until a verdict from outside resumes it. Event Histories recorded by 0.1.0 still replay; the breaking changes concern custom ports, stores and code that reads node results.

Added

  • TemporalWorkflowEngine.resolveNode and the resolveNodeUpdate Workflow Update (RESOLVE_NODE_UPDATE_NAME): a node executor can return { waiting: true } to park the run until resolveNode delivers the node's completion. Refusals come back as a ResolveNodeResult, and resolveTimeoutMs bounds the wait for acceptance.
  • outcome on a node completion: declares the run's result, which the terminal completed write passes to updateExecutionStatus as a fourth argument.

Changed

  • Breaking. Widen NodeExecutionResult to CompletedNodeExecution | WaitingNodeExecution. Narrow on waiting before reading .output.
  • Breaking. Require resolveNode on a custom WorkflowEnginePort. It takes a ResolveNodeInput ({ executionId, nodeId, resolution }).
  • Breaking. Send the node_waiting event and the waiting and running statuses to the ExecutionStore. They can arrive after a cancel or a terminal status, so the store must not let them replace a cancel it recorded or a terminal status.