mimaison commented on code in PR #23316:
URL: https://github.com/apache/kafka/pull/23316#discussion_r3957829485
##########
storage/src/main/java/org/apache/kafka/storage/internals/log/UnifiedLog.java:
##########
@@ -944,6 +944,20 @@ public int numberOfSegments() {
return localLog.segments().numberOfSegments();
}
+ /**
+ * Append the largest time index entry to the time index of the active
segment and trim the log and indexes.
+ * This is the same operation performed when rolling a segment and should
be called before flushing and
+ * closing the log during shutdown.
+ */
+ public void prepareActiveSegmentForClose() {
Review Comment:
Yes these can now be removed. This effectively overwrites
https://github.com/apache/kafka/commit/18cdc642d8ce7aff66f5db9b682e552c09e2c796
which swapped trim/flush.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]