I am using spring boot 2.1.1 release and spring-boot-starter-amqp , the @@RabbitListener stopped consuming messages although it was working fine. When i restarted the consumer API , it starts to work fine.
Also from the management UI, it shows no consumers on this queue
Heartbeates and keepalive with default values I tried to re-synchronize the queue via rabbitmqctl, but it still not working.
@Component
public class Receiver {
Logger logger = Logger.getLogger(Receiver.class);
@RabbitListener(queues="test")
public void recievedMessage(String msg) {
logger.info("Recieved Message: " + msg);
}
}
The most common cause, by far, for problems like this is the container thread is "stuck" somewhere in user code - either in the listener, or code called by the listener; e.g. a deadlock.
First step is to take a thread dump the next time it happens to see what the listener container thread(s) are doing.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With