Uh oh!
There was an error while loading. Please reload this page.
feat: add ConnectionGater - #610
Conversation
tzdybal
left a comment
There was a problem hiding this comment.
Thanks for the submission!
I left some comments.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
fcb57fd to
b17b4baCompareCodecov Report
@@ Coverage Diff @@## main #610 +/- ##
==========================================
- Coverage 55.06% 55.02% -0.04%
==========================================
Files 48 48 Lines 10206 10224 +18 ==========================================
+ Hits 5620 5626 +6 - Misses 3724 3732 +8 - Partials 862 866 +4
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
tzdybal
left a comment
There was a problem hiding this comment.
Thanks for the submission! I left some comments.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
768aa05 to
3687d3eCompare3687d3e to
dad8975Compare
Manav-Aggarwal
left a comment
There was a problem hiding this comment.
Thanks for the submission! Left some comments. Had one question, when are whitelists useful as opposed to just having a blocklist? Or is the point to have overlap in whitelists and blocklists when unblocking a peer? Also, what happens when there are duplicate peer IDs in these blocklists/whitelists?
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
tzdybal
commented
Dec 20, 2022
When we get to the point where peers are blocked automatically (because of for example spamming, sending invalid FPs, etc), we might want to manually unblock specific peer. |
Manav-Aggarwal
commented
Dec 20, 2022
That makes sense but instead of having that peer in both the whitelist and blacklist, is it possible to just remove the peer from the blacklist instead since this is done during client initialization? |
TestClientStartup() ensures that using blacklists/whitelists don't result in an error log which peers exactly were white/blacklisted don't reuse gater between subtests blacklist/whitelist should be setup before gossiping/DHT/peer discovery do not create ConnectionGater yourself if gater was nil style revisions
dad8975 to
1f7aa04Compare
tzdybal
left a comment
There was a problem hiding this comment.
@randomshinichi thanks again for your submission!
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
nashqueue
left a comment
There was a problem hiding this comment.
No additional comments to the ones that were mentioned above. LGTM if they are resolved
tzdybal
commented
Jan 16, 2023
I changed the logic a bit - connection gater is created in Also addressed all the comments. |
To simplify our code, lets just depend on gater ability to block/unblock right peers.
107539b to
7ac66dcCompare
Overview
Resolves#386
Blacklists/whitelists are only applied while starting the
Client, and do not update while theClientis running.Checklist