Crate tender

Source
Expand description

Raft-based election framework.

Structs§

Election
The election API.
HardState
Election persistent state.
HeartbeatRequest
Heartbeat request.
HeartbeatResponse
Heartbeat response.
Metrics
A set of metrics describing the current state of election.
MetricsWatcher
The metrics watcher of the node.
MoveLeaderRequest
MoveLeader request.
Options
The election runtime configurations.
OptionsBuilder
The builder of election runtime configurations.
VoteRequest
Vote request.
VoteResponse
Vote response.

Enums§

Error
Error related to election.
Event
The event of election.
InitialMode
Initial mode when initialize election.
Quorum
The minimum number of votes that a node has to obtain in order to be the leader.
State
The state of the node.
VoteResult
Vote result.

Traits§

ElectionType
A trait defining application specific data type for election.
EventHandler
The event handler of election.
NodeId
Unique id used to identify the node.
Rpc
RPC interfaces used by election.
Storage
Storage interfaces used by election.
TaskSpawner
Spawner for internal short-time task.
Thread
Thread used for election main thread.
VoteFactor
Application specific data involved in voting.

Type Aliases§

Result
The result of election process.