Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1079309

Summary: Camel JPA binding and global transaction rollback logs 'no transaction is in progress' warning
Product: [JBoss] JBoss Fuse Service Works 6 Reporter: Václav Chalupa <vchalupa>
Component: SwitchYardAssignee: Rob Cernich <rcernich>
Status: CLOSED UPSTREAM QA Contact: Matej Melko <mmelko>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.0.0 GACC: mvecera, oskutka, soa-p-jira
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2025-02-10 03:35:25 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
simple reproducer none

Description Václav Chalupa 2014-03-21 12:11:02 UTC
Created attachment 877236 [details]
simple reproducer

Combination of Camel JPA inbound binding (service) with Drools component implementation logs 'failed polling endpoint - Will try again at next poll. Caused by: [org.springframework.dao.InvalidDataAccessApiUsageException - no transaction is in progress ' for every propagated transaction rollback.
Final transaction processing is correct.


The warning occurs for this combination, there is no such warning for bean/camel (xml,java) component implementation.


Simple reproducer attached.


11:49:21,468 WARN  [org.apache.camel.component.jpa.JpaConsumer] (Camel (camel-13) thread #31 - jpa://org.jboss.soa.qa.jpadroolsrollback.domain.InEntity) Consumer Consumer[jpa://org.jboss.soa.qa.jpadroolsrollback.domain.InEntity?consumeDelete=true&consumeLockEntity=false&consumer.transacted=true&delay=1000&initialDelay=1000&persistenceUnit=pu&transactionManager=%23jtaTransactionManager] failed polling endpoint: Endpoint[jpa://org.jboss.soa.qa.jpadroolsrollback.domain.InEntity?consumeDelete=true&consumeLockEntity=false&consumer.transacted=true&delay=1000&initialDelay=1000&persistenceUnit=pu&transactionManager=%23jtaTransactionManager]. Will try again at next poll. Caused by: [org.springframework.dao.InvalidDataAccessApiUsageException - no transaction is in progress; nested exception is javax.persistence.TransactionRequiredException: no transaction is in progress]: org.springframework.dao.InvalidDataAccessApiUsageException: no transaction is in progress; nested exception is javax.persistence.TransactionRequiredException: no transaction is in progress
	at org.springframework.orm.jpa.EntityManagerFactoryUtils.convertJpaAccessExceptionIfPossible(EntityManagerFactoryUtils.java:316)
	at org.springframework.orm.jpa.DefaultJpaDialect.translateExceptionIfPossible(DefaultJpaDialect.java:120)
	at org.springframework.dao.support.DataAccessUtils.translateIfNecessary(DataAccessUtils.java:213)
	at org.springframework.orm.jpa.JpaAccessor.translateIfNecessary(JpaAccessor.java:152)
	at org.springframework.orm.jpa.JpaTemplate.execute(JpaTemplate.java:188)
	at org.springframework.orm.jpa.JpaTemplate.execute(JpaTemplate.java:146)
	at org.apache.camel.component.jpa.JpaTemplateTransactionStrategy$1.doInTransaction(JpaTemplateTransactionStrategy.java:80) [camel-jpa-2.10.0.redhat-60024.jar:2.10.0.redhat-60024]
	at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:130)
	at org.apache.camel.component.jpa.JpaTemplateTransactionStrategy.execute(JpaTemplateTransactionStrategy.java:78) [camel-jpa-2.10.0.redhat-60024.jar:2.10.0.redhat-60024]
	at org.apache.camel.component.jpa.JpaConsumer.poll(JpaConsumer.java:75) [camel-jpa-2.10.0.redhat-60024.jar:2.10.0.redhat-60024]
	at org.apache.camel.impl.ScheduledPollConsumer.doRun(ScheduledPollConsumer.java:142) [camel-core-2.10.0.redhat-60024.jar:2.10.0.redhat-60024]
	at org.apache.camel.impl.ScheduledPollConsumer.run(ScheduledPollConsumer.java:92) [camel-core-2.10.0.redhat-60024.jar:2.10.0.redhat-60024]
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) [rt.jar:1.7.0_51]
	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304) [rt.jar:1.7.0_51]
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178) [rt.jar:1.7.0_51]
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [rt.jar:1.7.0_51]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_51]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_51]
	at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_51]
Caused by: javax.persistence.TransactionRequiredException: no transaction is in progress
	at org.hibernate.ejb.AbstractEntityManagerImpl.flush(AbstractEntityManagerImpl.java:993) [hibernate-entitymanager-4.2.0.SP1-redhat-1.jar:4.2.0.SP1-redhat-1]
	at sun.reflect.GeneratedMethodAccessor153.invoke(Unknown Source) [:1.7.0_51]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0_51]
	at java.lang.reflect.Method.invoke(Method.java:606) [rt.jar:1.7.0_51]
	at org.springframework.orm.jpa.JpaTemplate$CloseSuppressingInvocationHandler.invoke(JpaTemplate.java:425)
	at com.sun.proxy.$Proxy317.flush(Unknown Source)
	at org.apache.camel.component.jpa.JpaConsumer$1.doInJpa(JpaConsumer.java:117) [camel-jpa-2.10.0.redhat-60024.jar:2.10.0.redhat-60024]
	at org.apache.camel.component.jpa.JpaTemplateTransactionStrategy$1$1.doInJpa(JpaTemplateTransactionStrategy.java:82) [camel-jpa-2.10.0.redhat-60024.jar:2.10.0.redhat-60024]
	at org.springframework.orm.jpa.JpaTemplate.execute(JpaTemplate.java:183)
	... 14 more

Comment 1 Václav Chalupa 2014-03-21 12:54:32 UTC
Correction: the error occurs for all component implementation.

Comment 9 Red Hat Bugzilla 2025-02-10 03:35:25 UTC
This product has been discontinued or is no longer tracked in Red Hat Bugzilla.