Skip to main content

Crate a3s_flow

Crate a3s_flow 

Source
Expand description

Durable workflow engine core for A3S.

a3s-flow models the Workflow SDK style of durable execution as a Rust core: workflow runs are event-sourced, step results are persisted, waits and hooks suspend without burning compute, named signals queue in history, first-class child runs have durable lifecycle policy, and the actual workflow interpreter is a pluggable runtime. The native TypeScript runtime boundary compiles source once, then invokes the compiled executable through a small JSON protocol.

Structs§

A3sEventBusFlowEventSink
Sink that publishes bridged Flow events into an A3S Event bus.
A3sFlowEvent
A3S-style event record derived from a committed FlowEventEnvelope.
A3sFlowEventBridge
Observer adapter that maps Flow envelopes to A3S-style event records.
A3sFlowEventSubject
Subject touched by a workflow event.
ActiveHookSnapshot
Active external callback hook with the run that owns it.
BootFlowTaskManager
A3S Boot-backed task manager for Flow scheduler and callback dispatch.
BootFlowTaskPolicy
Typed Boot queue policy applied to every task dispatched by one manager.
CancellationRequest
Durable request for a workflow to stop through its cleanup-aware path.
CancellationRequestSnapshot
Projected cancellation request with its durable event position.
ChildOperationReference
Durable reference from a parent workflow to a child operation.
ChildWorkflowSnapshot
Parent-owned projection of one first-class child workflow execution.
FanoutFlowEventObserver
Observer that forwards every committed event to multiple observers.
FlowEngine
Event-sourced workflow engine.
FlowEngineBuilder
Builder for a FlowEngine.
FlowEventEnvelope
Stored event with per-run sequence and timestamp.
FlowHistoryHold
Persistent reason that prevents a run history from being pruned.
FlowHistoryRetentionPolicy
Bounded policy for deleting complete terminal histories.
FlowHistoryRetentionReport
Detailed result of a terminal-history retention scan.
FlowHistoryTombstone
Minimal audit record retained after a complete event history is deleted.
FlowScheduler
Scheduler that scans durable state once and enqueues one task per due run.
FlowSchedulerTick
Result of one scheduler scan and its targeted per-run dispatches.
FlowTaskLease
Leased task returned by a queue worker before acknowledgement.
FlowTaskOutcome
Result of handling one queued FlowTask.
FlowWorker
Worker that handles queued workflow tasks against a FlowEngine.
FlowWorkflowIdentity
Low-cardinality workflow identity copied from the run-created event.
HookCallbackRoute
HTTP route metadata for external hook callbacks.
HookMetadata
Typed helper for common hook metadata fields.
HookSnapshot
Materialized state of one external callback hook.
InMemoryA3sFlowEventSink
In-memory A3S event sink for examples and tests.
InMemoryEventStore
In-memory event store for tests, local development, and embedded hosts.
InMemoryFlowEventObserver
In-memory observer for tests, local debugging, and embedded hosts.
InMemoryFlowTaskQueue
In-process FIFO queue for tests, embedded hosts, and local workers.
LocalFileA3sFlowEventSink
JSONL-backed A3S Flow event sink for local audit logs.
LocalFileDeadLetteredTask
Task moved out of inflight dispatch after exceeding a local lease policy.
LocalFileEventStore
JSONL-backed event store for local durable runs.
LocalFileFlowTaskQueue
JSON-backed local durable task queue.
NativeRuntimeRequest
Versioned request envelope sent to a native TypeScript executable.
NativeRuntimeResponse
Versioned response envelope returned by a native TypeScript executable.
NativeTsCompilerCapabilities
Capabilities reported by the installable native TypeScript compiler.
NativeTsDependencyManifest
Compiler-owned source graph used to bind native artifacts to every input.
NativeTsRuntime
Runtime that compiles TypeScript to a native executable and speaks JSON over stdin/stdout with that executable.
NativeTsRuntimeConfig
Configuration for the native TypeScript runtime adapter.
NativeTsRuntimePreflight
Result of validating and compiling a native TypeScript workflow source.
NoopFlowEventObserver
Observer that intentionally drops all events.
PostgresDeadLetteredTask
Task moved out of Postgres inflight dispatch after exceeding a lease policy.
PostgresEventStore
A3S ORM-backed PostgreSQL event store for multi-process durable hosts.
PostgresFlowTaskQueue
A3S ORM-backed PostgreSQL task queue for shared workers.
RetryPolicy
Retry behavior for a step command.
RuntimeBuildCompatibility
Runtime builds one engine instance can execute deterministically.
RuntimeBuildId
Immutable identity of a deployed workflow runtime build.
RuntimeBuildTaskRouter
Routes pinned Flow tasks to dispatchers serving exact runtime builds.
RuntimeSpec
Runtime metadata stored with a run so replay can happen on another process.
ScheduledWakeup
Minimal indexed record for a wait timer or delayed step retry.
SignalWaitSnapshot
A deterministic workflow wait for the next unconsumed signal of one name.
SqliteEventStore
A3S ORM-backed SQLite event store for single-node durable hosts.
StepCommand
Step definition returned by workflow replay.
StepInvocation
Step execution request passed to a runtime implementation.
StepSnapshot
Materialized state of one durable step.
WaitSnapshot
Materialized state of one durable timer wait.
WorkflowContext
Replay helper for Rust workflow runtimes.
WorkflowContinuation
Durable link from a closed history segment to its successor run.
WorkflowDag
Authoring graph containing workflow nodes, edges, and canvas metadata.
WorkflowDagEdge
One directed connection between workflow DAG nodes.
WorkflowDagNode
One semantic node in a workflow authoring graph.
WorkflowDagPlan
Deterministic topological node order grouped by container scope.
WorkflowDsl
Lossless representation of an imported A3S workflow DSL document.
WorkflowDslApp
Application identity and authoring mode from a workflow DSL document.
WorkflowDslBody
Workflow-specific body of a DSL document.
WorkflowInvocation
Workflow replay request passed to a runtime implementation.
WorkflowPatchId
Stable identity of a replay-safe workflow code change.
WorkflowProgress
A durable, idempotently identified progress update.
WorkflowRunSnapshot
Materialized state of a workflow run.
WorkflowRunSummary
Aggregated run counts for host dashboards and health probes.
WorkflowSignal
One durable asynchronous message delivered to a workflow execution.
WorkflowSignalSnapshot
A received signal together with its durable history position.
WorkflowSpec
Durable workflow definition.

