From 4e53e152f83ecb88fa162e0a18e6832df5a38fef Mon Sep 17 00:00:00 2001 From: tv Date: Thu, 5 Nov 2026 05:38:20 +0100 Subject: round trips in trees --- docs/dashboard.md | 4 ++-- docs/peers.md | 9 ++++++--- 2 files changed, 8 insertions(+), 5 deletions(-) (limited to 'docs') diff --git a/docs/dashboard.md b/docs/dashboard.md index 4c3f6e5..5a36dd2 100644 --- a/docs/dashboard.md +++ b/docs/dashboard.md @@ -157,8 +157,8 @@ static, the nodes staying where they are. The choice is kept in the browser. focus, else of this node. A chevron on the line from each member's parent to it, at its middle and in the colour of the line in use, points the way the writer's changes go; a member without one gets them by announcement. The node computes the tree as every node does, from the member list and -whom each member reaches, which it takes from the links members report (a member that -reports none counts as reaching its neighbours by the member list): asked for when the +whom each member reaches and its round trips, which it takes from the links members +report (a member that reports none counts as reaching its neighbours by the member list): asked for when the writer in focus changes and every 10 s (`GET /admin/dashboard/tree`). The choice is kept in the browser. diff --git a/docs/peers.md b/docs/peers.md index c41d431..991bb40 100644 --- a/docs/peers.md +++ b/docs/peers.md @@ -330,8 +330,10 @@ which from where it is. A neighbour that has the changes already only answers. Every node tells its neighbours whom it reaches ([`swarm/reach.rs`](../src/swarm/reach.rs)): the members it has an active session with (handshake done, neither dormant nor unreachable) that -answer, each by an 8-byte key (the hash its pair scores come from), in its keepalive -STATUSes and their replies, and within 5 s when it changed; not in announcements of +answer, each by an 8-byte key (the hash its pair scores come from) and its round trip +to it as a coarse bucket (doubling bounds from 25 ms to 800 ms; one that moves only +once 20% past a bound, so a round trip near one doesn't flip; one never measured in the +middle), in its keepalive STATUSes and their replies, and within 5 s when either changed; not in announcements of heads, which go often. A member that leaves a keepalive or sync message unanswered, with nothing else heard from it, is asked again (a PING) after the first sync reply timeout, and after twice that no longer counts as reached: its neighbours are told at @@ -348,7 +350,8 @@ built on the graph the member list gives (as if every member reached every other on whom each member says it reaches. Members are ordered by their distance from the writer over that graph, then whether they reach a member a hop closer, then by key; a member's parent is the neighbour it reaches that comes before it, the closest to the -writer first, then one that reaches closer, then by pair score. Coming before rules out +writer first, then one that reaches closer, then the one it said it has the shortest +round trip to, then by pair score. Coming before rules out cycles; taking only one it reaches routes around links that don't work: where a writer behind NAT reaches a single member, that one comes first among those as far from it, and the others take it as their parent. Whose a change is, its author says (every -- cgit v1.3.1