raft 0.1.0
Loading...
Searching...
No Matches
Public Attributes | List of all members
raft::ServerCreateConfig Struct Reference

Configuration for creating a Raft server. More...

#include <server.hpp>

Collaboration diagram for raft::ServerCreateConfig:
Collaboration graph
[legend]

Public Attributes

std::string id
 The ID of the server.
 
std::shared_ptr< ClientFactoryclientFactory
 The client factory to use.
 
std::vector< Peerpeers
 The list of other addresses of Raft servers in the cluster.
 
std::shared_ptr< Persisterpersister
 The persister to use.
 
std::optional< CommitCallback > commitCallback
 The commit callback to use.
 
std::optional< LeaderChangedCallback > leaderChangedCallback
 The leader changed callback to use.
 
TimeoutInterval timeoutInterval
 The election timeout interval.
 
uint64_t heartbeatInterval = DEFAULT_HEARTBEAT_INTERVAL
 The heartbeat interval.
 
uint16_t threadCount = 1
 The number of threads to use for network I/O and consensus.
 

Detailed Description

Configuration for creating a Raft server.


The documentation for this struct was generated from the following file: