Skip to content

Instantly share code, notes, and snippets.


pramodpk89/ Secret

Created May 1, 2020
What would you like to do?
package com.ppk.kafkareader.service;
import lombok.SneakyThrows;
import org.json.simple.JSONObject;
import org.json.simple.parser.JSONParser;
import org.springframework.kafka.annotation.KafkaListener;
import org.springframework.stereotype.Service;
public class kafkaService {
@KafkaListener(topics = "first_topic")
public void readPayload(String payload) {
System.out.println("Message read from kafka "+payload);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment