Thanks, Bruce.  I'll give this a try.

On Tue, Apr 28, 2009 at 5:00 PM, Bruce Snyder <bruce.sny...@gmail.com>wrote:

> On Wed, Apr 29, 2009 at 12:15 AM, Roger Hoover <roger.hoo...@gmail.com>
> wrote:
> > Hi,
> >
> > Are queued messages supposed to be delivered in order?  I have a simple
> > STOMP Perl script below that shows messages delivered out of order.  I've
> > run it against AMQ 4.1.1 and 5.2.0 in with both persistent and
> > non-persistent messages.  Note from the message ids and timestamps that
> the
> > newer message is delivered first.
> >
> > Is there a way to force message delivery order? I don't think selectors
> > allow for ordering, right? Our application doesn't particularly depend on
> > message order but this behavior is causing my unit tests to fail every
> third
> > time they are run.  :(
> >
> > This also seems problematic for STOMP clients using "client" ack mode.
> > Since newer messages are delivered first, ack'ing the newer message will
> > implicitly ack the older message which has not even been delivered yet.
>
> Ordering of message dispatch doesn't take place by default but it's
> easy to achieve. You just need to configure it in the
> conf/activemq.xml file using the strict order dispatch policy AKA
> total ordering:
>
> http://activemq.apache.org/total-ordering.html
>
> Bruce
> --
> perl -e 'print
> unpack("u30","D0G)u8...@4vyy9&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
> );'
>
> ActiveMQ in Action: http://bit.ly/2je6cQ
> Blog: http://bruceblog.org/
> Twitter: http://twitter.com/brucesnyder
>

Reply via email to