Skip to content

Commit

Permalink
kv: remove raft leader progress override in newTruncateDecision
Browse files Browse the repository at this point in the history
Addresses a long-standing TODO.

We picked up etcd-io/etcd#10279 a while ago.
  • Loading branch information
nvanbenschoten committed Apr 6, 2022
1 parent ca89922 commit cacac45
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions pkg/kv/kvserver/raft_log_queue.go
Original file line number Diff line number Diff line change
Expand Up @@ -309,13 +309,6 @@ func newTruncateDecision(ctx context.Context, r *Replica) (truncateDecision, err
log.Eventf(ctx, "raft status after lastUpdateTimes check: %+v", raftStatus.Progress)
r.mu.RUnlock()

if pr, ok := raftStatus.Progress[raftStatus.Lead]; ok {
// TODO(tschottdorf): remove this line once we have picked up
// https://github.com/etcd-io/etcd/pull/10279
pr.State = tracker.StateReplicate
raftStatus.Progress[raftStatus.Lead] = pr
}

input := truncateDecisionInput{
RaftStatus: *raftStatus,
LogSize: raftLogSize,
Expand Down

0 comments on commit cacac45

Please sign in to comment.