pub struct InProcessBus { /* private fields */ }Expand description
In-process broadcast bus — the standalone implementation.
Implementations§
Trait Implementations§
Source§impl EventBus for InProcessBus
impl EventBus for InProcessBus
Source§fn publish(&self, event: FleetEvent)
fn publish(&self, event: FleetEvent)
Fan an event out to current subscribers. Never blocks on slow/absent
receivers (delivery is best-effort relative to the durable store).
Source§fn subscribe(&self, stream_key: &str) -> BusSubscription
fn subscribe(&self, stream_key: &str) -> BusSubscription
A live subscription to one stream’s events. The returned stream yields
only events whose stream key equals
stream_key; consumers dedup the
initial-history/live overlap on seq.Source§fn subscribe_all(&self) -> BusSubscription
fn subscribe_all(&self) -> BusSubscription
A live subscription to EVERY stream’s events, unfiltered. Needed by
fleet-wide watchers (e.g.
FleetManager::watch_changes) that can’t name
a stream key in advance — a brand-new agent’s own id keys its
AgentDiscovered event, so no one can pre-subscribe to it by key.Auto Trait Implementations§
impl Freeze for InProcessBus
impl RefUnwindSafe for InProcessBus
impl Send for InProcessBus
impl Sync for InProcessBus
impl Unpin for InProcessBus
impl UnsafeUnpin for InProcessBus
impl UnwindSafe for InProcessBus
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more