pub struct SubMonitorCell {
pub max_age_ms: AtomicU32,
pub takes: AtomicU32,
}Expand description
One contracted subscriber’s take-age accumulator (W3b.5). The take
path records epoch_now - header.stamp per message (fetch_max); the
age check drains it (swap 0) per window.
Fields§
§max_age_ms: AtomicU32Max observed take-age (ms) in the current check window.
takes: AtomicU32phase-462 W2 – observations recorded since the last check, drained
(swap 0) by check_age. The age itself cannot answer “did anything
arrive”: a window with no take and a window whose only take was
perfectly fresh both leave max_age_ms at 0.
Implementations§
Source§impl SubMonitorCell
impl SubMonitorCell
pub const fn new() -> SubMonitorCell
Sourcepub fn observe(&self, stamp_us: u64, epoch_now_us: u64)
pub fn observe(&self, stamp_us: u64, epoch_now_us: u64)
Take-path hook: record one message’s age. stamp_us is the
peeked header.stamp as µs since the UNIX epoch, epoch_now_us
the receive-side wall clock. A stamp from the future clamps to 0.
phase-462 W2 – also the silence rule’s only evidence that this
endpoint is being fed. It counts what the AGE rule can see, which is
stamped takes on a type that carries a stamp: a contracted endpoint
whose messages carry no readable stamp records nothing here and is
reported silent. That is the intended verdict rather than a gap –
its max_age_ms cannot be judged either, and an unjudgeable promise
reported as met is the silent class this phase exists to remove.