Spring Boot 1.3.5 : No local transaction to join

382 views
Skip to first unread message

tesc...@ippon.fr

unread,
Jul 6, 2016, 9:16:30 AM7/6/16
to jBPM Setup
These are my two projects (atomikos and bitronix). I'd be glad if someone could criticize them, as they both fail...

Atomikox failure (no User Transaction, found no way to aim on JNDI as for Bitronix; might not be the pb, that said) :
java.lang.RuntimeException: Could not commit session or rollback
at org.jbpm.shared.services.impl.TransactionalCommandService.rollbackTransaction(TransactionalCommandService.java:92) ~[jbpm-shared-services-6.4.0.Final.jar:6.4.0.Final]
at org.jbpm.shared.services.impl.TransactionalCommandService.execute(TransactionalCommandService.java:77) ~[jbpm-shared-services-6.4.0.Final.jar:6.4.0.Final]
at org.jbpm.kie.services.impl.store.DeploymentStore.getEnabledDeploymentUnits(DeploymentStore.java:69) ~[jbpm-kie-services-6.4.0.Final.jar:6.4.0.Final]
at org.jbpm.kie.services.impl.store.DeploymentSynchronizer.synchronize(DeploymentSynchronizer.java:83) ~[jbpm-kie-services-6.4.0.Final.jar:6.4.0.Final]
at org.jbpm.kie.services.impl.store.DeploymentSyncInvoker$TriggerDeploymentSync.run(DeploymentSyncInvoker.java:81) [jbpm-kie-services-6.4.0.Final.jar:6.4.0.Final]
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [na:1.8.0_92]
at java.util.concurrent.FutureTask.runAndReset(Unknown Source) [na:1.8.0_92]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(Unknown Source) [na:1.8.0_92]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source) [na:1.8.0_92]
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [na:1.8.0_92]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [na:1.8.0_92]
at java.lang.Thread.run(Unknown Source) [na:1.8.0_92]
Caused by: java.lang.RuntimeException: Unable to rollback transaction
at org.drools.persistence.jta.JtaTransactionManager.rollback(JtaTransactionManager.java:259) ~[drools-persistence-jpa-6.4.0.Final.jar:6.4.0.Final]
at org.jbpm.shared.services.impl.TransactionalCommandService.rollbackTransaction(TransactionalCommandService.java:89) ~[jbpm-shared-services-6.4.0.Final.jar:6.4.0.Final]
... 11 common frames omitted
Caused by: java.lang.NullPointerException: null
at org.drools.persistence.jta.JtaTransactionManager.rollback(JtaTransactionManager.java:255) ~[drools-persistence-jpa-6.4.0.Final.jar:6.4.0.Final]
... 12 common frames omitted



Bitronix failure :
javax.persistence.TransactionRequiredException: No local transaction to join
at org.springframework.orm.jpa.ExtendedEntityManagerCreator$ExtendedEntityManagerInvocationHandler.doJoinTransaction(ExtendedEntityManagerCreator.java:385) ~[spring-orm-4.2.6.RELEASE.jar:4.2.6.RELEASE]
at org.springframework.orm.jpa.ExtendedEntityManagerCreator$ExtendedEntityManagerInvocationHandler.invoke(ExtendedEntityManagerCreator.java:327) ~[spring-orm-4.2.6.RELEASE.jar:4.2.6.RELEASE]
at com.sun.proxy.$Proxy106.joinTransaction(Unknown Source) ~[na:na]
at org.jbpm.shared.services.impl.JpaPersistenceContext.joinTransaction(JpaPersistenceContext.java:206) ~[jbpm-shared-services-6.4.0.Final.jar:6.4.0.Final]
at org.jbpm.shared.services.impl.TransactionalCommandService.execute(TransactionalCommandService.java:70) ~[jbpm-shared-services-6.4.0.Final.jar:6.4.0.Final]
at org.jbpm.kie.services.impl.store.DeploymentStore.getEnabledDeploymentUnits(DeploymentStore.java:69) ~[jbpm-kie-services-6.4.0.Final.jar:6.4.0.Final]
at org.jbpm.kie.services.impl.store.DeploymentSynchronizer.synchronize(DeploymentSynchronizer.java:83) ~[jbpm-kie-services-6.4.0.Final.jar:6.4.0.Final]
at org.jbpm.kie.services.impl.store.DeploymentSyncInvoker$TriggerDeploymentSync.run(DeploymentSyncInvoker.java:81) [jbpm-kie-services-6.4.0.Final.jar:6.4.0.Final]
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [na:1.8.0_92]
at java.util.concurrent.FutureTask.runAndReset(Unknown Source) [na:1.8.0_92]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(Unknown Source) [na:1.8.0_92]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source) [na:1.8.0_92]
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [na:1.8.0_92]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [na:1.8.0_92]
at java.lang.Thread.run(Unknown Source) [na:1.8.0_92]



My goal is to migrate on an all JavaConfig style. Thx in advance for having a look. T.
spring-boot-sample-jta-atomikos.zip
spring-boot-sample-jta-bitronix.zip

tesc...@ippon.fr

unread,
Jul 19, 2016, 11:57:17 AM7/19/16
to jBPM Setup
UP! How can I, instead, NOT use a JTA with jBPM ?

Maciej Swiderski

unread,
Jul 21, 2016, 9:00:19 AM7/21/16
to tesc...@ippon.fr, jBPM Setup
I tried to run the bitronix sample but it failed to start saying there are cyclic dependencies.

Anyway I looked at it and noticed you use hibernate auto configuration which last time I looked at it was causing bunch of issue thus it was disabled in the part I used https://github.com/mswiderski/jbpm-examples/commit/12130b4251ac3f25a9db20a9aea9476cf0d1a350

so you might want to look at that without hibenrate auto configuration …
Maciej
-- 
You received this message because you are subscribed to the Google Groups "jBPM Setup" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jbpm-setup+...@googlegroups.com.
To post to this group, send email to jbpm-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jbpm-setup/f4a884ad-69cc-4cb3-abcd-cb4eab4e104c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

tesc...@ippon.fr

unread,
Jul 26, 2016, 4:42:59 AM7/26/16
to jBPM Setup, tesc...@ippon.fr
Thank you, but those lines don't have any effect :

@Configuration
@EnableAutoConfiguration(exclude = HibernateJpaAutoConfiguration.class)
@EntityScan(basePackages = { "org.jbpm", "org.drools.persistence.info" })
public class HibernateConfig extends HibernateJpaAutoConfiguration {

Maciej Swiderski

unread,
Jul 26, 2016, 2:03:47 PM7/26/16
to tesc...@ippon.fr, jBPM Setup
I don’t think it could have any effect as you disabling annotation but the class extends that class anyway… so I would say you need to remove that hibernateJpaAutoConfiguration. Once you have this working you can look into details of the auto jpa config….

Maciej
Reply all
Reply to author
Forward
0 new messages