Skip to content

Commit

Permalink
separate maybeCompactRaftLog function to compact raft log independent…
Browse files Browse the repository at this point in the history
…ly from snapshots

Signed-off-by: Clement <[email protected]>
  • Loading branch information
clement2026 committed Sep 24, 2024
1 parent 9b04e4d commit 1d08b34
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion server/etcdserver/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -2181,7 +2181,6 @@ func (s *EtcdServer) maybeCompactRaftLog(ep *etcdProgress) {
return
}

// make sure compacti > 0, because s.r.raftStorage.Compact(compacti) returns ErrCompacted if compacti = 0
compacti := ep.snapi - s.Cfg.SnapshotCatchUpEntries

lg := s.Logger()
Expand Down

0 comments on commit 1d08b34

Please sign in to comment.