Open ashishbhatia22 opened 5 years ago
librdkafka doesn't expose statistics for compression ratio AFAICT. The java producer does. This would be good to add (marked as enhancement). you'd need to work it out yourself using the values that are provided (in stats, by broker metrics & by knowing the uncompressed size of your messages), and I think that would not be trivial. I had a play and don't think it's easy to verify compression is turned on, even with debug
messages. if you've set the configuration parameter though, and you didn't get an error message, you can be sure it is being used.
Thanks. I was wondering if a command like this will be helfpul to validate
./kafka-log-dirs --bootstrap-server --topic-list CompressionTopic --describe
if you want to get really low level, you could use DumpLogSegments:
./bin/kafka-run-class kafka.tools.DumpLogSegments --deep-iteration --files <log-file-name>
Description
We will like to enable compression before sending messages to the bus. I've set the following setting:
compression.codec: "snappy"
Is there a way to find out if this setting is taking effect? Also, can we find out the compression efficiency i.e. message size after the compression is enabled?