Hi Kafka users,

I am trying to understand the behavior of compression in Kafka. Consider a
scenario, where producer sets compression.codec "snappy" and broker's
compression.code  "lz4"?
In this scenario, what is the behavior of the compression?

As far as I have understood is the following,
The messages compressed by the producer are wrapped in the wrapper message
and send to the broker. If the broker compression.codec is "producer", the
message is written as is to the log.
In the code,


what I understand is that if the producer and broker codecs are not same,
then the compression should happen again.

But I am not sure about this. Can somebody tell me how this works?


Reply via email to