The four instances of gas in the CALL operations are all implemented
identically. Refactor the method into the abstract parent.
Signed-off-by: Danno Ferrin <danno.ferrin@gmail.com>
* Refactor retrying peer task switching peers at every try
RetryingGetBlockFromPeersTask had a problem that prevented to complete
when all the peers were tried without success, and that also had the
consequence to not removing the failed requested block for the internal
caches in BlockPropagationManager, that could cause a stall since that
block will to be tried to be retrieved again.
Signed-off-by: Fabio Di Fabio <fabio.difabio@consensys.net>
* if merge enabled, wrap two clique rules in composed Attached rule to enable fast-sync to proceed normally for post-merge networks
* move BlockPropagationManager warning to debug until #4274
Signed-off-by: garyschulte <garyschulte@gmail.com>
* start filtering peers after 1 finalized instead of 2
* stops counting finalized, and starts filtering on first finalized
* DefaultSynchronizer now listens to Forkhoice messages so it can stop block propagation at finalization, as opposed to TTD (previous behavior)
Signed-off-by: Justin Florentine <justin+github@florentine.us>
Make the ethereum/trie and services/kvstore modules as slim as possible
by dropping dependencies.
* The ':util' api dependency is removed from kvstore and added to
eth module
* Move tries's kvstore dependency to test
* Other dependencies are removed as unused from trie and kvstore
Signed-off-by: Danno Ferrin <danno.ferrin@gmail.com>
* Add more log to retrieve parent method
* Request the lowest pending ancestor when saving a block
* Replace recursive implementation with iterative when getting pending ancestors of Block
* Decrease scope of synchronized block to reflect only the event of adding pending block to the list
* Add fork to the chain so test is more representative
Signed-off-by: Gabriel Trintinalia <gabriel.trintinalia@consensys.net>
Signed-off-by: Gabriel Trintinalia <gabriel.trintinalia@consensys.net>
Co-authored-by: Gabriel Trintinalia <gabriel.trintinalia@consensys.net>
* quieten DynamicPivotBlockManager. Only change pivot block if it is different than existing. move logging to debug
Signed-off-by: garyschulte <garyschulte@gmail.com>
* removed constraint with the length of the privacy public key
* refactor to include tessera ec encryptor
* added EC snippet to the tessera json config, still need to replace base64string from web3j
* acceptance tests working after modifying the web3j library to allow secp256r1 keys
* using NACL encryptor by default
* using web3j v4.9.4 and web3j-quorum v4.9.0
Signed-off-by: Miguel Rojo <miguelangel.rojofernandez@mastercard.com>
Co-authored-by: Antony Denyer <git@antonydenyer.co.uk>
* correct fallback ttd to correct value
Signed-off-by: Daniel Lehrner <daniel.lehrner@consensys.net>
Co-authored-by: Sally MacFarlane <sally.macfarlane@consensys.net>
* DNS peers handled the same as boot nodes
* make sure that non bonded peers can be used as initial peers
* try to connect to DNS nodes
Signed-off-by: Stefan <stefan.pingel@consensys.net>
Co-authored-by: Justin Florentine <justin+github@florentine.us>
* initial impl of engine-api override:
* remove reliance on isMergeEnabled in pre-merge block header validation rules
* create a merge-specific block header validtion stack rather than leveraging mainnet
* re-add --engine-api-enabled cli param
* make engine api usable without a merge config.
leaves the door open to supporting the engine api with other MiningCoordinators, but disables all but engine_exchangeTransitionConfiguration in the absence of mergeCoordinator
Signed-off-by: garyschulte <garyschulte@gmail.com>
* on block propagation stop, only kill the new block and new block hash handlers, leave all others (especially txs) alone
Signed-off-by: Justin Florentine <justin+github@florentine.us>
If a response to the get header P2P request only returns the header that
is the start of the range we may need to trim it to an empty response,
this is breaking the validation response. One client has started
returning only the range header start in some circumstances (which is a
valid response per spec). Because we sometimes request an overlapping
header this results in an empty stream once we cut the duplicates.
fixes#3336
Signed-off-by: Danno Ferrin <danno.ferrin@gmail.com>
* Add mechanism to retrieve missing blocks that caused BlockPropagationManager to get stuck on pending blocks
* Remove threshold and request the lowest block parent everytime a block is saved for future
Signed-off-by: Gabriel Trintinalia <gabriel.trintinalia@consensys.net>
Co-authored-by: Gabriel Trintinalia <gabriel.trintinalia@consensys.net>
Co-authored-by: garyschulte <garyschulte@gmail.com>
Co-authored-by: Sally MacFarlane <sally.macfarlane@consensys.net>