jsancio commented on a change in pull request #10085:
URL: https://github.com/apache/kafka/pull/10085#discussion_r600925523
##########
File path: raft/src/main/java/org/apache/kafka/raft/ReplicatedCounter.java
##########
@@ -87,6 +96,25 @@ public synchronized void handleCommit(BatchReader<Integer>
reader) {
}
}
+ @Override
+ public synchronized void handleSnapshot(SnapshotReader<Integer> reader) {
+ try {
+ try (SnapshotReader<Integer> snapshot = reader) {
+ log.debug("Loading snapshot {}", snapshot.snapshotId());
+ for (List<Integer> batch : snapshot) {
Review comment:
Yes. I missed this. `ReplicatedCounter` now generates a snapshot after
more than 10 records. Fix the existing simulation tests to take snapshot into
account.
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]