pub struct SbrRuntime<S: DowningStrategy> { /* private fields */ }Expand description
Runtime that pairs a strategy with a stability deadline.
Implementations§
Source§impl<S: DowningStrategy> SbrRuntime<S>
impl<S: DowningStrategy> SbrRuntime<S>
pub fn new(strategy: S, stable_after: Duration) -> Self
Sourcepub fn with_observer(self, observer: Arc<dyn QuorumObserver>) -> Self
pub fn with_observer(self, observer: Arc<dyn QuorumObserver>) -> Self
Attach a QuorumObserver (FR-7b). Builder-style; consumes and
returns self.
Sourcepub fn tick(&mut self, state: &MembershipState, now: Instant) -> SbrAction
pub fn tick(&mut self, state: &MembershipState, now: Instant) -> SbrAction
One scheduling tick. Returns the action the leader should apply — typically nothing, sometimes a downing list.
Auto Trait Implementations§
impl<S> Freeze for SbrRuntime<S>where
S: Freeze,
impl<S> !RefUnwindSafe for SbrRuntime<S>
impl<S> Send for SbrRuntime<S>
impl<S> Sync for SbrRuntime<S>
impl<S> Unpin for SbrRuntime<S>where
S: Unpin,
impl<S> UnsafeUnpin for SbrRuntime<S>where
S: UnsafeUnpin,
impl<S> !UnwindSafe for SbrRuntime<S>
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