aboutsummaryrefslogtreecommitdiffstats
path: root/src/swarm/reach.rs
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2026-11-30 14:31:03 +0000
committertv <tv@krebsco.de>2026-11-30 14:31:03 +0000
commit362633603e9fc1912fd35807da5653dc1273a5be (patch)
treeb5f277be7e3e38bb058203d5196016b13fd5cc3b /src/swarm/reach.rs
parent01a71c5ba7171feba8ed794b591b81c07b0f3d97 (diff)
swarm: members read of where the node's document keeps them
The swarm reads its members, their addresses, aliases, parties, tiers and links, at _continuum/members of the document the node holds. Where the node's document keeps them apart and hands them over as a tree (AppState::entries: a set of events, Holding::entries), they are read of that (view::members_of): by the topology, the node's registration, stability, working links, the state file's seeds, reach, and the API's aliases, dashboards and tier. No node's document does so yet but one whose store a set carries, which none starts as.
Diffstat (limited to 'src/swarm/reach.rs')
-rw-r--r--src/swarm/reach.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/swarm/reach.rs b/src/swarm/reach.rs
index 760bcb5..2e8c151 100644
--- a/src/swarm/reach.rs
+++ b/src/swarm/reach.rs
@@ -196,7 +196,9 @@ pub(crate) fn of(said: Option<&(Instant, Vec<u64>)>) -> Option<Vec<u64>> {
/// The members of our member list by pair key, to name what neighbours say they reach.
pub(crate) async fn names(state: &AppState) -> HashMap<u64, String> {
let replica = state.doc.read().await;
- members::members(&replica.doc)
+ let entries = state.entries();
+ let listed = crate::document::view::members_of(&entries, &replica.doc);
+ members::members(listed)
.into_iter()
.map(|member| (topology::pair_key(&member), member))
.collect()