[rabbitmq-discuss] Losing messages, why?
jerryk at vmware.com
Tue Feb 22 22:36:40 GMT 2011
> rabbitmqctl list_queues name messages messages_ready messages_unacknowledged
> I get (for most of queues):
> queue_name_1 0 0 0
That looks good. That's either a queue to which nobody is publishing,
or one that's being consumed from at a brisk enough rate that nothing
is being left behind, either ready to be delivered to clients, or
already delivered to a client but not yet acknowledged.
> and for some queues:
> queue_name_2 239 239 0
> i.e. "messages" and "messages_ready" are greater than zero, but
> "messages_unacknowledged" are always the same (0).
I think earlier in the thread we established that all of your
consumers are consuming with noAck=true, so therefore everything
should be getting ACK-ed as its consumed. That would be consistent
with what we're seeing here, since there are no messages being
reported as unacknowledged by rabbitmqctl. On the other hand, since a
message has to be delivered before it can be ACK-ed, one would also
think that the messages_ready (the second column from the right in
your output) should also read zero.
Has, perhaps, one of your consumers died? Or become busy and stopped
consuming and acking from queue_name_2?
To investigate try:
That will show you the names of your queues, the id's of the channel
processes that created and now own the subscriptions, and tags that
let you identify a subscription within the channel. You'll also be
reminded there about whether or not ACKs are expected for messages
going to that consumer, but since you have nothing un-ACKed above, you
don't seem to be having a problem with this.
More information about the rabbitmq-discuss