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

Perform CRC validation on KRaft Batch Records and Snapshots

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Blocker
    • Resolution: Fixed
    • 3.2.0
    • 3.3.0
    • None
    • None

    Description

      Today we stamp the BatchRecord header with a CRC [1] and verify that CRC before the log is written to disk [2]. The CRC checks should also be verified when the records are read back from disk. The same procedure should be followed for KRaft snapshots as well.

      [1] https://github.com/apache/kafka/blob/6b76c01cf895db0651e2cdcc07c2c392f00a8ceb/clients/src/main/java/org/apache/kafka/common/record/DefaultRecordBatch.java#L501=

      [2] https://github.com/apache/kafka/blob/679e9e0cee67e7d3d2ece204a421ea7da31d73e9/core/src/main/scala/kafka/log/UnifiedLog.scala#L1143

      Attachments

        Issue Links

          Activity

            People

              Niket Goel Niket Goel
              Niket Goel Niket Goel
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: