pub struct EnforcementSummaryWire {
pub policy_slug: String,
pub chunks_pushed: u64,
pub chunks_delivered: u64,
pub drop_oldest_hits: u64,
pub degrade_quality_hits: u64,
pub pause_upstream_blocks: u64,
pub fail_overflows: u64,
pub failed: bool,
}Expand description
v1.24.0 — Wire-serializable mirror of
crate::stream_effect_dispatcher::EnforcementSummary published
on axon.complete per the D2 contract.
policy_slug is the closed-catalog slug of the policy that the
enforcer ran (drop_oldest / degrade_quality / pause_upstream
/ fail); pushed/delivered count chunks the enforcer’s input
stream produced + the consumer drained respectively. The four
*_hits / *_blocks / *_overflows counters surface
policy-specific activations so adopters can verify the declared
policy actually fired (D2 contract — declaration ⟺ runtime
behavior).
All counters are u64 so high-throughput long-running flows
don’t risk overflow. failed is set only when the enforcer’s
internal stream surfaced BackpressurePolicy::Fail overflow.
Fields§
§policy_slug: String§chunks_pushed: u64§chunks_delivered: u64§drop_oldest_hits: u64§degrade_quality_hits: u64§pause_upstream_blocks: u64§fail_overflows: u64§failed: boolImplementations§
Source§impl EnforcementSummaryWire
impl EnforcementSummaryWire
Sourcepub fn from_summary(s: &EnforcementSummary) -> Self
pub fn from_summary(s: &EnforcementSummary) -> Self
Project from the rich internal EnforcementSummary (which has
policy: Option<&'static str>) into the wire-stable shape.
Trait Implementations§
Source§impl Clone for EnforcementSummaryWire
impl Clone for EnforcementSummaryWire
Source§fn clone(&self) -> EnforcementSummaryWire
fn clone(&self) -> EnforcementSummaryWire
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more