3 Replies Latest reply on Sep 13, 2013 8:57 AM by Paul Ferraro

    [JBOSS EAP6] session serialization in standalone.xml mode

    viragegroup Newbie

      Hi all,

      I'm testing clustering with jboss EAP 6.  

      I just set <distributable/> in my web.xml to test it in standalone-ha mode.

       

      But, when I deploy the web app in standalone mode (standalone.xml not HA), I notice the following exception:

      12:03:27,765 ERROR ajp-/0.0.0.0:8009-4(:) [org.infinispan.transaction.tm.DummyTransaction] - ISPN000111: afterCompletion() failed for SynchronizationAdapter{localTransaction=LocalTransaction{remoteLockedNodes=null, isMarkedForRollback=false, lockedKeys=null, backupKeyLocks=null, topologyId=-1, isFromStateTransfer=false} org.infinispan.transaction.synchronization.SyncLocalTransaction@20} org.infinispan.transaction.synchronization.SynchronizationAdapter@3f: org.infinispan.CacheException: Could not commit.

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

          at org.infinispan.transaction.tm.DummyTransaction.notifyAfterCompletion(DummyTransaction.java:285)

          at org.infinispan.transaction.tm.DummyTransaction.runCommitTx(DummyTransaction.java:334)

          at org.infinispan.transaction.tm.DummyTransaction.commit(DummyTransaction.java:91)

          at org.infinispan.transaction.tm.DummyBaseTransactionManager.commit(DummyBaseTransactionManager.java:102)

          at org.jboss.as.clustering.web.impl.TransactionBatchingManager.endBatch(TransactionBatchingManager.java:75)

          at org.jboss.as.web.session.DistributableSessionManager.processSessionRepl(DistributableSessionManager.java:1535)

          at org.jboss.as.web.session.DistributableSessionManager.storeSession(DistributableSessionManager.java:865)

          at org.jboss.as.web.session.InstantSnapshotManager.snapshot(InstantSnapshotManager.java:47)

          at org.jboss.as.web.session.ClusteredSessionValve.handleRequest(ClusteredSessionValve.java:142)

          at org.jboss.as.web.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:99)

          at org.jboss.as.web.session.JvmRouteValve.invoke(JvmRouteValve.java:92)

          at org.jboss.as.web.session.LockingValve.invoke(LockingValve.java:64)

          at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169)

          at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:145)

          at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97)

          at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102)

          at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:336)

          at org.apache.coyote.ajp.AjpProcessor.process(AjpProcessor.java:488)

          at org.apache.coyote.ajp.AjpProtocol$AjpConnectionHandler.process(AjpProtocol.java:420)

          at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:920)

          at java.lang.Thread.run(Unknown Source) [rt.jar:1.7.0_25]

      Caused by: javax.transaction.xa.XAException

          at org.infinispan.transaction.TransactionCoordinator.handleCommitFailure(TransactionCoordinator.java:224)

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

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

          ... 21 more

      It is due to a not serializable object.

      Ok, we have work to do.

       

      But, the question is, why in standalone mode, without any clustering configuration, Jboss try to serialize the session ?

      I saw, in standalone.xml file, the following :

              <cache-container name="web" aliases="standard-session-cache" default-cache="local-web" module="org.jboss.as.clustering.web.infinispan">
                  <local-cache name="local-web" batching="true">
                      <file-store passivation="false" purge="false"/>
                  </local-cache>
              </cache-container>

      What is the purpose of this configuration ?

      Is there a way to desactivate session serialization if we are in standalone mode (ie if we are using standalone.xml file, not cluster) ?

       

      Thanks for any comment.