I don't think there is any example, but seems to be more or less
"straightforward" to do?
However, I am wondering about the usage pattern? Does not sound like a
good fit for Kafka. Producers and consumer should be long lived. It's an
anti pattern to use short lived clients (Kafka is optimized for stream
processing, not ad-hoc read/writes).
What are you trying to do?
Also: if the same process write the message, why would you need to read
it back anyway?
On 8/20/24 5:31 PM, Keith Brown wrote:
I would like to have a producer and consumer in the same binary. I
want to send a message and have the consumer read the message and exit
immediately. Is there an example I can follow for something like this?