feat: Prioritize peers based on previous dial succession / failure #1953
Labels
kind/discussion
Topical discussion; usually not changes to codebase
kind/enhancement
A net-new feature or improvement to an existing feature
Following from the conversation here,
If a peer recently failed to establish a connection, there might be underlying issues causing the failure that haven't been resolved yet (may take longer than 10 minutes), and so it's far less likely that a successful connection would result from dialling that peer, as opposed to a peer which was recently successfully dialled but for whatever a reason that connection was closed.
Modifying the tag value is not ideal. The problem is the connection manager doesn't know what it means to penalize a peer, because it doesn't know what the value of a tag added by one component means compared to a tag added by another so it cannot alter the tag values without possibly compromising the functioning of the components doing the tagging.
So if we've successfully dialled the peer recently, but we are no longer connected to them, we should prioritize those peers and conversely if we have dialled a peer but failed recently, those should be de-prioritized.
cc @achingbrain @wemeetagain @p-shahi
The text was updated successfully, but these errors were encountered: