简体   繁体   中英

How much data is there in which partition in Kafka?

I am new to Kafka and I have a single broker node in which I have created one topic with 1 replica and 1500 partitions. I have pumped lot of data in this particular topic. Now is there any way, I can figure out how much data is there in which partition?

I am not sending any key while sending data to the kafka so I know it will choose partition in a round robin fashion but I want to see how much data is there in each of those 1500 partitions. Is there any way to figure this out?

Run command:

bin/kafka-run-class.sh kafka.tools.GetOffsetShell --broker-list host:port --topic your_topic --time -1

The result lists each partition's offset, which can be thought of produced message number.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM