Difference between @KafkaListener, @StreamListener and @ServiceActivator?

Viewed 3467

I want to use Kafka with Spring Boot and with Avro schemas. But I'm stucked on 'What is the difference between those 3 listeners?'. There are 3 possibilities to create listeners: annotate a method with - @KafkaListener, @StreamListener or @ServiceActivator. Seems like all of them are listening for incoming events but I cannot see/find difference between those solutions.

  1. What is the difference between those three?
  2. What are prons and cons of each solution?
  3. Which fits more for purpose of using Avro?
1 Answers
Related