Re: Camel JPA + JTA Transaction (TomEE)

2016-08-05 Thread dimas
Tried that, doesn't work. CDI is starting CamelContext even with context.setAutoStartup(false). SEVERE - Failed to create Producer for endpoint: Endpoint[jpa://com.kaltire.mix.wosess.model.ScanEvent]. Reason: javax.persistence.PersistenceException: No persistence providers available for "camel"

Re: Camel JPA + JTA Transaction (TomEE)

2016-07-31 Thread dimas
I like this option (using Singleton start up). Going to try to set autoStartUp=false on CamelContext (produced by Camel CDI producer) and start it up from Singleton EJB next week (I'm on vacation till next Friday). Will update on results. Cheers, Dmitry -- View this message in context: http://

Re: Camel JPA + JTA Transaction (TomEE)

2016-07-30 Thread dimas
I looks like the CDI initialization is triggered by Camel JPA component. How to make Camel to initialize lazily? -- View this message in context: http://camel.465427.n5.nabble.com/Camel-JPA-JTA-Transaction-TomEE-tp5785642p5785707.html Sent from the Camel - Users mailing list archive at Nabble.

Re: Camel JPA + JTA Transaction (TomEE)

2016-07-29 Thread dimas
Is there anything else i need to do besides just reference it as @Resource? It's still 'null' -- View this message in context: http://camel.465427.n5.nabble.com/Camel-JPA-JTA-Transaction-TomEE-tp5785642p5785653.html Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Camel JPA + JTA Transaction (TomEE)

2016-07-29 Thread dimas
Antonin, yes, It helped a lot! I can see the transaction committed successfully and message persisted after I used your advice and injected transaction and manager like this: @Resource UserTransaction userTransaction; @Resource(lookup = "java:comp/env/TransactionManager") TransactionManager tran

Camel JPA + JTA Transaction (TomEE)

2016-07-29 Thread dimas
Hi All, I'm using TomEE (7.0.0) + Camel JMS + Camel CDI + Camel JPA to receive and store messages in the DB. Camel version is 2.17.2. Out of the box, Camel JPA is failing because it is trying to access the EntityTransaction of TomEE. 08:36| ERROR | CamelLogger.java 156 | org.apache.openjpa.pe

RE: camel-test-cdi + OpenEJB fails on weld dependency?

2016-06-01 Thread dimas
at java.lang.reflect.Constructor.newInstance(Constructor.java:422) > at > org.jboss.weld.util.ServiceLoader.prepareInstance(ServiceLoader.java:240) > ... 21 more > > Any idea how to resolve this one? Am I doing something totally wrong here? > > Dmitry > >

RE: camel-test-cdi + OpenEJB fails on weld dependency?

2016-06-01 Thread dimas
ava:45) > at java.lang.reflect.Constructor.newInstance(Constructor.java:422) > at > org.jboss.weld.util.ServiceLoader.prepareInstance(ServiceLoader.java:240) > ... 21 more > > Any idea how to resolve this one? Am I doing something totally wrong here? >

camel-test-cdi + OpenEJB fails on weld dependency?

2016-06-01 Thread dimas
Hi All, Here is my app environment: Camel-CDI 2.17.1, TomEE/openejb-core 7.0.0. I'm trying to test the app using camel-test-cdi and getting this exception: java.lang.RuntimeException: Error instantiating class org.apache.deltaspike.jsf.impl.scope.mapped.MappedJsf2ScopeExtension at org.jb