How to disable RabbitMQ prefetch count with SimpleMessageListenerContainer
问题 RabbitMQ offers the ability to optionally set a prefetch count. Using spring-amqp's SimpleMessageListenerContainer , I've noticed the prefetch count is always set. I cannot set the prefetch count to 0, because SimpleMessageListenerContainer sets it to at least txSize which must be greater than zero (even when there are no transactions involved). So is there a way to disable the prefetch count, i.e. make it unlimited? Here is the relevant code from spring-amqp: SimpleMessageListenerContainer