[rabbitmq-discuss] Strategy for consuming queues and ordering
Alfonso Pantoja
alfonso.pantoja at gmail.com
Thu Feb 10 09:44:14 GMT 2011
Hi,
Can anyone tell me how to deal with queues that contain messages that
are higly recommended by business logic to be ordered?
As far as I know when messages are not acked and a BasicRecover(true)
is done or the consumer is reconnected all these messages are requeued
so the order is lost.
The more suitable strategy I've found in queues where ordering is
important is to use one consumer that stops the consuming process
conditioned to the treatment of the message. In other words, it does
not consume any more message until the current message is, for
example, successfully stored in the database.
The drawback of this is that in case of a consumer is disconnected the
current message is not acked so it will be requeued so the order will
be lost.
Advice on this would be really appreciated :)
Thank you in advance.
Regards,
Alfonso
More information about the rabbitmq-discuss
mailing list