Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-4167

DummyBaseTransactionManager doesn't clean up when rollback fails

    XMLWordPrintable

Details

    Description

      If the rollback fails, the thread local holding the current transaction is not cleared, and it becomes impossible to start a new transaction on the same thread.

      One way this can happen is when Infinispan registers as a XA transaction, but DummyTransactionManager is not configured to use XA Xids:

      12:47:57,169 ERROR (testng-ReplicationExceptionTest:) [DummyTransaction] ISPN000098: Exception while rollback
      java.lang.UnsupportedOperationException
      	at org.infinispan.transaction.tm.DummyNoXaXid.getBranchQualifier(DummyNoXaXid.java:30)
      	at org.infinispan.transaction.xa.recovery.SerializableXid.<init>(SerializableXid.java:37)
      	at org.infinispan.transaction.xa.TransactionXaAdapter.convertXid(TransactionXaAdapter.java:251)
      	at org.infinispan.transaction.xa.TransactionXaAdapter.rollback(TransactionXaAdapter.java:122)
      	at org.infinispan.transaction.tm.DummyTransaction.runRollback(DummyTransaction.java:281)
      	at org.infinispan.transaction.tm.DummyTransaction.rollback(DummyTransaction.java:88)
      	at org.infinispan.transaction.tm.DummyBaseTransactionManager.rollback(DummyBaseTransactionManager.java:104)
      	at org.infinispan.CacheImpl.tryRollback(CacheImpl.java:1442)
      	at org.infinispan.CacheImpl.executeCommandAndCommitIfNeeded(CacheImpl.java:1418)
      	at org.infinispan.CacheImpl.putInternal(CacheImpl.java:894)
      	at org.infinispan.CacheImpl.put(CacheImpl.java:886)
      	at org.infinispan.CacheImpl.put(CacheImpl.java:1461)
      	at org.infinispan.CacheImpl.put(CacheImpl.java:225)
      	at org.infinispan.tx.synchronisation.ReplicationExceptionTest.testSyncReplTimeout(ReplicationExceptionTest.java:54)
      

      Attachments

        Activity

          People

            pruivo@redhat.com Pedro Ruivo
            dberinde@redhat.com Dan Berindei
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: