#[non_exhaustive]pub enum FlowEvent {
Show 27 variants
RunCreated {
spec: WorkflowSpec,
input: JsonValue,
},
RunStarted,
RunCompleted {
output: JsonValue,
},
RunFailed {
error: String,
},
RunCancellationRequested {
request: CancellationRequest,
},
RunCancelled {
reason: Option<String>,
},
RunTimedOut {
deadline: DateTime<Utc>,
reason: Option<String>,
},
RunRetryExhausted {
step_id: String,
attempt: u32,
error: String,
},
RunHostShutdown {
reason: Option<String>,
},
RunContinuedAsNew {
successor_run_id: String,
input: JsonValue,
},
RunProgressRecorded {
progress: WorkflowProgress,
},
ChildOperationLinked {
child: ChildOperationReference,
},
ChildWorkflowRequested {
child_id: String,
child_run_id: String,
spec: WorkflowSpec,
input: JsonValue,
cancellation_policy: ChildWorkflowCancellationPolicy,
},
ChildWorkflowResolved {
child_id: String,
outcome: WorkflowTerminalOutcome,
},
SignalReceived {
signal: WorkflowSignal,
},
SignalWaitCreated {
wait_id: String,
signal_name: String,
},
SignalWaitCompleted {
wait_id: String,
signal_id: String,
},
StepCreated {
step_id: String,
step_name: String,
input: JsonValue,
retry: RetryPolicy,
},
StepStarted {
step_id: String,
attempt: u32,
},
StepCompleted {
step_id: String,
output: JsonValue,
},
StepRetrying {
step_id: String,
attempt: u32,
error: String,
retry_after: Option<DateTime<Utc>>,
},
StepFailed {
step_id: String,
attempt: u32,
error: String,
},
WaitCreated {
wait_id: String,
resume_at: DateTime<Utc>,
},
WaitCompleted {
wait_id: String,
},
HookCreated {
hook_id: String,
token: String,
metadata: JsonValue,
},
HookReceived {
hook_id: String,
payload: JsonValue,
},
HookDisposed {
hook_id: String,
},
}Expand description
Event persisted as the single source of truth for a workflow run.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
RunCreated
Creates a run with its immutable definition and initial input.
Fields
spec: WorkflowSpecWorkflow definition pinned to the run.
RunStarted
Marks the run as actively executing.
RunCompleted
Completes the run successfully.
RunFailed
Terminates the run with an application or runtime error.
RunCancellationRequested
Records a cleanup-aware cancellation request.
Fields
request: CancellationRequestImmutable cancellation request delivered during replay.
RunCancelled
Completes a requested or forced cancellation.
RunTimedOut
Terminates the run because its deadline elapsed.
Fields
RunRetryExhausted
Terminates the run after a step uses all permitted attempts.
Fields
RunHostShutdown
Terminates the run because its owning host shut down.
RunContinuedAsNew
Closes this history and links it to a successor run.
Fields
RunProgressRecorded
Persists the workflow’s latest durable progress report.
Fields
progress: WorkflowProgressProgress value made visible to inspectors and observers.
ChildOperationLinked
Links an externally managed child operation to the run.
Fields
child: ChildOperationReferenceStable reference to the linked operation.
ChildWorkflowRequested
Requests a first-class child workflow.
Fields
spec: WorkflowSpecWorkflow definition used to create the child.
cancellation_policy: ChildWorkflowCancellationPolicyPolicy applied when the parent is cancelled or terminated.
ChildWorkflowResolved
Records the terminal result observed from a child workflow.
Fields
outcome: WorkflowTerminalOutcomeTerminal outcome returned by the child.
SignalReceived
Persists one named asynchronous signal.
Fields
signal: WorkflowSignalSignal identity, name, payload, and receipt metadata.
SignalWaitCreated
Creates a replay-stable wait for a named signal.
Fields
SignalWaitCompleted
Pairs a waiting command with one received signal.
Fields
StepCreated
Creates a durable step invocation.
Fields
retry: RetryPolicyRetry behavior pinned when the step is created.
StepStarted
Marks one step attempt as started.
StepCompleted
Records the successful output of a step.
Fields
StepRetrying
Records a failed attempt that will be retried.
Fields
StepFailed
Records a step that exhausted its retry policy.
Fields
WaitCreated
Creates a durable timer wait.
Fields
WaitCompleted
Marks a durable timer wait as ready.
HookCreated
Creates an externally completable hook.
Fields
HookReceived
Records a payload delivered to a hook.
Fields
HookDisposed
Permanently closes a hook without another payload.