Hibernate 3.3.0.SP1
Jboss Cache 2.1.1
Bitronix 1.3
When committing a transaction with bulk operations, I’m getting the following exception:
Code:
ERROR (ActionQueue.java:207) - could not release a cache lock
org.hibernate.cache.CacheException: org.jboss.cache.CacheException: Invalid transaction a Bitronix Transaction with GTRID [45494D2D544D0000011C88534779000CA100], status=COMMITTED, 1 resource(s) enlisted (started Mon Sep 22 00:31:11 EDT 2008), status = 3
at org.hibernate.cache.jbc2.util.CacheHelper.removeAll(CacheHelper.java:380)
at org.hibernate.cache.jbc2.util.CacheHelper.removeAll(CacheHelper.java:360)
at org.hibernate.cache.jbc2.access.TransactionalAccessDelegate.evictOrRemoveAll(TransactionalAccessDelegate.java:146)
at org.hibernate.cache.jbc2.access.TransactionalAccessDelegate.evictAll(TransactionalAccessDelegate.java:142)
at org.hibernate.cache.jbc2.entity.TransactionalAccess.evictAll(TransactionalAccess.java:102)
at org.hibernate.impl.SessionFactoryImpl.evictEntity(SessionFactoryImpl.java:870)
at org.hibernate.action.BulkOperationCleanupAction.evictEntityRegions(BulkOperationCleanupAction.java:153)
at org.hibernate.action.BulkOperationCleanupAction.afterTransactionCompletion(BulkOperationCleanupAction.java:132)
at org.hibernate.engine.ActionQueue.afterTransactionCompletion(ActionQueue.java:198)
at org.hibernate.impl.SessionImpl.afterTransactionCompletion(SessionImpl.java:451)
at org.hibernate.jdbc.JDBCContext.afterTransactionCompletion(JDBCContext.java:252)
at org.hibernate.transaction.CacheSynchronization.afterCompletion(CacheSynchronization.java:117)
at bitronix.tm.BitronixTransaction.fireAfterCompletionEvent(BitronixTransaction.java:382)
at bitronix.tm.BitronixTransaction.commit(BitronixTransaction.java:188)
at bitronix.tm.BitronixTransactionManager.commit(BitronixTransactionManager.java:96)
Caused by: org.jboss.cache.CacheException: Invalid transaction a Bitronix Transaction with GTRID [45494D2D544D0000011C88534779000CA100], status=COMMITTED, 1 resource(s) enlisted (started Mon Sep 22 00:31:11 EDT 2008), status = 3
at org.jboss.cache.interceptors.Interceptor.assertTransactionValid(Interceptor.java:208)
at org.jboss.cache.interceptors.PessimisticLockInterceptor.lock(PessimisticLockInterceptor.java:428)
at org.jboss.cache.interceptors.PessimisticLockInterceptor.acquireLocksWithTimeout(PessimisticLockInterceptor.java:399)
at org.jboss.cache.interceptors.PessimisticLockInterceptor.handleRemoveNodeMethod(PessimisticLockInterceptor.java:274)
at org.jboss.cache.interceptors.MethodDispacherInterceptor.invoke(MethodDispacherInterceptor.java:108)
at org.jboss.cache.interceptors.PessimisticLockInterceptor.invoke(PessimisticLockInterceptor.java:81)
at org.jboss.cache.interceptors.Interceptor.nextInterceptor(Interceptor.java:111)
at org.jboss.cache.interceptors.MethodDispacherInterceptor.invoke(MethodDispacherInterceptor.java:58)
at org.jboss.cache.interceptors.Interceptor.nextInterceptor(Interceptor.java:111)
at org.jboss.cache.interceptors.TxInterceptor.handleNonTxMethod(TxInterceptor.java:456)
at org.jboss.cache.interceptors.TxInterceptor.handleRemoveNodeMethod(TxInterceptor.java:215)
at org.jboss.cache.interceptors.MethodDispacherInterceptor.invoke(MethodDispacherInterceptor.java:108)
at org.jboss.cache.interceptors.Interceptor.nextInterceptor(Interceptor.java:111)
at org.jboss.cache.interceptors.MethodDispacherInterceptor.invoke(MethodDispacherInterceptor.java:58)
at org.jboss.cache.interceptors.Interceptor.nextInterceptor(Interceptor.java:111)
at org.jboss.cache.interceptors.InvocationContextInterceptor.invoke(InvocationContextInterceptor.java:73)
at org.jboss.cache.invocation.AbstractInvocationDelegate.invoke(AbstractInvocationDelegate.java:123)
at org.jboss.cache.invocation.AbstractInvocationDelegate.invoke(AbstractInvocationDelegate.java:64)
at org.jboss.cache.invocation.CacheInvocationDelegate.removeNode(CacheInvocationDelegate.java:420)
at org.hibernate.cache.jbc2.util.CacheHelper.removeAll(CacheHelper.java:378)
Looks like the COMMITTED status is not considered valid.
Any ideas on how it can be fixed?
Thank you.