DUE TO SPAM, SIGN-UP IS DISABLED. Goto Selfserve wiki signup and request an account.
| Table of Contents |
|---|
Status
Current state: Under discussionAccepted
Discussion thread: here
JIRA: here
...
- Add
--bootstrap-servertokafka-producer-perf-test.shbringing it into line with all the other tools. Because users will already have config files which specify the bootstrap server and there's no need to break these, the new--bootstrap-serverflag is optional. If provided, it takes precedence over specifyingbootstrap.serversin the configuration file. The order of precedence for configuring the bootstrap server from highest to lowest is--bootstrap-server, then--command-property(previously called--producer-props), then--command-config. - Introduce consistent use of
--command-propertyas a way of providing individual configuration properties without use of a configuration file. Replace--producer-propswith--producercommand-propertyinkafka-producer-perf-test.sh, bringing it into line with the other tools that accept producer or consumer properties . Add--command-propertytokafka-consumer-perf-test.shandkafka-share-consumer-perf-test.sh. - For the console producer and consumer tools, replace
--producer-propertyand--consumer-propertywith--command-property. - For all tools which support a properties file, replace the existing option for specifying a configuration properties file with
--command-config. This eliminates the guesswork about whether a particular tool uses the producer, consumer or admin APIs and then chose to pass this knowledge into the original names of the command-line arguments. - Add
--reporting-intervaltokafka-producer-perf-test.sh. The tools already has a reporting interval hard-coded to 5000ms, so this simply makes it configurable like for the consumer performance tests, with a default of 5000ms. - Replace
--propertywith--formatter-propertyinkafka-console-consumer.shandkafka-console-share-consumer.sh. This argument is used to configure the formatter, so this names it accordingly. - Replace
--propertywith--reader-propertyinkafka-console-producer.sh. This argument is used to configure the message reader, so this names it accordingly and also matches the existing--reader-configargument. - Replace
--messageswith--num-recordsinkafka-consumer-perf-test.shandkafka-share-consumer-perf-test.sh.
Proposed Changes
The following table shows the existing and proposed options. The changes are in GREEN.
Tools | Existing option for bootstrap server | Proposed option for bootstrap server | Existing option for properties | Proposed option for properties | Existing option for config file | Proposed option for config file |
kafka-acls.sh | --bootstrap-server | --command-config | ||||
kafka-broker-api-versions.sh | --bootstrap-server | --command-config | ||||
kafka-client-metrics.sh | --bootstrap-server | --command-config | ||||
kafka-cluster.sh | --bootstrap-server | --config | --command-config | |||
kafka-configs.sh | --bootstrap-server | --command-config | ||||
kafka-console-consumer.sh | --bootstrap-server | --consumer-property | --command-property | --consumer.config | --command-config | |
kafka-console-producer.sh | --bootstrap-server | --producer-property | --command-property | --producer.config | --command-config | |
kafka-console-share-consumer.sh | --bootstrap-server | --consumer-property | --command-property | --consumer-config | --command-config | |
kafka-consumer-groups.sh | --bootstrap-server | --command-config | ||||
kafka-consumer-perf-test.sh | --bootstrap-server | --command-property | --consumer.config | --command-config | ||
kafka-delegation-tokens.sh | --bootstrap-server | --command-config | ||||
kafka-delete-records.sh | --bootstrap-server | --command-config | ||||
kafka-features.sh | --bootstrap-server | --command-config | ||||
kafka-get-offsets.sh | --bootstrap-server | --command-config | ||||
kafka-groups.sh | --bootstrap-server | --command-config | ||||
kafka-leader-election-sh | --bootstrap-server | --admin.config | --command-config | |||
kafka-log-dirs.sh | --bootstrap-server | --command-config | ||||
kafka-metadata-quorum.sh | --bootstrap-server | --command-config | ||||
kafka-producer-perf-test.sh | --bootstrap-server | --producer-props | --producercommand-property | --producer.config | --command-config | |
kafka-reassign-partitions.sh | --bootstrap-server | --command-config | ||||
kafka-share-consumer-perf-test.sh | --bootstrap-server | --command-property | --consumer.config | --command-config | ||
kafka-share-groups.sh | --bootstrap-server | --command-config | ||||
kafka-streams-application-reset.sh | --bootstrap-server | --config-file | --command-config | |||
kafka-streams-groups.sh | --bootstrap-server | --command-config | ||||
kafka-topics.sh | --bootstrap-server | --command-config | ||||
kafka-transactions.sh | --bootstrap-server | --command-config | ||||
kafka-verifiable-consumer.sh | --bootstrap-server | --consumer.config | --command-config | |||
kafka-verifiable-producer.sh | --bootstrap-server | --producer.config | --command-config | |||
kafka-verifiable-share-consumer.sh | --bootstrap-server | --command-config |
...
The existing options will be deprecated until the next major Apache Kafka release, and then they will be removed. During the deprecation period, using the old parameter names will cause a deprecation message to be displayed. It is an error to use both the old name and the new name together - they are mutually exclusive.
All uses of the command-line tools in the Apache Kafka codebase such as system tests will be migrated over to the new parameter names.
...
The KIP will be tested with unit tests.
For tests such as system tests which use these command-line tools, the tests will be migrated across to the new parameter names providing additional validation.
Rejected Alternatives
An alternative for tools such as kafka-verifiable-producer.sh would be rename --producer.config to --producer-config instead of --command-config . This was rejected because some of the tools such as kafka-verifiable-share-consumer.sh actually use multiple APIs (consumer and admin in this case) so the clean simplicity of --command-config was chosen instead for all tools.