Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Decouple coord package from addressing #903

Merged
merged 4 commits into from
Sep 19, 2023
Merged

Decouple coord package from addressing #903

merged 4 commits into from
Sep 19, 2023

Conversation

iand
Copy link

@iand iand commented Sep 18, 2023

Greatly simplifies the coord package. All addressing should be handled by the DHT's host peerstore.

Also align on using kadt.PeerID everywhere in the coord package. Probably all of this package could now be generic on Key and Node now.

Simplifies the Router interface since the coordinator doesn't need to interact with addressing.

Removes all the conversion functions 🎉

@iand iand added the v2 All issues related to the v2 rewrite label Sep 18, 2023
iand and others added 2 commits September 18, 2023 16:43
Moved ticker initialization outside the garbage collection goroutine. There was a race condition between advancing the mocked time in TestProvidersBackend_GarbageCollection and the initialization of the ticker that triggers the garbage collection runs. It happened that we were advancing the time without the ticker being initialized. Hence, advancing the time hasn't had any effect.

In this PR, I moved the ticker initialization outside the garbage collection goroutine. This means the ticker will be registered with the MockClock object after StartGarbageCollection returns. Calls to mockClock.Add will therefore trigger the ticker.
* Increase test iterations to trigger flake

* Add failfast

* Replace routing notification channel with a RoutingNotifier type

* Remove unused code

* Remove test count
@iand iand merged commit 1220ddd into v2-develop Sep 19, 2023
11 checks passed
@iand iand deleted the v2-coord-addr branch September 19, 2023 12:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
v2 All issues related to the v2 rewrite
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants