You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Ro...@t-systems.com on 2014/10/17 15:45:19 UTC

Documentation for JEE Transaction Handling in Camel needed

Hi,

our application run in JBoss EAP 6.1 and uses different camel routes to read data from external servers, converts and writes them via jms (hornetQ) into database. The MDB reads values from queue, store them in database and put in a second queue.
Sometimes an OptimisticLockException occurs in second MDB while trying to look up them in database.

Very simplified scenario:
from("ftp://server").to("direct:convert");
from("direct:convert").process(xyz).bean(myEJB).to("direct:save"); 
from("direct:save").process(abc).to("jms://savequeue");

My question is where can I find a description of how and when transactions are started and closed during a camel route using EJBs.

Regards Robin

Re: Documentation for JEE Transaction Handling in Camel needed

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

As you use MDB then its the app server that manages the transaction
and does the TX start | commit | rollback. So you should look at the
documentation of the app server how this works / jee spec etc.

On Fri, Oct 17, 2014 at 3:45 PM,  <Ro...@t-systems.com> wrote:
> Hi,
>
> our application run in JBoss EAP 6.1 and uses different camel routes to read data from external servers, converts and writes them via jms (hornetQ) into database. The MDB reads values from queue, store them in database and put in a second queue.
> Sometimes an OptimisticLockException occurs in second MDB while trying to look up them in database.
>
> Very simplified scenario:
> from("ftp://server").to("direct:convert");
> from("direct:convert").process(xyz).bean(myEJB).to("direct:save");
> from("direct:save").process(abc).to("jms://savequeue");
>
> My question is where can I find a description of how and when transactions are started and closed during a camel route using EJBs.
>
> Regards Robin



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
hawtio: http://hawt.io/
fabric8: http://fabric8.io/