camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Claus Ibsen <>
Subject Re: Transaction spanning multiple routes separated by seda queue
Date Thu, 16 Jan 2014 14:14:16 GMT
On Thu, Jan 16, 2014 at 10:57 AM, gilboy <> wrote:
> Hi
> I have a route to consume a message from a JMS Topic, do some processing on
> it and then place on a SEDA Queue.
> My second route will consume the message from the SEDA queue and place on a
> different JMS Topic.
> I want to ensure that the message only gets de-queued from the first Topic
> which it has successfully been placed on the 2nd topic. Is this possible?

Well almost. If you use transacted jms, then the consumer on the jms
topic will not ack the msg until Camel has routed the message and
there was no error.

So when you send to the seda queue, then if you do request/reply then
it will block here waiting for the 2nd route to complete. And if that
completes without any exception, then it continue and the 1st consumer
can ack the message.

But if you involve other resources such as JDBC and want to use XA
then you would need that work to happen on the same thread (very often
that is).

If you have Camel in Action book, read chapter 9, and see section 9.3
about local vs global tx's.

> Thanks in advance
> Joe
> --
> View this message in context:
> Sent from the Camel - Users mailing list archive at

Claus Ibsen
Red Hat, Inc.
Twitter: davsclaus
Author of Camel in Action:
Make your Camel applications look hawt, try:

View raw message