Struct openraft_memstore::MemStoreStateMachine
source · pub struct MemStoreStateMachine {
pub last_applied_log: Option<LogId<MemNodeId>>,
pub last_membership: StoredMembership<MemNodeId, ()>,
pub client_serial_responses: HashMap<String, (u64, Option<String>)>,
pub client_status: HashMap<String, String>,
}
Expand description
The state machine of the MemStore
.
Fields§
§last_applied_log: Option<LogId<MemNodeId>>
§last_membership: StoredMembership<MemNodeId, ()>
§client_serial_responses: HashMap<String, (u64, Option<String>)>
A mapping of client IDs to their state info.
client_status: HashMap<String, String>
The current status of a client by ID.
Trait Implementations§
source§impl Clone for MemStoreStateMachine
impl Clone for MemStoreStateMachine
source§fn clone(&self) -> MemStoreStateMachine
fn clone(&self) -> MemStoreStateMachine
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for MemStoreStateMachine
impl Debug for MemStoreStateMachine
source§impl Default for MemStoreStateMachine
impl Default for MemStoreStateMachine
source§fn default() -> MemStoreStateMachine
fn default() -> MemStoreStateMachine
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for MemStoreStateMachine
impl<'de> Deserialize<'de> for MemStoreStateMachine
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 RaftStorageDebug<MemStoreStateMachine> for Arc<MemStore>
impl RaftStorageDebug<MemStoreStateMachine> for Arc<MemStore>
source§fn get_state_machine<'life0, 'async_trait>(
&'life0 mut self
) -> Pin<Box<dyn Future<Output = MemStoreStateMachine> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_state_machine<'life0, 'async_trait>( &'life0 mut self ) -> Pin<Box<dyn Future<Output = MemStoreStateMachine> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait,
Get a handle to the state machine for testing purposes.