diff --git a/crates/hiroz/src/config.rs b/crates/hiroz/src/config.rs index b6cf922f2..d1d86a4b9 100644 --- a/crates/hiroz/src/config.rs +++ b/crates/hiroz/src/config.rs @@ -7,7 +7,7 @@ //! # Architecture //! - Common overrides: 10 settings shared between router and session //! - Router-specific: 5 settings unique to router mode -//! - Session-specific: 6 settings unique to peer mode +//! - Session-specific: 8 settings unique to peer mode //! //! # Example //! ```no_run @@ -230,7 +230,7 @@ fn router_specific_overrides() -> &'static [ConfigOverride] { &ROUTER_SPECIFIC } -/// Session-specific overrides (6 settings) +/// Session-specific overrides (8 settings) fn session_specific_overrides() -> &'static [ConfigOverride] { static SESSION_SPECIFIC: LazyLock> = LazyLock::new(|| { vec![ @@ -244,6 +244,16 @@ fn session_specific_overrides() -> &'static [ConfigOverride] { value: serde_json::json!(["tcp/localhost:7447"]), reason: "Connect to Zenoh router on localhost at standard ROS 2 port 7447", }, + ConfigOverride { + key: "connect/timeout_ms", + value: serde_json::json!({"router": -1, "peer": -1, "client": 0}), + reason: "Matches rmw_zenoh_cpp's default: -1 for peer and router means the connect does not block session start, not that it waits forever", + }, + ConfigOverride { + key: "connect/exit_on_failure", + value: serde_json::json!({"router": false, "peer": false, "client": true}), + reason: "Matches rmw_zenoh_cpp's default: a peer with no reachable router must not fail session creation; only a client, which needs one, does", + }, ConfigOverride { key: "listen/endpoints", value: serde_json::json!(["tcp/localhost:0"]),