Skip to content

Instantly share code, notes, and snippets.

@mostafa-asg
Last active June 12, 2024 16:31
Show Gist options
  • Save mostafa-asg/a92d37af3635ee5a4b65568a2f24192b to your computer and use it in GitHub Desktop.
Save mostafa-asg/a92d37af3635ee5a4b65568a2f24192b to your computer and use it in GitHub Desktop.
Print key of records in kafka-console-consumer
use --property print.key=true
Example : ./kafka-console-consumer.sh --bootstrap-server <BROKERS_ADDRESS> --topic <YOUR_TOPIC> --property print.key=true
@JakkuSakura
Copy link

How there should be --bootstrap-server, no --zookeeper anymore

@mostafa-asg
Copy link
Author

Thanks @qiujiangkun, applied.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment