zlayer-consensus 0.11.22

Shared Raft consensus library built on openraft 0.9 for ZLayer and Zatabase
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
//! Storage implementations for the Raft log and state machine.
//!
//! Two backends are provided:
//!
//! - **`MemStore`** (feature `mem-store`, default): BTreeMap-based in-memory storage.
//!   Suitable for testing and development. Data is lost on restart.
//!
//! - **`RedbStore`** (feature `redb-store`): Crash-safe persistent storage backed by
//!   the `redb` embedded database. Suitable for production deployments.

#[cfg(feature = "mem-store")]
pub mod mem_store;

#[cfg(feature = "redb-store")]
pub mod redb_store;