Open YuanYuYuan opened 1 year ago
Failover brokering has been designed to forward data between peers that cannot directly connect with each other. But it is not able at this time to forward data between peers that can connect to each other but loose connectivity.
Describe the bug
Even when the failover_brokering option is utilized, transmission failure can still occur due to the disconnection between peers that are connecting to a router.
To reproduce
Topology
Terminal 1
Terminal 2
Terminal 3 z_pub_modified.rs, this program closes the transporation between peers after a while.
[async_std::main]
async fn main() -> Result<()> { let connect_endpoint = vec!["tcp/127.0.0.1:7450".parse()?]; let listen_endpoint = vec!["tcp/127.0.0.1:7452".parse()?]; let peer_config = { let mut config = Config::default(); config.set_mode(Some(WhatAmI::Peer)).unwrap(); config.scouting.multicast.set_enabled(Some(false)).unwrap(); config.connect.set_endpoints(connect_endpoint).unwrap(); config.listen.set_endpoints(listen_endpoint).unwrap(); config }; let runtime = Runtime::new(peer_config).await.unwrap(); let _manager = runtime.manager(); let session = zenoh::init(runtime.clone()).res_async().await?; let _receiver = zenoh::scout(WhatAmI::Peer, Config::default()) .res() .await .unwrap();
}