[rabbitmq-discuss] Age of message

cw storm cwstorm at gmail.com
Thu Mar 20 20:49:49 GMT 2014


I guess the client could include a timestamp during the publish and put it
in a header attribute.  The consumer can use that information and match
that against the current date time.

You see, there could be an issue with the client not setting the
acknowledge flag so that the message can be remove from the queue.  What
happens is that all other messages are back up until that one message is
acknowledge by the client.  At that time, anything can happen with the
environment.  The client server could be unavailable or that some other
components is working overtime which prevent the consumer service to
complete processing it correctly.  If everything goes well, then the last
step is to set that flag and the message will either be acknowledge or
rejected.  If rejected, it'll go back to the ready state and will process
again until it's acknowledge.  So, I'm trying to come up with a good
approach on reporting "stale" messages. I could get the total messages
waiting in the queue and if it's greater than say 100, then send an alert.
 But during runtime, one could get 1k messages in a queue and it just take
time to process so it's not really "stale".  But I guess this would be good
for now so that support person can phyiscially monitor it.


On Thu, Mar 20, 2014 at 4:24 PM, Alvaro Videla <videlalvaro at gmail.com>wrote:

> If you are not going to process the staled messages, then if they have
> TTL set, they will be dead lettered, by setting up a queue on that
> dead letter exchange, you could then report on those "staled"
> messages.
>
> RabbitMQ doesn't support browsing a queue and selecting message with
> certain age.
>
> On Thu, Mar 20, 2014 at 9:07 PM, cw storm <cwstorm at gmail.com> wrote:
> > TTL applies to expiring the message.  I don't want to set an expiration
> on
> > the message.  What we're trying to do is report on stale messages.
>  Trying
> > to find a reasonable design or approach on this topic.  Interested in how
> > everyone does it.
> >
> >
> > On Thu, Mar 20, 2014 at 3:54 PM, Alvaro Videla <videlalvaro at gmail.com>
> > wrote:
> >>
> >> On Thu, Mar 20, 2014 at 8:49 PM, cw storm <cwstorm at gmail.com> wrote:
> >> > We want to get an alert when messages haven't been ack since the time
> it
> >> > arrived in the queue.
> >>
> >> I don't think RabbitMQ could give you that functionality. In any case,
> >> have you looked into TTLs? http://www.rabbitmq.com/ttl.html
> >> _______________________________________________
> >> rabbitmq-discuss mailing list
> >> rabbitmq-discuss at lists.rabbitmq.com
> >> https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
> >
> >
> >
> > _______________________________________________
> > rabbitmq-discuss mailing list
> > rabbitmq-discuss at lists.rabbitmq.com
> > https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
> >
> _______________________________________________
> rabbitmq-discuss mailing list
> rabbitmq-discuss at lists.rabbitmq.com
> https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20140320/9ea696ce/attachment.html>


More information about the rabbitmq-discuss mailing list