Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Raft Process

The core of Multi-Raft is Raft process. Each Multi-Raft server has one or more Raft processes.

To implement Multi-Raft, Sorock implements Raft process as it is fully agnostic to detailed node communications through gRPC. Since the Raft process doesn’t know about the IO, we call it Pure Raft.

To make Raft process to communicate with other Raft processes through network, RaftIO must be provided. Everything about actual on-network communication is encapsulated under RaftIO.

#![allow(unused)]
fn main() {
impl RaftProcess {
    pub async fn new(
        app: impl RaftApp,
        storage: &RaftStorage,
        io: RaftIO,
    ) -> Result<Self> {
}