THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
Following are examples of a CLI tool built on top of FeatureCommand
, .
It demonstrates the type of options supported, and the their output.
Code Block |
---|
=== DESCRIBE FEATURES === # Get cluster-wide finalized features, and features supported by a specific broker. # - Use `--bootstrap-server` to provide a broker host:port to which queries should be issued. # - Optionally, provide `--controller` flag directing the tool to issue the query to the # controller (while discovering the controller via the bootstrap server). # This can be useful for debugging purposes. $> kafka-features.sh describe --bootstrap-server kafka-broker0.prn1:9071 --controller { "status": "OK", "supported_features": { "group_coordinator": { "minVersion": 1, "maxVersion": 2 }, "transaction_coordinator": { "minVersion": 0, "maxVersion": 5 }, "consumer_offsets_topic_schema": { "minVersion": 3, "maxVersion": 7 } }, "finalized_features": { "group_coordinator": { "version": 1 }, "transaction_coordinator": { "version": 4 }, "consumer_offsets_topic_schema": { "version": 7 } }, "host": "kafka-broker0.prn1", "port": 9071 } === ADD_OR_UPDATE FEATURES === # Add or update a list of cluster-wide finalized features. # - Use `--bootstrap-server` to provide a broker host:port to which MetadataRequest query should be issued. # The MetadataResponse will be used to discover the Controller, to which the actual ADD_OR_UPDATE request is issued. # - Use `--features` to provide a comma-separated list of features and their new finalized versions to ADD_OR_UPDATE. $> kafka-features.sh update --bootstrap-server kafka-broker0.prn1:9071 --features group_coordinator:2,transaction_coordinator:5 Please confirm before finalizing the upgrade of the following features: 1. group_coordinator from v1 (existing) to v2 (new) 2. transaction_coordinator from v4 (existing) to v5 (new) [Y/n]? Y { "status": "OK", "supported_features": { "group_coordinator": { "minVersion": 1, "maxVersion": 2 }, "transaction_coordinator": { "minVersion": 0, "maxVersion": 5 }, "consumer_offsets_topic_schema": { "minVersion": 3, "maxVersion": 7 } }, "finalized_features": { "group_coordinator": { "version": 2 }, "transaction_coordinator": { "version": 5 }, "consumer_offsets_topic_schema": { "version": 7 } }, "host": "kafka-broker0.prn1", "port": 9071 } === DELETE FEATURES === # Delete a list of cluster-wide finalized features. # - Use `--bootstrap-server` to provide a broker host:port to which MetadataRequest query should be issued. # The MetadataResponse will be used to discover the Controller, to which the actual delete request is issued. # - Use `--features` to provide a comma-separated list of features to be deleted. $> kafka-features.sh delete --bootstrap-server kafka-broker0.prn1:9071 --features group_coordinator,transaction_coordinator Please confirm deletion of the following features: 1. group_coordinator 2. transaction_coordinator [Y/n] Y { "status": "OK", "supported_features": { "group_coordinator": { "minVersion": 1, "maxVersion": 2 }, "transaction_coordinator": { "minVersion": 0, "maxVersion": 5 }, "consumer_offsets_topic_schema": { "minVersion": 3, "maxVersion": 7 } }, "finalized_features": { "consumer_offsets_topic_schema": { "version": 7 } }, "host": "kafka-broker0.prn1", "port": 9071 } |
...