I am trying to use the kafka-go package to write data to Kafka asynchronously, but it is not working. When I use synchronous mode, the data is written to Kafka successfully. However, when I use asynchronous mode, the data is not written to Kafka and the Write method returns immediately.
I am trying to use the kafka-go package to write data to Kafka asynchronously, but it is not working. When I use synchronous mode, the data is written to Kafka successfully. However, when I use asynchronous mode, the data is not written to Kafka and the Write method returns immediately.
var wr = kafka.Writer{ Addr: kafka.TCP("localhost:9092", "localhost:9093"), Balancer: &kafka.CRC32Balancer{}, Async: true, }