pub struct MulticastHandle { /* private fields */ }Expand description
Handle to a running multicast discovery engine.
Implementations§
Source§impl MulticastHandle
impl MulticastHandle
Sourcepub async fn announce_burst(&self)
pub async fn announce_burst(&self)
Broadcasts an announcement burst with exponential backoff and jitter.
The default burst schedule is 100ms, 500ms, 2000ms, each randomized
with up to +50ms jitter to prevent network collisions when multiple nodes boot simultaneously.
Sourcepub async fn announce_custom_burst(
&self,
delays: &[Duration],
max_jitter: Duration,
)
pub async fn announce_custom_burst( &self, delays: &[Duration], max_jitter: Duration, )
Broadcasts a custom burst with the provided delays and maximum jitter.
Sourcepub async fn send_single_announcement(&self)
pub async fn send_single_announcement(&self)
Sends a single instantaneous announcement packet without waiting.
Sourcepub async fn stop(&self)
pub async fn stop(&self)
Stops the discovery engine and waits for all sockets to close and release their ports.
Sourcepub async fn wait_stopped(&self)
pub async fn wait_stopped(&self)
Waits for the discovery task to terminate.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for MulticastHandle
impl !UnwindSafe for MulticastHandle
impl Freeze for MulticastHandle
impl Send for MulticastHandle
impl Sync for MulticastHandle
impl Unpin for MulticastHandle
impl UnsafeUnpin for MulticastHandle
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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