[rabbitmq-discuss] Message wait time in a queue

Jerry Kuch jerryk at vmware.com
Tue Feb 7 16:28:15 GMT 2012


Hi, Rasadoll...

Do you really want to measure the time spent in a queue by the
message and do something with that information or do you just want 
messages to vanish after they get appropriately stale?  If the
latter, check out:

http://www.rabbitmq.com/extensions.html

And check out the "Per-Queue Message TTL" session.  It describes
a RabbitMQ extension to AMQP that lets you declare a queue with
a new argument, x-message-ttl, that controls how long a message
published to that queue can live before the broker discards it.
Messages that have exceeded the TTL set for their queue are
considered dead, won't be delivered to consumers, and will
be expunged periodically.

Note that you specify the TTL in *milliseconds*... :-)

Best regards,
Jerry

----- Original Message -----
From: "rasadoll" <rasadoll at gmail.com>
To: rabbitmq-discuss at lists.rabbitmq.com
Sent: Tuesday, February 7, 2012 8:11:33 AM
Subject: [rabbitmq-discuss] Message wait time in a queue

Hi,

How can we measure how long a message has been in a queue before it is
delivered to a consumer? If the message was in a queue for more than a
certain amount of time we would like to ignore it for example. Our
message publisher and consumers are on different machines and we
cannot synchronize their clocks, so the publish time cannot be set by
the publisher and checked by the consumer. Is there any way to get
this information from RabbitMQ?

Thanks,
_______________________________________________
rabbitmq-discuss mailing list
rabbitmq-discuss at lists.rabbitmq.com
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss


More information about the rabbitmq-discuss mailing list