Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/ByteStorage/FlyDB
/ IsLeader
Method
IsLeader
lib/raft/raft_impl.go:33–35 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
31
}
32
33
func
(i *Impl) IsLeader() bool {
34
return
i.m.Raft.State() == raft.Leader
35
}
36
37
func
(i *Impl) IsCandidate() bool {
38
return
i.m.Raft.State() == raft.Candidate
Callers
nothing calls this directly
Calls
1
State
Method · 0.65
Tested by
no test coverage detected