Enums§

BootFlowTaskDeduplication
How a Boot queue coalesces duplicate Flow task targets.
ChildWorkflowCancellationPolicy
Action applied to an open child when its parent enters cancellation.
FlowError
Errors surfaced by the workflow engine and runtime adapters.
FlowEvent
Event persisted as the single source of truth for a workflow run.
FlowTask
Queueable unit of workflow engine work.
HookStatus
Materialized lifecycle state of an external callback hook.
NativeRuntimeKind
Kind of invocation sent to a native TypeScript runtime.
NativeTsDependencyMode
Source-identity policy for native TypeScript artifacts.
RuntimeCommand
Command emitted by the workflow runtime after replay.
RuntimeKind
Runtime family used to execute workflow code.
ScheduledWakeupKind
Kind of durable timer that can wake a suspended workflow run.
SignalWaitStatus
Materialized lifecycle state of a deterministic signal wait.
StepFailureAction
What the engine should do after a step exhausts its retry attempts.
StepStatus
Materialized lifecycle state of a durable step.
WaitStatus
Materialized lifecycle state of a durable timer wait.
WorkflowDslCompatibility
Compatibility of an imported workflow DSL with the version exercised by this release of A3S Flow.
WorkflowDslError
Failure returned while parsing, validating, planning, or encoding workflow DSL.
WorkflowRunStatus
Materialized lifecycle state of a workflow run.
WorkflowRunSuspension
Open suspension projected for host dashboards and operator consoles.
WorkflowTerminalOutcome
Typed terminal result projected from the final run event.

Constants§

MAX_WORKFLOW_PATCH_MARKERS
Maximum number of replay-safe patch markers pinned to one workflow run.
NATIVE_COMPILER_PROTOCOL
Command protocol implemented by the installable native TypeScript compiler.
NATIVE_DEPENDENCY_MANIFEST_PROTOCOL
Dependency-manifest protocol emitted by the native TypeScript compiler.
NATIVE_RUNTIME_PROTOCOL
Wire protocol implemented by native TypeScript workflow executables.
TESTED_WORKFLOW_DSL_VERSION
Latest workflow DSL version covered by compatibility tests.
WORKFLOW_DSL_MAX_BYTES
Maximum accepted UTF-8 byte length for one workflow DSL document or graph.

Traits§

A3sFlowEventSink
Sink for A3S-style Flow events.
FlowEventObserver
Observer for committed workflow events.
FlowEventStore
Append-only event store for durable workflow runs.
FlowRuntime
Runtime boundary for workflow code and side-effecting steps.
FlowTaskDispatcher
Enqueue-only dispatch boundary used by schedulers and callback routers.
FlowTaskQueue
Queue abstraction for workflow dispatch.

Functions§

migrate_postgres_flow
Apply the canonical Flow PostgreSQL schema with a dedicated migration executor.

Type Aliases§

JsonValue
JSON payload exchanged between the engine and runtimes.
Result
Crate-local result type.