kafka/core
Gaurav Narula 36b9bb94f1
CI / build (push) Waiting to run Details
KAFKA-19474 Move WARN log on log truncation below HWM (#20106)
#5608 introduced a regression where the check for `targetOffset <
log.highWatermark`
to emit a `WARN` log was made incorrectly after truncating the log.

This change moves the check for `targetOffset < log.highWatermark`  to
`UnifiedLog#truncateTo` and ensures we emit a `WARN` log on truncation
below  the replica's HWM by both the `ReplicaFetcherThread` and
`ReplicaAlterLogDirsThread`

Reviewers: Jun Rao <junrao@gmail.com>, Chia-Ping Tsai
 <chia7712@gmail.com>
2025-07-09 09:55:02 +08:00
..
src KAFKA-19474 Move WARN log on log truncation below HWM (#20106) 2025-07-09 09:55:02 +08:00
.gitignore