[release-v2.0] multi: Main module backports.#3352
Merged
davecgh merged 7 commits intodecred:release-v2.0from Jun 4, 2024
Merged
[release-v2.0] multi: Main module backports.#3352davecgh merged 7 commits intodecred:release-v2.0from
davecgh merged 7 commits intodecred:release-v2.0from
Conversation
This corrects a log message for misbehaving peers to include the reason they were banned.
When a peer responds to an unknown mix message and this does not result in a ban, the requested message must be removed from the sync manager's current state for in-flight requested messages.
Instead of removing PRs spent by the latest tip block attached to the main chain, use the previous block. The goal of this is to avoid immediately removing mixpool messages that are still propagating the network when a block was quickly mined which includes transactions created from those very same mix messages. After taking a second look at this, this method of removing completed sessions from mixpool does not deal well with reorgs. Using the previous block for every main chain tip extension or reorg will work better, but will still not handle a 2+ block reorg properly. However, these mixpool messages are only removed to avoid a memory leak, and the messages would simply be removed at a later time due to PR expiry.
Previously, outbound peers were required to have a newer minimum protocol version than inbound peers, so two different checks were needed to differentiate. However, now that both inbound and outbound peers are required to have the same minimum version, there is no longer any need to have both checks for the same thing. Thus, this removes the additional check that is no longer needed.
If a transaction is rejected because it reference unknown previous transaction outputs and orphans are disallowed, provide the particular outpoints that are missing, not just transaction hashes.
This adds logic to attempt to help maintain at least one mix capable outbound peer to ensure better connectivity among the mix capable peers.
jrick
approved these changes
Jun 4, 2024
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is a backport of the following PRs to the 2.0 release branch: