Skip to main content

Module dispatch

Module dispatch 

Expand description

Unified SOP event dispatch helpers.

Structs§

SopCronCache
Pre-parsed cron schedules for SOP triggers. Built once at daemon startup to avoid re-parsing cron expressions on every scheduler tick.
SopIngress
Borrowed, per-call adapter from transport deliveries into canonical SOP events.

Enums§

DispatchResult
Outcome of attempting to dispatch an event to the SOP engine.
SopIngressKind
How a SopTriggerSource variant currently reaches the SOP matcher.
SopIngressOutcome
Result of passing one external delivery through SopIngress.
SopIngressUnavailable
Why a fan-in event could not enter the shared SOP dispatch path.

Functions§

check_sop_cron_triggers
Check all cached cron SOP triggers for firings in the window (last_check, now] and dispatch events for each. Uses window-based evaluation so ticks between polls are never missed.
dispatch_peripheral_signal
Convenience wrapper for peripheral hardware callbacks. Builds a SopEvent with source Peripheral and topic "{board}/{signal}" then dispatches it through the standard path.
dispatch_sop_event
dispatch_sop_event_to
Dispatch an incoming event to one named SOP, after normal trigger matching. This is useful for channel routers that already selected a configured SOP name, while still requiring that SOP to declare a matching trigger.
dispatch_untrusted_fan_in
Compatibility wrapper for fan-in sources that already require concrete engine and audit handles. New or handle-optional sources should use SopIngress so missing handles and source-interest gating share one path.
ingress_kind
Classify every SopTriggerSource as SopIngressKind::SharedIngress, SopIngressKind::DedicatedInternalDispatch, or SopIngressKind::NotYetLive.
process_headless_results
results_need_redelivery
True when at least one matched SOP is backpressured and no SOP has already started from this delivery. A durable transport (e.g. AMQP with durable_ack) can safely nack/requeue only when redelivery cannot replay a started SOP’s side effects.