This sample application shows how to use basic Spring Boot configuration to set up a producer to a topic with multiple partitions and a consumer group with three different consumers.
To illustrate the different configuration options, this application deserializes Kafka messages in three different ways:
- As a simple String (plain JSON).
- As a JSON to Java object.
- As a byte array(I'll add those)
- GET: http:localhost:8080/api/v1/message?message=Hello from kafka producer
- GET: http:localhost:8080/api/v1/json/message
- Request Body: {"id": "1", "firstName": "shantanu", "lastName": "Barua" }
Give a star to this project, and consider some extra readings: