0 Replies Latest reply on May 15, 2014 11:57 AM by andrew_scully

    Infinispan tree cache on Glassfish.

    andrew_scully

      Hi,

       

      I'm running Infinispan 6.0.2.Final (JGroups 3.4.3.Final ) on Glassfish 4.

       

      At runtime, when creating a tree cache using new TreeCacheFactory().createTreeCache(cache), I get the following exception thrown (see bottom).

       

      This does not happen for our other caches (only this one is a tree cache, the others are the standard Map-style caches).

       

      Tree-cache requires TransactionMode.TRANSACTIONAL, so there is no hope of just turning off transactions for this one cache.

       

      We did not get this on the previous version we used (5.2.1.Final), so this has been introduced since.

       

      Having examined JavaEETransactionManagerSimplified (http://grepcode.com/file/repo1.maven.org/maven2/org.glassfish.transaction/jta/3.1.1/com/sun/enterprise/transaction/JavaE…) it appears that a bad transaction status (javax.transaction.Status.STATUS_ROLLEDBACK) is being given to the transaction layer.

       

      Is there something wrong with our configuration or some incompatibility with Glassfish's transaction implementation?

       

      Any help would be much appreciated.

       

      Cheers, Andy.

       

       

       

      2014-05-15 15:09:29,716 ERROR [org.infinispan.transaction.TransactionCoordinator] (518,EclipseGeminiBlueprintExtenderThread-89) ISPN000188: Error while processing a commit in a two-phase transaction

      org.infinispan.commons.CacheException: javax.transaction.InvalidTransactionException: Invalid transaction passed to resume() call.

          at org.infinispan.interceptors.InterceptorChain.invoke(InterceptorChain.java:341)

          at org.infinispan.transaction.TransactionCoordinator.commitInternal(TransactionCoordinator.java:212)

          at org.infinispan.transaction.TransactionCoordinator.commit(TransactionCoordinator.java:160)

          at org.infinispan.transaction.synchronization.SynchronizationAdapter.afterCompletion(SynchronizationAdapter.java:58)

          at com.sun.enterprise.transaction.JavaEETransactionImpl.commit(JavaEETransactionImpl.java:557)

          at com.sun.enterprise.transaction.JavaEETransactionManagerSimplified.commit(JavaEETransactionManagerSimplified.java:854)

          at com.sun.enterprise.transaction.TransactionManagerHelper.commit(TransactionManagerHelper.java:81)

          at org.infinispan.batch.BatchContainer.resolveTransaction(BatchContainer.java:101)

          at org.infinispan.batch.BatchContainer.endBatch(BatchContainer.java:83)

          at org.infinispan.batch.AutoBatchSupport.endAtomic(AutoBatchSupport.java:27)

          at org.infinispan.tree.TreeStructureSupport.createNodeInCache(TreeStructureSupport.java:63)

          at org.infinispan.tree.TreeStructureSupport.createNodeInCache(TreeStructureSupport.java:42)

          at org.infinispan.tree.TreeCacheImpl.createRoot(TreeCacheImpl.java:437)

          at org.infinispan.tree.TreeCacheImpl.<init>(TreeCacheImpl.java:32)

          at org.infinispan.tree.TreeCacheImpl.<init>(TreeCacheImpl.java:24)

          at org.infinispan.tree.TreeCacheFactory.createTreeCache(TreeCacheFactory.java:37)

       

      Caused by: javax.transaction.InvalidTransactionException: Invalid transaction passed to resume() call.

          at com.sun.enterprise.transaction.JavaEETransactionManagerSimplified.resume(JavaEETransactionManagerSimplified.java:999)

          at com.sun.enterprise.transaction.TransactionManagerHelper.resume(TransactionManagerHelper.java:96)

          at org.infinispan.interceptors.BatchingInterceptor.handleDefault(BatchingInterceptor.java:70)

          at org.infinispan.commands.AbstractVisitor.visitCommitCommand(AbstractVisitor.java:106)

          at org.infinispan.commands.tx.CommitCommand.acceptVisitor(CommitCommand.java:38)

          at org.infinispan.interceptors.InterceptorChain.invoke(InterceptorChain.java:333)

          ... 39 more