nixfleet_control_plane/runtime/workers/
mod.rs

1//! Workers โ€” the I/O-bearing edges around the pure reducer.
2//!
3//! Each worker is spawned by [`super::spawn`] with its own
4//! [`super::ShutdownToken`] and a clone of the reducer's input
5//! `mpsc::Sender<ReducerInput>`. Workers never call `step()` or
6//! `plan_next()` โ€” they translate I/O into [`super::ReducerInput`] values
7//! and let the reducer task do the actual transitions.
8//!
9//! Routing (RFC-0006 ยง7.2):
10//!
11//! - [`manifest_poll`] โ€” periodic verify of channel-refs + per-channel
12//!   rollout manifests; emits `ManifestSetUpdated`.
13//!
14//! The other three route surfaces (`POST /v1/agent/events`,
15//! `POST /v1/agent/heartbeat`, `GET /v1/agent/dispatch?wait=60`) do not
16//! have dedicated workers: their HTTP handlers (`server/routes/`)
17//! send `ReducerInput` values directly into the input channel and
18//! coordinate shutdown through axum-server's graceful-drain protocol,
19//! not through the runtime's `ShutdownToken` constellation. Phase 6a
20//! spawned stub workers as placeholders for an alternative bridge
21//! architecture that never shipped; Phase 8f deleted them.
22
23pub mod manifest_poll;