Documentation
¶
Index ¶
- func NewEasyRaft(ctx context.Context, addr string, logger Logger, logStore LogStore, ...) (_ *raftService, err error)
- func NewEasyRaftInMemory(ctx context.Context, addr string, logger Logger, ...) (*raftService, error)
- type ConsensusValidatorFunc
- type KVState
- type LogStore
- type Logger
- type Raft
- type ServerID
- type SnapshotStore
- type StableStore
- type Transporter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewEasyRaft ¶
func NewEasyRaft( ctx context.Context, addr string, logger Logger, logStore LogStore, stableStore StableStore, snapshotStore SnapshotStore, transport Transporter, validators ...ConsensusValidatorFunc, ) (_ *raftService, err error)
func NewEasyRaftInMemory ¶
func NewEasyRaftInMemory( ctx context.Context, addr string, logger Logger, validators ...ConsensusValidatorFunc, ) (*raftService, error)
NewEasyRaftInMemory is not going to network - for testing purposes
Types ¶
type ConsensusValidatorFunc ¶
type SnapshotStore ¶
type SnapshotStore = raft.SnapshotStore
type StableStore ¶
type StableStore = raft.StableStore
type Transporter ¶
Click to show internal directories.
Click to hide internal directories.