mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
raft: rename makeP{RS,rogressTracker}
This commit is contained in:
@@ -343,7 +343,7 @@ func newRaft(c *Config) *raft {
|
||||
raftLog: raftlog,
|
||||
maxMsgSize: c.MaxSizePerMsg,
|
||||
maxUncommittedSize: c.MaxUncommittedEntriesSize,
|
||||
prs: makePRS(c.MaxInflightMsgs),
|
||||
prs: makeProgressTracker(c.MaxInflightMsgs),
|
||||
electionTimeout: c.ElectionTick,
|
||||
heartbeatTimeout: c.HeartbeatTick,
|
||||
logger: c.Logger,
|
||||
@@ -1346,7 +1346,7 @@ func (r *raft) restore(s pb.Snapshot) bool {
|
||||
r.id, r.raftLog.committed, r.raftLog.lastIndex(), r.raftLog.lastTerm(), s.Metadata.Index, s.Metadata.Term)
|
||||
|
||||
r.raftLog.restore(s)
|
||||
r.prs = makePRS(r.prs.maxInflight)
|
||||
r.prs = makeProgressTracker(r.prs.maxInflight)
|
||||
r.restoreNode(s.Metadata.ConfState.Nodes, false)
|
||||
r.restoreNode(s.Metadata.ConfState.Learners, true)
|
||||
return true
|
||||
|
||||
Reference in New Issue
Block a user