Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Election ¶
Election objects keep track of the outcome of a single leader election by mapping remote peers to the votes they've provided. Uses simple majority to determine if an election has passed or failed.
func New ¶
New creates an election for the specified peers, defaulting the votes to false until otherwise updated. Elections only allow the peers specified to vote.
Click to show internal directories.
Click to hide internal directories.