I am trying to consume Kafka message using below options [format token as requirement]
kafkacat -C -b localhost:9092 -t test-topic -p 0 -f 'Topic %t [%p] at offset %o: key %k: %s\n' -o -1 -e | jq .
But getting below error,
Error: file/topic list only allowed in producer(-P)/kafkaconsumer(-G) mode
Usage: <path> <options> [file1 file2 .. | topic1 topic2 ..]]
kcat - Apache Kafka producer and consumer tool
https://github.com/edenhill/kcat
If I try above command without -f
option then it works, but I want the formatted output. What would be the issue?