MCPcopy Create free account
hub / github.com/ceramicnetwork/rust-ceramic / latency

Method latency

p2p/src/behaviour/ceramic_peer_manager.rs:62–65  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

60
61impl Info {
62 pub fn latency(&self) -> Option<Duration> {
63 // only approximation, this is wrong but the best we have for now
64 self.last_rtt.map(|rtt| rtt / 2)
65 }
66}
67
68const PEERING_MIN_DIAL_SECS: Duration = Duration::from_secs(1); // 1 second min between redials

Callers 1

handle_node_eventMethod · 0.80

Calls 1

mapMethod · 0.80

Tested by

no test coverage detected