Announcement Announcement Module
Collapse
No announcement yet.
distinguishing rejected message from expired message Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • distinguishing rejected message from expired message

    Hi ,

    When a consumer throws AmqpRejectAndDontRequeueException, message is reject and delivered to dead letter exchange,
    Similarly when the life of the message in queue becomes > x-message-ttl of a queue , messages are again sent to the dead letter exchange,
    In such cases how can a dead letter queue consumer distinguish these two condition, Does SI/Spring amqp sets some special header in case of AmqpRejectAndDontRequeueException? Or is there a hook/provision in SI/spring amqp to do such thing?

  • #2
    The consumer is not given any opportunity to modify the message, we just get to reject it (with requeue or not). I don't know if rabbit itself provides any mechanism to determine the reason for routing to the DLE/DLQ; I suggest you ask over there... https://lists.rabbitmq.com/cgi-bin/m...bbitmq-discuss

    Comment


    • #3
      thanks Gary,
      I figured it out. basically rabbit lets one identify the the cause for dead lettering,infact it give a detailed list of things happened with the 'declared dead' message. all these information are available as part of message headers.

      ferer section Dead-Lettered Messages in http://www.rabbitmq.com/extensions.html

      Comment

      Working...
      X