pub struct StateMachine { /* private fields */ }Expand description
The replicated state machine with in-memory storage. For production use, consider using DatabaseStateMachine which persists to storage.
Implementations§
Source§impl StateMachine
impl StateMachine
Trait Implementations§
Source§impl Default for StateMachine
impl Default for StateMachine
Source§impl StateMachineBackend for StateMachine
impl StateMachineBackend for StateMachine
Source§fn apply(&self, command: &Command, index: u64) -> CommandResult
fn apply(&self, command: &Command, index: u64) -> CommandResult
Apply a command to the state machine at the given log index.
Source§fn last_applied(&self) -> u64
fn last_applied(&self) -> u64
Get the last applied log index.
Auto Trait Implementations§
impl !Freeze for StateMachine
impl RefUnwindSafe for StateMachine
impl Send for StateMachine
impl Sync for StateMachine
impl Unpin for StateMachine
impl UnsafeUnpin for StateMachine
impl UnwindSafe for StateMachine
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