pub struct HealthChecker { /* private fields */ }Implementations§
Source§impl HealthChecker
impl HealthChecker
Sourcepub async fn register(&self, name: String, initial_status: HealthStatus)
pub async fn register(&self, name: String, initial_status: HealthStatus)
Register a node for health checking
Sourcepub async fn update(&self, name: &str, status: HealthStatus)
pub async fn update(&self, name: &str, status: HealthStatus)
Update health status for a node
Sourcepub async fn check_one(&self, name: &str) -> Option<HealthStatus>
pub async fn check_one(&self, name: &str) -> Option<HealthStatus>
Get health status for a specific node
Sourcepub async fn check_all(&self) -> HashMap<String, HealthStatus>
pub async fn check_all(&self) -> HashMap<String, HealthStatus>
Get health status for all nodes
Sourcepub async fn unregister(&self, name: &str)
pub async fn unregister(&self, name: &str)
Remove a node from health checking
Auto Trait Implementations§
impl !RefUnwindSafe for HealthChecker
impl !UnwindSafe for HealthChecker
impl Freeze for HealthChecker
impl Send for HealthChecker
impl Sync for HealthChecker
impl Unpin for HealthChecker
impl UnsafeUnpin for HealthChecker
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
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> ⓘ
Converts
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> ⓘ
Converts
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 more