diff options
| author | tv <tv@krebsco.de> | 2026-11-01 21:01:43 +0100 |
|---|---|---|
| committer | tv <tv@krebsco.de> | 2026-11-01 21:01:43 +0100 |
| commit | 9edf5e5d56596458c9f8faf289cc5328aef08226 (patch) | |
| tree | e1809beca905767d9d82ba4d5569a2925f9cbb2f /src/transport/paths.rs | |
| parent | da18be3c9bbfdd5b3b4ff19f48863a7badf6074d (diff) | |
introduce per-transport sync reply timeout
Diffstat (limited to 'src/transport/paths.rs')
| -rw-r--r-- | src/transport/paths.rs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/transport/paths.rs b/src/transport/paths.rs index 8bb8533..1f88e0a 100644 --- a/src/transport/paths.rs +++ b/src/transport/paths.rs @@ -644,6 +644,16 @@ impl Paths { .unwrap_or_default() } + /// The longest of the transports' (`Transport::sync_reply_timeout`): an answer may + /// come over any of them. + pub(crate) fn sync_reply_timeout(&self) -> Duration { + self.links + .iter() + .map(|link| link.inner.sync_reply_timeout()) + .max() + .unwrap_or(crate::state::SYNC_REPLY_TIMEOUT) + } + /// Each transport's (`Transport::local_addresses`), with its scheme: taken in turns, /// each transport's first in the configured order, then each one's second, and so on, /// so a list cut short (`members::MAX_ADDRESSES`) still has every transport's best. |
