little_raft/lib.rs
1//! This crate is a small but full-featured implementation of the Raft
2//! distributed consensus protocol. By using this library, you can run a
3//! replicated state machine in your own cluster. The cluster could be comprised
4//! of dozens of physical servers in different parts of the world or of two
5//! threads on a single CPU.
6//!
7//! The goal of this library is to provide a generic implementation of the
8//! algorithm that the library user can leverage in their own way. It is
9//! entirely up to the user how to configure the Raft cluster, how to ensure
10//! communication between the nodes, how to process client's messages, how to do
11//! service discovery, and what kind of state machine to replicate.
12//!
13//! The implementation is kept as simple as possible on purpose, with the entire
14//! library code base fitting in under 1,000 lines of code.
15pub mod cluster;
16pub mod message;
17pub mod replica;
18pub mod state_machine;
19mod timer;