From 34989e5140eaa16e17a0ab4501e64e779215e3d1 Mon Sep 17 00:00:00 2001 From: tv Date: Sun, 25 Oct 2026 22:12:27 +0100 Subject: recompute neighbours whenever topology changes --- src/swarm/sync.rs | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/swarm/sync.rs') diff --git a/src/swarm/sync.rs b/src/swarm/sync.rs index 93af6f7..d4503bb 100644 --- a/src/swarm/sync.rs +++ b/src/swarm/sync.rs @@ -608,6 +608,13 @@ pub(crate) async fn run_change_publisher(state: AppState) { warn!(path = ?path, "Concurrent writes produced a conflict"); } + if paths + .iter() + .any(|path| crate::swarm::topology::affects_neighbours(path)) + { + state.topology_changed.notify_one(); + } + // Fails only when nobody is subscribed. let _ = state.change_events.send(Arc::new(ChangeSet { paths })); } -- cgit v1.3.1