From bdb76a07c824f3775c5eb92d2754f8f239ccdf70 Mon Sep 17 00:00:00 2001 From: tv Date: Tue, 3 Nov 2026 03:30:19 +0100 Subject: dashboard: show eager links on the map --- src/transport/mod.rs | 4 ++++ src/transport/wire.rs | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) (limited to 'src/transport') diff --git a/src/transport/mod.rs b/src/transport/mod.rs index 7f1aa98..22782ef 100644 --- a/src/transport/mod.rs +++ b/src/transport/mod.rs @@ -469,6 +469,10 @@ pub(crate) struct Link { pub(crate) rtt_us: Option, /// Silent for long (`peers.md`, dormancy). pub(crate) dormant: bool, + /// Eager links (`swarm::relay`): the member sends the peer its changes as it applies + /// them (the peer asked), and the peer the member (the member asked). + pub(crate) eager_to: bool, + pub(crate) eager_from: bool, /// The peer's other transports (`swarm::links::MAX_OTHERS` at most): where else /// it proved itself, those paths up. pub(crate) others: Vec, diff --git a/src/transport/wire.rs b/src/transport/wire.rs index 40976ee..fe690a2 100644 --- a/src/transport/wire.rs +++ b/src/transport/wire.rs @@ -14,7 +14,7 @@ use super::{EncodedMessage, MessageKind, ParsedMessage}; /// The wire format's version, the first byte of every payload. Bump it with every change /// to a message type or a codec (`golden_bytes` fails then). -pub(crate) const VERSION: u8 = 17; +pub(crate) const VERSION: u8 = 18; /// What the second byte of a payload says. fn tag(kind: MessageKind) -> u8 { @@ -445,6 +445,8 @@ pub(crate) fn samples() -> Vec { down: false, rtt_us: Some(1500), dormant: false, + eager_to: true, + eager_from: false, others: vec![crate::transport::OtherPath { transport: "mycelium".into(), rtt_us: None, -- cgit v1.3.1