diff options
| author | tv <tv@krebsco.de> | 2026-11-01 23:08:21 +0100 |
|---|---|---|
| committer | tv <tv@krebsco.de> | 2026-11-01 23:08:21 +0100 |
| commit | 7c58f3d8bfa87cfbc6c89ae34780e81b5ff47e0d (patch) | |
| tree | 45150ebd3505a0ccf0e9b4277e57579db79bef95 | |
| parent | 0a870df1ca78ce732134853a512d958eecf84032 (diff) | |
probe wakes peer worker
| -rw-r--r-- | src/swarm/peer/handshake.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/swarm/peer/handshake.rs b/src/swarm/peer/handshake.rs index 896ffdf..6bd4784 100644 --- a/src/swarm/peer/handshake.rs +++ b/src/swarm/peer/handshake.rs @@ -305,8 +305,8 @@ pub(super) async fn discover_peers( } /// Brings `peer`'s next probe forward to now, if it is a member we can't reach (dormant, -/// or unanswered HELLOs) whose probe is pending: the peer worker sends it (its next -/// tick). Whether it was. +/// or unanswered HELLOs) whose probe is pending: the peer worker sends it (woken for +/// it). Whether it was. async fn probe_now(state: &AppState, peer: &str) -> bool { let Some(peer_state) = state.get_peer_state(peer).await else { return false; @@ -320,6 +320,7 @@ async fn probe_now(state: &AppState, peer: &str) -> bool { match &mut peer_state.hello_state { HelloState::AwaitingReply { next_attempt } => { *next_attempt = Instant::now(); + state.peers_due.now(); true } _ => false, |
