Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-10664

Streams fails to overwrite corrupted offsets leading to infinite OffsetOutOfRangeException loop

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Blocker
    • Resolution: Fixed
    • 2.7.0
    • 2.7.0
    • streams
    • None

    Description

      In KAFKA-10391 we fixed an issue where Streams could get stuck in an infinite loop of  OffsetOutOfRangeException/TaskCorruptedException due to re-initializing the corrupted offsets from the checkpoint after each revival. The fix we applied was to remove the corrupted offsets from the state manager and then force it to write a new checkpoint file without those offsets during revival.

      Unfortunately we missed that there's an optimization in OffsetCheckpoint#write to just return without writing anything when there's no offsets. So if a task doesn't have any offsets that aren't corrupted, it will skip overwriting the corrupted checkpoint.

      Probably we should just fix the optimization in OffsetCheckpoint so that it deletes the current checkpoint in the case there are no offsets to write

      Attachments

        Issue Links

          Activity

            People

              ableegoldman A. Sophie Blee-Goldman
              ableegoldman A. Sophie Blee-Goldman
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: