Created
December 31, 2019 22:08
-
-
Save timhugh/0e900dcd44b83786eb95535f7adef8c2 to your computer and use it in GitHub Desktop.
Kafka CLI Cheatsheet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Selecting a server | |
kafka-topics --bootstrap-server kafka:9092 | |
kafka-console-producer --broker-list kafka:9092 | |
kafka-console-consumer --bootstrap-server kafka:9092 | |
# Managing topics | |
kafka-topics --list | |
kafka-topics --describe --topic topic.name | |
kafka-topics --create --partitions 1 --replication-factor 1 --topic topic.name | |
kafka-topics --delete --topic topic.name | |
# producing messages | |
kafka-console-producer --topic topic.name | |
# consuming messages | |
kafka-console-consumer --topic topic.name |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment