pub enum State {
Alive,
Suspect,
Down,
}
Expand description
State describes how a Foca instance perceives a member of the cluster.
This is part of the Suspicion Mechanism described in section 4.2 of the original SWIM paper.
Variants§
Alive
Member is active.
Suspect
Member is active, but at least one cluster member
suspects its down. For all purposes, a Suspect
member
is treated as if it were Alive
until either it
refutes the suspicion (becoming Alive
) or fails to
do so (being declared Down
).
Down
Confirmed Down. A member that reaches this state can’t join the cluster with the same identity until the cluster forgets this knowledge.
Trait Implementations§
source§impl<'de> Deserialize<'de> for State
impl<'de> Deserialize<'de> for State
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>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq for State
impl PartialEq for State
impl Copy for State
impl Eq for State
impl StructuralPartialEq for State
Auto Trait Implementations§
impl Freeze for State
impl RefUnwindSafe for State
impl Send for State
impl Sync for State
impl Unpin for State
impl UnwindSafe for State
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