#[non_exhaustive]pub struct Config {
pub hop: Hop,
pub pool: Pool,
pub cache_duration: Duration,
pub default_max_age: Duration,
}Expand description
An origin’s identity plus the cache pool its broadcasts inherit.
Construction config for an origin Producer. The origin passes its
cache::Pool to every broadcast it creates, so every track and group beneath it
shares one budget. Defaults to no byte target and the cache’s standard idle expiry.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.hop: HopThe origin’s wire identity, appended to broadcast hop chains for loop detection and shortest-path routing.
pool: PoolThe cache pool broadcasts under this origin charge their groups into. It flows
down the ownership chain (origin -> broadcast -> track -> group): a track opens
an account against it, and its groups charge through that. It has no byte target
and uses cache::DEFAULT_EXPIRY by default; a relay sets a shared configured
pool (assign Self::pool) so cached groups across the whole process share
one policy.
cache_duration: DurationCeiling on each track’s media-timestamp retention window under this origin.
Each track’s own max_age is clamped down to this
when the track binds, so a subscriber is never promised more history than the
origin allows, regardless of what a publisher advertises. Wall-clock
reclamation of idle content is separate: Self::pool’s
expiry window. Duration::MAX (the default)
imposes no ceiling, leaving each track’s own window in force.
default_max_age: DurationThe retention window given to a track whose publisher advertises none.
moq-lite 05+ carries max_age in TRACK_INFO, so a
track relayed over it keeps the window its publisher chose. Every moq-transport
draft and moq-lite 01-04 have no such wire property, so a track arriving over one
of them lands here instead. Raise it on a relay fronting a segmented egress
(HLS/DASH), which needs a playlist window’s worth of history rather than the live
edge. Defaults to track::DEFAULT_MAX_AGE, and Self::cache_duration
still caps it.