jsancio opened a new pull request #11084: URL: https://github.com/apache/kafka/pull/11084
This commit includes a few changes: 1. The leader assumes that there is always an in-memory snapshot at the last committed offset. This means that the controller needs to generate an in-memory snapshot when getting promoted from inactive to active. 2. Delete all in-memory snapshots less that the last committed offset when the on-disk snapshot is canceled or it completes. 3. The controller always starts inactive. When loading an on-disk snapshot the controller is always inactive. This means that we don't need to generate an in-memory snapshot at the offset -1 because there is no requirement that there exists an in-memory snapshot at the last committed offset when the controller is inactive. 4. SnapshotRegistry's createSnapshot should allow the creating of a snapshot if the last snapshot's offset is the given offset. This allows for simpler client code. ### Committer Checklist (excluded from commit message) - [ ] Verify design and implementation - [ ] Verify test coverage and CI build status - [ ] Verify documentation (including upgrade notes) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org