hachikuji commented on code in PR #13396: URL: https://github.com/apache/kafka/pull/13396#discussion_r1136194254
########## raft/src/test/java/org/apache/kafka/raft/RaftClientTestContext.java: ########## @@ -975,6 +980,18 @@ void assertFetchRequestData( assertEquals(fetchOffset, fetchPartition.fetchOffset()); assertEquals(lastFetchedEpoch, fetchPartition.lastFetchedEpoch()); assertEquals(localId.orElse(-1), request.replicaId()); + + // Assert that voters have flushed up to the fetch offset + if (localId.isPresent() && voters.contains(localId.getAsInt())) { Review Comment: If someone removed the optimization, it might be a notable regression in performance, but no tests would fail. I think that makes it worthwhile. -- 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