Documentation ¶
Index ¶
Constants ¶
View Source
const ( WorkingMode_INIT WorkingMode = "init" WorkingMode_FOLLOWER = "follower" WorkingMode_LEADER = "leader" WorkingMode_UNSAFE = "unsafe" )
View Source
const (
StatusKey_WorkMode = "work_mode"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Election ¶
type Election struct {
// contains filtered or unexported fields
}
func NewElection ¶
func NewElection(config *ElectionConfig) *Election
func (*Election) ChangeNotify ¶
func (o *Election) ChangeNotify() <-chan struct{}
func (*Election) QuitNotify ¶
func (o *Election) QuitNotify() <-chan struct{}
type ElectionConfig ¶
type WorkingMode ¶
type WorkingMode string
Click to show internal directories.
Click to hide internal directories.