Skip to main content

with_declared_arrival_rate

Function with_declared_arrival_rate 

Source
pub fn with_declared_arrival_rate<'a>(topic: TopicInfo<'a>) -> TopicInfo<'a>
Expand description

phase-519 W3b (RFC-0074) – topic, carrying this image’s declared ingress rate for it, if the contract declared one.

Every subscription registration that builds its own TopicInfo calls this before the backend call – the executor’s one prologue (Executor::open_subscription), the two Node subscription verbs, and the C and C++ polling subscriptions. The rate reaches the backend in rmw_subscription_options_t::arrival_rate_mhz: the XRCE backend asks the agent for rate_hz x rx_buffer_hint bytes a second, and a backend that enforces the declaration elsewhere (zenoh, at the router) ignores it.

Unchanged when nothing was declared, which is every image with no contract sidecar: arrival_rate_mhz stays 0, “undeclared”.