Skip to main content

Module engine

Module engine 

Structs§

MaintenanceSummary
Outcome of one SopEngine::run_maintenance_tick pass (EPIC A1), for observability. All counts are 0 on a quiet tick.
SopEngine
Central SOP orchestrator: loads SOPs, matches triggers, manages run lifecycle.

Enums§

CancelOutcome
What an idempotent operator cancellation did. Returned by cancel_run_idempotent so a caller (the gateway cancel endpoint) can report success on both a fresh cancellation and a repeat request without re-deriving the run’s active/terminal state itself.

Functions§

err_is_cancellation_persistence_retained
True when cancellation could not be durably persisted and the run remains active with its admission claim intact. Covers both the initial CancelRequested snapshot and the terminal Cancelled transition.
err_is_resume_at_capacity
True when err is the typed ResumeAtCapacity backpressure marker (an over-cap resume was refused), as opposed to a store fault. Lets a caller in another module or crate (e.g. resolve_gate, or the gateway resume endpoint) render it as backpressure (HTTP 503) rather than a fault without depending on the private struct.
err_is_terminal_persistence_retained
True when err is the typed TerminalPersistenceRetained marker (a terminal write failed and the run stayed active with its claim intact), as opposed to any other fault. Lets a caller in another module or crate (e.g. the gateway cancel endpoint) render it as retryable backpressure rather than reporting the run as cancelled, without depending on the private struct.
now_iso8601