-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Keep track of peers with maps instead of lists. #433
Merged
Merged
Conversation
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
Reads well. I'll spend some time testing it out. |
I've been running this for a while now with no issues. OK after rebase.. |
Just curious: why was this change necessary? |
It isn't strictly necessary, but it's more efficient for a few reasons:
So, summarizing, it uses less memory and provides faster access to the set elements. |
jrick
added a commit
to jrick/btcd
that referenced
this pull request
Nov 1, 2016
Change the block connected and disconnected notifications to include the entire block header. Do not notify the previous block's regular tree transactions if the newly attached block voted to approve them. Instead, notify the regular transactions from the newly attached block. It is up to the client to check the vote bits in the header to decide how to handle the previous block's regular transactions. Every websocket client now has an associated transaction filter that is used to determine whether or not a processed transaction is (or might be) relevant to the client. A new RPC, loadtxfilter, has been added to load, reload, or add to this filter. Redo the entire rescan RPC to scan over previously-processed blocks using the same transaction filter (rather than specifying which addresses and outpoints to watch for in the rescan request). Fixes btcsuite#433.
jrick
added a commit
to jrick/btcd
that referenced
this pull request
Nov 1, 2016
Change the block connected and disconnected notifications to include the entire block header. Do not notify the previous block's regular tree transactions if the newly attached block voted to approve them. Instead, notify the regular transactions from the newly attached block. It is up to the client to check the vote bits in the header to decide how to handle the previous block's regular transactions. Every websocket client now has an associated transaction filter that is used to determine whether or not a processed transaction is (or might be) relevant to the client. A new RPC, loadtxfilter, has been added to load, reload, or add to this filter. Redo the entire rescan RPC to scan over previously-processed blocks using the same transaction filter (rather than specifying which addresses and outpoints to watch for in the rescan request). Fixes btcsuite#433.
jrick
added a commit
to jrick/btcd
that referenced
this pull request
Nov 8, 2016
Change the block connected and disconnected notifications to include the entire block header. Do not notify the previous block's regular tree transactions if the newly attached block voted to approve them. Instead, notify the regular transactions from the newly attached block. It is up to the client to check the vote bits in the header to decide how to handle the previous block's regular transactions. Every websocket client now has an associated transaction filter that is used to determine whether or not a processed transaction is (or might be) relevant to the client. A new RPC, loadtxfilter, has been added to load, reload, or add to this filter. Redo the entire rescan RPC to scan over previously-processed blocks using the same transaction filter (rather than specifying which addresses and outpoints to watch for in the rescan request). Fixes btcsuite#433.
jrick
added a commit
to jrick/btcd
that referenced
this pull request
Nov 8, 2016
Change the block connected and disconnected notifications to include the entire block header. Do not notify the previous block's regular tree transactions if the newly attached block voted to approve them. Instead, notify the regular transactions from the newly attached block. It is up to the client to check the vote bits in the header to decide how to handle the previous block's regular transactions. Every websocket client now has an associated transaction filter that is used to determine whether or not a processed transaction is (or might be) relevant to the client. A new RPC, loadtxfilter, has been added to load, reload, or add to this filter. Redo the entire rescan RPC to scan over previously-processed blocks using the same transaction filter (rather than specifying which addresses and outpoints to watch for in the rescan request). Fixes btcsuite#433.
jrick
added a commit
to jrick/btcd
that referenced
this pull request
Nov 8, 2016
Change the block connected and disconnected notifications to include the entire block header. Do not notify the previous block's regular tree transactions if the newly attached block voted to approve them. Instead, notify the regular transactions from the newly attached block. It is up to the client to check the vote bits in the header to decide how to handle the previous block's regular transactions. Every websocket client now has an associated transaction filter that is used to determine whether or not a processed transaction is (or might be) relevant to the client. A new RPC, loadtxfilter, has been added to load, reload, or add to this filter. Redo the entire rescan RPC to scan over previously-processed blocks using the same transaction filter (rather than specifying which addresses and outpoints to watch for in the rescan request). Fixes btcsuite#433.
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.
No description provided.