0

Lets say my consumer acked and due to some strange reason did not handle the message well. Is there a technic to go over message again? Requirements :
1. same order.
2. continue receiving new messages and placing them last in the queue?

therefor, not re-queieng them (messing order), something like moving the index back (as in kafka )? Thanks.

Bick
  • 17,833
  • 52
  • 146
  • 251

1 Answers1

0

1 - Same order is something that is not compatible with async AMQP model.

In general RabbitMQ feed messages in order they was added, but if redelivery occurred that message will be delivered ASAP. Also, if one message was not acked among other it will be scheduled to client ASAP too.

2 - Dead lettering may help you.

Sure, you can manually add message back to exchange it was originally published to, but it is not what may be called best practice (ok, it works and pretty well in some cases). But you have to protect your application from cycled messages that fails and then delivered again (headres solve this problem for me, at least).

pinepain
  • 12,453
  • 3
  • 60
  • 65