How long RabbitMQ keeps the messages for disconnected consumers?
Let's say that a consumer for a queue has been disconnected for some time during which many number of messages are produced.
How long does RabbitMQ keep the messages for the disconnected consumer without durable mode? (Will it discard the queue right after the consumer is disconnected? or will it keep the queue until the memory allows?)
Does the durable mode will give a functionality for a consumer to consume any message which is published until now? (ie random access to the queue, fetching messages out-of-order, or consuming from the beginning of the queue)
TTL can be set for a given queue by setting the x-message-ttl
argument to queue.declare, or by setting the message-ttl
policy.