I have explored many tutorials but could not find the exact way to send multiple messages in one go to Kafka broker.
Example:
I want to send List employees using Kafka producer
producer.send(topicName, employees);
I don’t want records to be sent one by one, like running a loop and calling send method each time.
Could someone help me with the best way to achieve the same?