viktorsomogyi commented on code in PR #19137:
URL: https://github.com/apache/kafka/pull/19137#discussion_r1983262909
##########
core/src/main/scala/kafka/log/UnifiedLog.scala:
##########
@@ -1522,6 +1522,9 @@ class UnifiedLog(@volatile var logStartOffset: Long,
val startMs = time.milliseconds
def shouldDelete(segment: LogSegment, nextSegmentOpt: Option[LogSegment]):
Boolean = {
+ if (startMs < segment.largestTimestamp()) {
+ warn(s"Segment with base offset $segment contains future timestamp")
Review Comment:
If I have 500GB logs with 1GB segment size, this log will print 500 times in
the worst case, but luckily only on log cleaning. I think we should approach
this the other way. What if we logged this on debug level and whoever needs
this can enable it in their own logging configs?
--
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]