mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
etcdserver: adjust election ticks on restart
Signed-off-by: Gyuho Lee <gyuhox@gmail.com>
This commit is contained in:
parent
c536205249
commit
8eeab582d0
@ -368,8 +368,7 @@ func startNode(cfg *ServerConfig, cl *membership.RaftCluster, ids []types.ID) (i
|
|||||||
raftStatusMu.Lock()
|
raftStatusMu.Lock()
|
||||||
raftStatus = n.Status
|
raftStatus = n.Status
|
||||||
raftStatusMu.Unlock()
|
raftStatusMu.Unlock()
|
||||||
advanceTicksForElection(n, c.ElectionTick)
|
return id, n, s, w
|
||||||
return
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func restartNode(cfg *ServerConfig, snapshot *raftpb.Snapshot) (types.ID, *membership.RaftCluster, raft.Node, *raft.MemoryStorage, *wal.WAL) {
|
func restartNode(cfg *ServerConfig, snapshot *raftpb.Snapshot) (types.ID, *membership.RaftCluster, raft.Node, *raft.MemoryStorage, *wal.WAL) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user