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
Call initialize_block
before doing any runtime calls.
Previously the node would execute initialize_block
before fetching 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.
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.
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> Freeze for CompatibilityMode<N>where
N: Freeze,
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<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> CheckedConversion for T
impl<T> CheckedConversion for T
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)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> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§impl<T, Outer> IsWrappedBy<Outer> for T
impl<T, Outer> IsWrappedBy<Outer> for T
source§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 S
impl<T, S> UniqueSaturatedInto<T> for S
source§fn unique_saturated_into(self) -> T
fn unique_saturated_into(self) -> T
T
.