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

Adding checks on "version" field for tools using it

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.0.0
    • Component/s: tools
    • Labels:
      None

      Description

      Hi,
      the kafka-delete-records script allows user to pass information about records to delete through a JSON file. Such file, as described in the command help, is made by a "partitions" array and a "version" field. Reading KIP-107 and the DeleteRecords API (Key: 21) description it's not clear what such field is and even it's not used at all (in the current implementation).
      It turned out that the field is for having backward compatibility in the future where the JSON format could change. This JIRA is about adding more checks on the "version" field having it not mandatory but assuming the earliest version (current 1) if it's omitted from the JSON file.

      The same for the kafka-reassign-partitions which has a topics-to-move JSON file as input (used with --generate option) and the partitions-to-move.json (used with --execute option). In both cases the same logic can be applied as above.

        Attachments

          Activity

            People

            • Assignee:
              ppatierno Paolo Patierno
              Reporter:
              ppatierno Paolo Patierno
              Reviewer:
              Ismael Juma
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: