pub enum CompatibilityMode<N> {
None,
UseInitializeBlock {
until: N,
},
}
Expand description
Run AURA
in a compatibility mode.
This is required for when the chain was launched and later there was a consensus breaking change.
Variants§
None
Don’t use any compatibility mode.
UseInitializeBlock
Fields
until: N
The block number until this compatibility mode should be executed. The first runtime
call in the context of the until
block (importing it/building it) will disable the
compatibility mode (i.e. at until
the default rules will apply). When enabling this
compatibility mode the until
block should be a future block on which all nodes will
have upgraded to a release that includes the updated compatibility mode configuration.
At until
block there will be a hard fork when the authority set changes, between the
old nodes (running with initialize_block
, i.e. without the compatibility mode
configuration) and the new nodes.
Call initialize_block
before doing any runtime calls.
Previously the node would execute initialize_block
before fetchting the authorities
from the runtime. This behaviour changed in: https://github.com/paritytech/substrate/pull/9132
By calling initialize_block
before fetching the authorities, on a block that
would enact a new validator set, the block would already be build/sealed by an
authority of the new set. With this mode disabled (the default) a block that enacts a new
set isn’t sealed/built by an authority of the new set, however to make new nodes be able to
sync old chains this compatibility mode exists.
Trait Implementations§
source§impl<N: Clone> Clone for CompatibilityMode<N>
impl<N: Clone> Clone for CompatibilityMode<N>
source§fn clone(&self) -> CompatibilityMode<N>
fn clone(&self) -> CompatibilityMode<N>
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl<N: Debug> Debug for CompatibilityMode<N>
impl<N: Debug> Debug for CompatibilityMode<N>
Auto Trait Implementations§
impl<N> RefUnwindSafe for CompatibilityMode<N>where N: RefUnwindSafe,
impl<N> Send for CompatibilityMode<N>where N: Send,
impl<N> Sync for CompatibilityMode<N>where N: Sync,
impl<N> Unpin for CompatibilityMode<N>where N: Unpin,
impl<N> UnwindSafe for CompatibilityMode<N>where N: UnwindSafe,
Blanket Implementations§
source§impl<T> CheckedConversion for T
impl<T> CheckedConversion for T
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T, Outer> IsWrappedBy<Outer> for Twhere
Outer: AsRef<T> + AsMut<T> + From<T>,
T: From<Outer>,
impl<T, Outer> IsWrappedBy<Outer> for Twhere Outer: AsRef<T> + AsMut<T> + From<T>, T: From<Outer>,
§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<T> SaturatedConversion for T
impl<T> SaturatedConversion for T
source§fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
fn saturated_from<T>(t: T) -> Selfwhere Self: UniqueSaturatedFrom<T>,
source§fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
fn saturated_into<T>(self) -> Twhere Self: UniqueSaturatedInto<T>,
T
. Read moresource§impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
impl<S, T> UncheckedInto<T> for Swhere T: UncheckedFrom<S>,
source§fn unchecked_into(self) -> T
fn unchecked_into(self) -> T
unchecked_from
.source§impl<T, S> UniqueSaturatedInto<T> for Swhere
T: Bounded,
S: TryInto<T>,
impl<T, S> UniqueSaturatedInto<T> for Swhere T: Bounded, S: TryInto<T>,
source§fn unique_saturated_into(self) -> T
fn unique_saturated_into(self) -> T
T
.