Enum ListenerHealth
pub enum ListenerHealth {
Pending,
Healthy,
Unhealthy,
}Expand description
What a channel can say about its own listener without performing any I/O.
See Channel::listener_health. The three states exist because a listener
that has not connected yet and a listener that is working are different
claims, and a caller that stamps “healthy” for both reports a channel as
ok before it has ever reached the service.
Variants§
Pending
No exchange has completed yet, so the channel has nothing to report. Not a failure — a listener that has only just started is not yet broken — but not evidence of health either.
Healthy
The most recent exchange succeeded, recently enough that it is still evidence the channel works.
Unhealthy
Either the most recent exchange failed, or the last success is old
enough that the channel will no longer vouch for it. Both mean a live
listen() is not proof the channel is working.
Trait Implementations§
Source§impl Clone for ListenerHealth
impl Clone for ListenerHealth
Source§fn clone(&self) -> ListenerHealth
fn clone(&self) -> ListenerHealth
1.0.0 (const: unstable) · §fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more