On Fri, Jun 4, 2010 at 1:47 PM, Christian Schneider <ch...@die-schneider.net> wrote: > How about simply using two separate queues. This way you don“t have to care > about selectors. > > If the sender can not do this then you could still use a content based > router to route to two queues. Then at least the incoming queue will always > be emptied quite fast. > Of course then the gain will depend on how slow your processor is in > comparisson with the jms messaging. >
Yeah a good solution when you have control of the message broker and can create new queues for this purpose. It would be the best choice as the message can be transacted and persisted and you wont have issue if the server crashes (well of course a bit but not as big as having the message lost in the Camel resequencer) > Greetings > > Christian > > > Am 04.06.2010 13:20, schrieb Christian Mueller: >> >> Hello list, >> >> I have a requirement to process online (coming from an external web >> service) >> and batch (several thousand) messages. The online messages are more prior >> (the customer is waiting of the response) and should be processed before >> the >> batch messages (I think a common requirement). Because ActiveMQ at this >> time >> doesn't support message priority >> >> ([how-can-i-support-priority-queues|http://activemq.apache.org/how-can-i-support-priority-queues.html]), >> I was looking for another solution. I read this thread >> >> [Camel-and-jms-priority|http://old.nabble.com/Camel-and-jms-priority-ts25962858.html#a25962858] >> and found it to complicated - I'm lasy... :-) >> >> My question is, would this Camel route also do a good job for this >> requirements? >> >> {code} >> >> from("activemq://queue:inbox?concurrentConsumers=5&selector=priority<='4'") >> .to("direct:inbox"); >> >> from("activemq://queue:inbox?concurrentConsumers=5&selector=priority>'4'") >> .to("direct:inbox"); >> >> from("direct:inbox") >> .processRef("myProcessor") >> .to("activemq://queue:outbox"); >> {code} >> >> Thanks in advanced, >> Christian >> > > -- > ---- > http://www.liquid-reality.de > > -- Claus Ibsen Apache Camel Committer Author of Camel in Action: http://www.manning.com/ibsen/ Open Source Integration: http://fusesource.com Blog: http://davsclaus.blogspot.com/ Twitter: http://twitter.com/davsclaus