Block import and verification refactoring (#4844)
A few refactorings to block import and block verification that should not be controversial. Block verification before block import is stateless by design as described in https://substrate.stackexchange.com/a/1322/25 and the fact that it wasn't yet I consider to be a bug. Some code that requires it had to use `Mutex`, but I do not expect it to have a measurable performance impact. Similarly with block import checking whether block preconditions should not be an exclusive operation, there is nothing fundamentally wrong with checking a few competing blocks whose parent blocks exist at the same time (and even import them concurrently later, though IIRC this is not yet implemented either). They were originally a part of https://github.com/paritytech/polkadot-sdk/pull/4842 and upstreaming will help us to reduce the size of the patch we need to apply on top of upstream code at Subspace every time we upgrade. There are no new features introduced here, just refactoring to get rid of unnecessary requirements.
parent
2f3a1bf8
Pipeline
#482546
waiting for manual action
with stages
in
1 hour, 19 minutes, and 11 seconds
Please register or sign in to comment