#[repr(i32)]pub enum LifecycleState {
StateUnspecified = 0,
StateRegistered = 1,
StateInactive = 2,
StateActive = 3,
StateError = 4,
StateTerminated = 5,
}Expand description
– CapabilityProvider lifecycle ––––––––––––––––––––––
Lifecycle is per-CapabilityProvider (per Primitive / Service / Skill), not per-Capability. The CapabilityProvider itself is the source of truth; Atlas only stores what it reported via SetLifecycleState.
The Driver(CMD_INIT) / Driver(CMD_ACTIVATE) / etc. calls
referenced below are NOT part of Atlas. Driver is defined by
lib/lifecycle/srv/Driver.srv and exposed by each CapabilityProvider
as a gRPC service alongside its data Capabilities. rbnx boot and
the executor call it on the CapabilityProvider’s own gRPC endpoint
to drive the transitions described here. Atlas only observes the
resulting SetLifecycleState pushes.
STATE_REGISTERED – process up, Register* succeeded, but
Driver(CMD_INIT) hasn’t completed.
STATE_INACTIVE – Driver(CMD_INIT) ok. Config parsed, upstream
CapabilityProvider dependencies looked up via
Atlas Query, soft validation done; no hot
resources held. Skills sit here until the
executor sends CMD_ACTIVATE. Primitives /
Services pass through immediately – rbnx boot auto-sends CMD_ACTIVATE next.
STATE_ACTIVE – Driver(CMD_ACTIVATE) ok. Hot resources held,
Capabilities serve traffic. Consumers MUST
gate on state == ACTIVE of the owning CapabilityProvider
before calling a Capability.
STATE_ERROR – last Driver(CMD_*) returned ok=false or
raised. Terminal apart from CMD_SHUTDOWN.
STATE_TERMINATED – on_shutdown ran (or process exited / heartbeat
lapsed). Atlas GCs after a brief delay.
Variants§
StateUnspecified = 0
StateRegistered = 1
StateInactive = 2
StateActive = 3
StateError = 4
StateTerminated = 5
Implementations§
Source§impl LifecycleState
impl LifecycleState
Sourcepub fn as_str_name(&self) -> &'static str
pub fn as_str_name(&self) -> &'static str
String value of the enum field names used in the ProtoBuf definition.
The values are not transformed in any way and thus are considered stable (if the ProtoBuf definition does not change) and safe for programmatic use.
Sourcepub fn from_str_name(value: &str) -> Option<Self>
pub fn from_str_name(value: &str) -> Option<Self>
Creates an enum from field names used in the ProtoBuf definition.
Trait Implementations§
Source§impl Clone for LifecycleState
impl Clone for LifecycleState
Source§fn clone(&self) -> LifecycleState
fn clone(&self) -> LifecycleState
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for LifecycleState
impl Debug for LifecycleState
Source§impl Default for LifecycleState
impl Default for LifecycleState
Source§fn default() -> LifecycleState
fn default() -> LifecycleState
Source§impl From<LifecycleState> for i32
impl From<LifecycleState> for i32
Source§fn from(value: LifecycleState) -> i32
fn from(value: LifecycleState) -> i32
Source§impl Hash for LifecycleState
impl Hash for LifecycleState
Source§impl Ord for LifecycleState
impl Ord for LifecycleState
Source§fn cmp(&self, other: &LifecycleState) -> Ordering
fn cmp(&self, other: &LifecycleState) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for LifecycleState
impl PartialEq for LifecycleState
Source§impl PartialOrd for LifecycleState
impl PartialOrd for LifecycleState
Source§impl TryFrom<i32> for LifecycleState
impl TryFrom<i32> for LifecycleState
Source§type Error = UnknownEnumValue
type Error = UnknownEnumValue
Source§fn try_from(value: i32) -> Result<LifecycleState, UnknownEnumValue>
fn try_from(value: i32) -> Result<LifecycleState, UnknownEnumValue>
impl Copy for LifecycleState
impl Eq for LifecycleState
impl StructuralPartialEq for LifecycleState
Auto Trait Implementations§
impl Freeze for LifecycleState
impl RefUnwindSafe for LifecycleState
impl Send for LifecycleState
impl Sync for LifecycleState
impl Unpin for LifecycleState
impl UnsafeUnpin for LifecycleState
impl UnwindSafe for LifecycleState
Blanket Implementations§
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].