How can I print the timestamp with kafka-avro-console-consumer

I am able to print the time stamp with kafka-console-consumer using --property print.timestamp=true. But, this does not work with kafka-avro-console-consumer

please help me here


Iā€™m not able to repro this. If I follow this tutorial and append --property print.timestamp=true to the kafka-avro-console-consumer command, I see output prepended with timestamps like CreateTime:1701955706710. Iā€™d suggest running through this tutorial to confirm it also works on your end, and then compare its setup with yours.

You might also verify that you can see timestamps with kcat. You can print the message timestamp and Avro-formatted value like this:

kcat -b <bootstrap server> \
    -r <schema registry URL> \
    -t <topic> \
    -s value=avro \
    -f 'Timestamp: %T, Message value: %s\n'

thanks @dtroiano will try this