This repository has been archived by the owner on Feb 18, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 35
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
c1ed28e
to
d23228e
Compare
In snap sync, we only verify header without processing block transactions so the statedb is not available. As a result, we need to avoid reading statedb in the header verification path and must use the information from header instead. This commit disables signer list verification in extra data of checkpoint block header in consortium version 1 when snap/fast sync. In consortium version 2, at the forked block, when getting the list of validators, we read this information from header instead of contract, it is expected to behave the same as before. This commit does not change the header verification process when full sync.
…5666) * eth/protocols/snap: throttle trie heal requests when peers DoS us * eth/protocols/snap: lower heal throttle log to debug Co-authored-by: Martin Holst Swende <[email protected]> * eth/protocols/snap: fix comment Co-authored-by: Martin Holst Swende <[email protected]>
* sort snap trienode heal requests * eth/protocols/snap: remove debug code * eth/protocols/snap: simplify sort, generate pathsets later * eth/protocols/snap: review concern * eth/protocols/snap: renamings * eth/protocols/snap: add comments in Merge * eth/protocols/snap: remove variable 'last' in Merge * eth/protocols/snap: fix lint flaws in test Co-authored-by: Felix Lange <[email protected]>
Make full sync the default sync mode until we thoroughly test the snap sync.
huyngopt1994
approved these changes
Jun 12, 2024
andicrypt
pushed a commit
to andicrypt/ronin
that referenced
this pull request
Aug 14, 2024
* consortium: avoid reading statedb in block header verification path In snap sync, we only verify header without processing block transactions so the statedb is not available. As a result, we need to avoid reading statedb in the header verification path and must use the information from header instead. This commit disables signer list verification in extra data of checkpoint block header in consortium version 1 when snap/fast sync. In consortium version 2, at the forked block, when getting the list of validators, we read this information from header instead of contract, it is expected to behave the same as before. This commit does not change the header verification process when full sync. * eth/protocols/snap: fix problems due to idle-but-busy peers * eth/protocols/snap: throttle trie heal requests when peers DoS us (#25666) * eth/protocols/snap: throttle trie heal requests when peers DoS us * eth/protocols/snap: lower heal throttle log to debug Co-authored-by: Martin Holst Swende <[email protected]> * eth/protocols/snap: fix comment Co-authored-by: Martin Holst Swende <[email protected]> * eth/protocols/snap: sort trienode heal requests by path (#24779) * sort snap trienode heal requests * eth/protocols/snap: remove debug code * eth/protocols/snap: simplify sort, generate pathsets later * eth/protocols/snap: review concern * eth/protocols/snap: renamings * eth/protocols/snap: add comments in Merge * eth/protocols/snap: remove variable 'last' in Merge * eth/protocols/snap: fix lint flaws in test Co-authored-by: Felix Lange <[email protected]> * eth/ethconfig: make full sync the default sync mode Make full sync the default sync mode until we thoroughly test the snap sync. --------- Co-authored-by: Martin Holst Swende <[email protected]> Co-authored-by: Péter Szilágyi <[email protected]> Co-authored-by: Felix Lange <[email protected]>
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
In snap sync, we only verify header without processing block transactions so the
statedb is not available. As a result, we need to avoid reading statedb in the
header verification path and must use the information from header instead.
This commit disables signer list verification in extra data of checkpoint block
header in consortium version 1 when snap/fast sync. In consortium version 2, at
the forked block, when getting the list of validators, we read this information
from header instead of contract, it is expected to behave the same as before.
This commit does not change the header verification process when full sync.
Mark the peer as idle only when it finish processing response packet
Throttle the breadth expansion to prioritize depth expansion
Sort the heal requests by path to merge the storage trie requests from the same
account. This helps to reduce the bandwith.
Make full sync the default sync mode until we thoroughly test the snap sync.