Skip to main content

discover_coordinator

Function discover_coordinator 

Source
pub fn discover_coordinator(
    disc_port: u16,
    host: Option<&str>,
) -> Result<SocketAddr>
Expand description

Worker side of star discovery: return the coordinator’s dial address. host = Some(h) (NAT/Docker) unicasts a query to h:disc_port and dials h:port from the reply; None listens for the LAN broadcast and dials the announcing host’s own IP.