pub struct FeatureActivation {
pub feature: String,
pub level: ClusterFeatureLevel,
pub activated_at: HlcTimestamp,
pub activated_by: NodeId,
}Expand description
Record of one cluster feature activation (spec section 11.8).
Feature activation is a replicated catalog command (ADR-0010 decision 4):
the catalog-command variant that carries this record through the command
envelope lands with the meta-group integration, and the apply path there
re-runs FeatureActivation::validate at quorum. Defined here so the
record shape and the activation rule exist before that integration.
Fields§
§feature: StringRegistered name of the feature being activated.
level: ClusterFeatureLevelCluster feature level this activation raises the cluster to.
activated_at: HlcTimestampCommit timestamp of the activation (assigned by the commit sequencer once the command is replicated).
activated_by: NodeIdNode that proposed the activation.
Implementations§
Source§impl FeatureActivation
impl FeatureActivation
Sourcepub fn validate(
&self,
registry: &FeatureRegistry,
current_level: ClusterFeatureLevel,
voters: &[NodeDescriptor],
) -> Result<(), FeatureActivationError>
pub fn validate( &self, registry: &FeatureRegistry, current_level: ClusterFeatureLevel, voters: &[NodeDescriptor], ) -> Result<(), FeatureActivationError>
Validate the activation against the registry, the current cluster
level, and every voter’s advertised VersionInfo.
voters must be exactly the current voter set of the group that will
apply the command. The rule (spec section 11.8 step 5): a feature may
activate only when every voter supports it, at a level that satisfies
the registry minimum and never lowers the cluster level.
Trait Implementations§
Source§impl Clone for FeatureActivation
impl Clone for FeatureActivation
Source§fn clone(&self) -> FeatureActivation
fn clone(&self) -> FeatureActivation
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for FeatureActivation
impl Debug for FeatureActivation
Source§impl<'de> Deserialize<'de> for FeatureActivation
impl<'de> Deserialize<'de> for FeatureActivation
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for FeatureActivation
Source§impl PartialEq for FeatureActivation
impl PartialEq for FeatureActivation
Source§impl Serialize for FeatureActivation
impl Serialize for FeatureActivation
impl StructuralPartialEq for FeatureActivation
Auto Trait Implementations§
impl Freeze for FeatureActivation
impl RefUnwindSafe for FeatureActivation
impl Send for FeatureActivation
impl Sync for FeatureActivation
impl Unpin for FeatureActivation
impl UnsafeUnpin for FeatureActivation
impl UnwindSafe for FeatureActivation
Blanket Implementations§
impl<T> AppData for Twhere
T: OptionalSend + OptionalSync + 'static + OptionalSerde,
impl<T> AppDataResponse for Twhere
T: OptionalSend + OptionalSync + 'static + OptionalSerde,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.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> 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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request