Skip to content

Instantly share code, notes, and snippets.

Naveen naveen09

View GitHub Profile
@naveen09
naveen09 / kafka-cheat-sheet.md
Created Apr 19, 2019 — forked from ursuad/kafka-cheat-sheet.md
Quick command reference for Apache Kafka
View kafka-cheat-sheet.md

Kafka Topics

List existing topics

bin/kafka-topics.sh --zookeeper localhost:2181 --list

Describe a topic

bin/kafka-topics.sh --zookeeper localhost:2181 --describe --topic mytopic

Purge a topic

bin/kafka-topics.sh --zookeeper localhost:2181 --alter --topic mytopic --config retention.ms=1000

... wait a minute ...

You can’t perform that action at this time.