Skip to content
This repository has been archived by the owner on Aug 23, 2019. It is now read-only.

fix: clear blacklist for peer when connection is established #340

Merged
merged 1 commit into from Jun 5, 2019

Conversation

jacobheun
Copy link
Contributor

This PR clears the blacklist for a peer when it established a muxed connection to the peer.

Previously, if you tried to connect to a peer that was temporarily unavailable, it would get blacklisted for a short period. If that peer came back online and connected to you, the blacklist wasn't getting cleared. This would prevent any application code from creating new streams to that peer because the dialer sees the blacklist. Incoming connections will now clear the blacklist to correct this.

Adding the test I also noticed the dialer queue .add function was not exiting early when things were blacklisting, so I corrected that.

@jacobheun jacobheun requested review from dirkmc and vasco-santos and removed request for dirkmc June 5, 2019 13:56
Copy link
Member

@vasco-santos vasco-santos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@jacobheun jacobheun merged commit f306cba into master Jun 5, 2019
@jacobheun jacobheun deleted the fix/blacklist branch June 5, 2019 14:43
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
2 participants