-
Notifications
You must be signed in to change notification settings - Fork 340
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
feat(kademlia): restrict peer quick pruning on net errors only #2599
Conversation
Codecov Report
@@ Coverage Diff @@
## master #2599 +/- ##
==========================================
- Coverage 63.54% 63.38% -0.17%
==========================================
Files 232 232
Lines 25937 25945 +8
==========================================
- Hits 16482 16444 -38
- Misses 7958 7996 +38
- Partials 1497 1505 +8
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed all commit messages.
Reviewable status: 0 of 1 files reviewed, 1 unresolved discussion (waiting on @acud, @istae, and @janos)
pkg/topology/kademlia/kademlia.go, line 1506 at r1 (raw file):
// isNetworkError is checking various conditions that relate to network problems. func isNetworkError(err error) bool {
Since the error might be wrapped I'd suggest using errors.As()
function to check for those error types.
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
Thanks for this, but it's still discouraging if you have a network connectivity issue when you have just started a bee node. You can watch the 100,000+ entry accumulated address book disappear within minutes! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 1 files at r2, all commit messages.
Reviewable status: complete! all files reviewed, all discussions resolved (waiting on @acud and @istae)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sweet :) thanks @janos 🙏
This PR adds a very small addition to the quick pruning to prone only on network related errors. Thanks @acud for the idea.
This change is