forked from tari-project/tari
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(wallet): fix aggressive disconnects in wallet connectivity (tari-…
…project#3807) Description --- - Disconnects the wallet peer only if the pool is unable to create a new RPC session. - Clear the `pool` when disconnecting, so that requests for a client session will wait - Immediately return an error if dialling a peer that is banned Motivation and Context --- Observed the wallet continuously disconnecting and reconnecting to base node, resulting in many of these message: `Outbound messaging protocol failed for peer xxxxx: IO Error: 5e5731a0/4: connection is closed` This is not a confirmed fix for the issue, because it is difficult to reproduce, but I suspect the problem was not clearing the pool in wallet connectivity when disconnecting was causing disconnect to be called whenever a peer session was requested by the monitor etc., sometimes timed in such a way that it would disconnect the new connection that was just established, and that would continue indefinitely. How Has This Been Tested? --- Manually, switching base nodes, stop base node while connected then restart
- Loading branch information
Showing
4 changed files
with
62 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters