-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
Milestone
Description
Can you please share a code snippet how to invoke the pause( )/resume( ) on the listener instead on a consumer as advised in spring-kafka reference doc as it is not always thread-safe.
I tried injecting or Autowiring the listener in the kafka-consumer but it lead to below cyclic error
The dependencies of some of the beans in the application context form a cycle: because
┌─────┐
| myListener defined in class path resource [no/demo/services/configuration/KafkaConfiguration.class]
↑ ↓
| myMessageConsumer (field org.springframework.kafka.listener.KafkaMessageListenerContainer no.demo.services.MyMessageConsumer.myListener)
└─────┘
shankarps