pub struct ManagedState { /* private fields */ }
Expand description
Managed state container for managers
Implementations§
Source§impl ManagedState
impl ManagedState
Sourcepub async fn set_state(&self, state: ManagerState)
pub async fn set_state(&self, state: ManagerState)
Sets the manager state
Sourcepub async fn set_health(&self, health: HealthStatus)
pub async fn set_health(&self, health: HealthStatus)
Sets the health status
Sourcepub async fn set_message(&self, message: impl Into<String>)
pub async fn set_message(&self, message: impl Into<String>)
Sets a status message
Sourcepub async fn add_metadata(&self, key: impl Into<String>, value: Value)
pub async fn add_metadata(&self, key: impl Into<String>, value: Value)
Adds metadata
Sourcepub async fn update_metrics(&self, metrics: ManagerMetrics)
pub async fn update_metrics(&self, metrics: ManagerMetrics)
Updates metrics
Sourcepub async fn status(&self) -> ManagerStatus
pub async fn status(&self) -> ManagerStatus
Returns current status
Sourcepub async fn state(&self) -> ManagerState
pub async fn state(&self) -> ManagerState
Returns current state
Sourcepub async fn health(&self) -> HealthStatus
pub async fn health(&self) -> HealthStatus
Returns current health
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ManagedState
impl !RefUnwindSafe for ManagedState
impl Send for ManagedState
impl Sync for ManagedState
impl Unpin for ManagedState
impl !UnwindSafe for ManagedState
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
Mutably borrows from an owned value. Read more
§impl<T> InitializeFromFunction<T> for T
impl<T> InitializeFromFunction<T> for T
§fn initialize_from_function(f: fn() -> T) -> T
fn initialize_from_function(f: fn() -> T) -> T
Create an instance of this type from an initialization function
§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> Pointable for T
impl<T> Pointable for T
§impl<T, O> SuperFrom<T> for Owhere
O: From<T>,
impl<T, O> SuperFrom<T> for Owhere
O: From<T>,
§fn super_from(input: T) -> O
fn super_from(input: T) -> O
Convert from a type to another type.
§impl<T, O, M> SuperInto<O, M> for Twhere
O: SuperFrom<T, M>,
impl<T, O, M> SuperInto<O, M> for Twhere
O: SuperFrom<T, M>,
§fn super_into(self) -> O
fn super_into(self) -> O
Convert from a type to another type.