Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrNotLeader is returned when an operation that must be done by // the cluster leader is being tryed on a follower ErrNotLeader = errors.New("RAFT: Not leader") // ErrRemovingNode is returned when service fails to remove a node from // the cluster ErrRemovingNode = errors.New("RAFT: Error removing node") )
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
Store is the struct that holds the information on the nodes In order to replicate and distribute in a secure way the information
the keys and values are changed via distributed consensus (raft).
func New ¶
func New(inst *instrumentation.Instrumentation, tick time.Duration) *Store
New returns the Store
func (*Store) Join ¶
Join joins a node, identified by nodeID and located at addr, to this store. The node must be ready to respond to Raft communications at that address.
Click to show internal directories.
Click to hide internal directories.