Dead-letterred messages not getting requeue to original queue after ttl

前端 未结 2 469
攒了一身酷
攒了一身酷 2020-12-20 06:30

I have planned to delay the processing of messages in queue by following these two links link1 link2. So, as suggested in the link. I have declared the original queue with t

相关标签:
2条回答
  • 2020-12-20 06:46

    Suppose your original exchange is x.notification and is bind to the queue q.A with routing queue A. And your dead-letter-exchange namae is dlx.notification. Now in the queue q.A set ttl the time interval you want to wait and dead-lleter-exchange as dlx.notification. Now create another queue dlq.A to route the expired message from dlx.notification into dlq.A with routing key "A". I think thats all you need to do to achive your goal.

    0 讨论(0)
  • 2020-12-20 07:01

    When a queue has a TTL setup that means that messages in that queue will be sent to the dead-letter-exchange (DLX) associated with that queue after the TTL has expired. If the queue has no DLX assigned then the messages go into the bit bucket.

    If you want to send messages back into the queue from which they came to be re-processed then you need to have the setup that I described in this post.

    Dead-lettering dead-lettered messages in RabbitMQ

    Hopefully that is helpful for you.

    0 讨论(0)
提交回复
热议问题