Skip to content
This repository has been archived by the owner on Sep 7, 2023. It is now read-only.

routing: integrate probe state machine #3

Merged
merged 2 commits into from
Sep 1, 2023
Merged

routing: integrate probe state machine #3

merged 2 commits into from
Sep 1, 2023

Conversation

iand
Copy link
Owner

@iand iand commented Aug 31, 2023

Integrates the probe state machine from probe-lab/go-kademlia#111 as part of probe-lab/go-kademlia#45

The include state machine is responsible for checking and adding nodes to the routing table. The probe state machine is responsible for checking and potentially removing nodes from the routing table. They operate independently but there is some cross-notification of events.

When the include state machine has performed an initial check it emits a StateIncludeRoutingUpdated state. This is used to notify the probe state machine that a new regular connectivity check must be created.

When the probe state machine fails a check for a node it emits a StateProbeNodeFailure state. This is used to notify the include state machine to add the failed node as a candidate for inclusion as described in probe-lab/go-kademlia#45. This effectively gives the node a second chance, if it fails the inclusion check it is dropped completely.

@iand iand merged commit 59a1b3c into main Sep 1, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant