1 Reply Latest reply on Jan 21, 2005 11:33 AM by omartin

    "Can't handle clustering where session id is from URL. Will

    omartin

      The problem:
      Some users lose sessions when one of our server goess down. They are redirect to the second server but lose all their datas. We can see in our log several errors. The performance decrease dramaticaly when we start the second server.

      The environment
      2 jboss on differents servers in a cluster
      JBoss version: 3.2.6
      JDK Sun 1.4.1_01
      OS: Debian kernel 2.6.8
      jvm args: -Xms1024m -Xmx1024m -XX:MaxPermSize=128m

      The configuration
      using mod_jk1.2 with sticky session
      using tc5-cluster-service.xml from all configuration
      using cluster-service.xml from all configuration
      using cache-invalidation-service.xml from all configuration
      setting the jvmRoute in jbossweb-tomcat50.sar according to workers.properties.

      we have set in web.xml the tag

      <distributable/>


      the jboss.xml for our web app:
      <jboss-web>
      <context-root>/jmanager</context-root>
      <replication-config> <replication-trigger>SET_AND_NON_PRIMITIVE_GET</replication-trigger>
      <replication-granularity>attribute</replication-granularity>
      </replication-config>
      </jboss-web>



      We can see in the log file 4 types of errors which happend periodicaly:

      1st error:
      ERROR [org.jboss.web.tomcat.tc5.JvmRouteFilter] JvmRouteFilter.doFilter(): Can't handle clustering where session id is from URL. Will skip.

      this one seems the origin for the session lost.

      2nd error:
      ERROR [org.jboss.web.tomcat.tc5.session.JBossCacheManager] processSessionRepl: failed with exception: java.lang.RuntimeException: JBossCacheService: exception occurred in cache put after retry ...
      ERROR [org.jboss.web.tomcat.tc5.session.JBossCacheManager] processSessionRepl: failed with exception: java.lang.IllegalStateException: Transaction has terminated


      3rd error:
      ERROR [org.jboss.web.tomcat.tc5.session.JBossCacheManager] processSessionRepl: failed with exception: org.jboss.tm.JBossRollbackException: Unable to commit, tx=TransactionImpl:XidImpl [FormatId=257, GlobalId=2ndServer**//11034, BranchQual=] status=STATUS_NO_TRANSACTION; - nested throwable: (org.jboss.util.NestedRuntimeException: ; - nested throwable: (org.jboss.cache.lock.TimeoutException: rsp=sender=XXX.XXX.XXX.XXX*:34588, retval=null, received=false, suspected=true))


      4th error
      ERROR [org.jboss.web.tomcat.tc5.session.JBossCacheManager] processSessionRepl: failed with exception: org.jboss.tm.JBossRollbackException: Unable to commit, tx=TransactionImpl:XidImpl [FormatId=257, GlobalId=sausset//49434, BranchQual=] status=STATUS_NO_TRANSACTION; - nested throwable: (org.jboss.util.NestedRuntimeException: ; - nested throwable: (org.jboss.cache.lock.TimeoutException: rsp=sender=XXX.XXX.XXX.XXX*:34588, retval=null, received=false, suspected=false))
      ERROR [STDERR] org.jboss.tm.JBossRollbackException: Unable to commit, tx=TransactionImpl:XidImpl [FormatId=257, GlobalId=sausset//49434, BranchQual=] status=STATUS_NO_TRANSACTION; - nested throwable: (org.jboss.util.NestedRuntimeException: ; - nested throwable: (org.jboss.cache.lock.TimeoutException: rsp=sender=XXX.XXX.XXX.XXX*:34588, retval=null, received=false, suspected=false))
      ERROR [STDERR] at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:415)
      ERROR [STDERR] at org.jboss.tm.TxManager.commit(TxManager.java:142)
      ERROR [STDERR] at org.jboss.tm.usertx.client.ServerVMClientUserTransaction.commit(ServerVMClientUserTransaction.java:126)
      ERROR [STDERR] at org.jboss.web.tomcat.tc5.session.JBossCacheManager.processSessionRepl(JBossCacheManager.java:406)
      ERROR [STDERR] at org.jboss.web.tomcat.tc5.session.JBossCacheManager.storeSession(JBossCacheManager.java:214)
      ERROR [STDERR] at org.jboss.web.tomcat.tc5.session.InstantSnapshotManager.snapshot(InstantSnapshotManager.java:37)
      ERROR [STDERR] at org.jboss.web.tomcat.tc5.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:91)
      ERROR [STDERR] at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
      ERROR [STDERR] at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      ERROR [STDERR] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
      ERROR [STDERR] at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      ERROR [STDERR] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
      ERROR [STDERR] at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
      ERROR [STDERR] at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      ERROR [STDERR] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
      ERROR [STDERR] at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
      ERROR [STDERR] at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
      ERROR [STDERR] at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
      ERROR [STDERR] at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
      ERROR [STDERR] at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:300)
      ERROR [STDERR] at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:374)
      ERROR [STDERR] at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:743)
      ERROR [STDERR] at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:675)
      ERROR [STDERR] at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:866)
      ERROR [STDERR] at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
      ERROR [STDERR] at java.lang.Thread.run(Thread.java:536)
      ERROR [STDERR] Caused by: org.jboss.util.NestedRuntimeException: ; - nested throwable: (org.jboss.cache.lock.TimeoutException: rsp=sender=XXX.XXX.XXX.XXX*:34588, retval=null, received=false, suspected=false)
      ERROR [STDERR] at org.jboss.cache.interceptors.ReplicationInterceptor$SynchronizationHandler.beforeCompletion(ReplicationInterceptor.java:222)
      ERROR [STDERR] at org.jboss.cache.interceptors.OrderedSynchronizationHandler.beforeCompletion(OrderedSynchronizationHandler.java:71)
      ERROR [STDERR] at org.jboss.tm.TransactionImpl.doBeforeCompletion(TransactionImpl.java:1362)
      ERROR [STDERR] at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:347)
      ERROR [STDERR] ... 25 more
      ERROR [STDERR] Caused by: org.jboss.cache.lock.TimeoutException: rsp=sender=XXX.XXX.XXX.XXX*:34588, retval=null, received=false, suspected=false
      ERROR [STDERR] at org.jboss.cache.TreeCache.callRemoteMethods(TreeCache.java:2159)
      ERROR [STDERR] Caused by: org.jboss.cache.lock.TimeoutException: rsp=sender=XXX.XXX.XXX.XXX*:34588, retval=null, received=false, suspected=false
      ERROR [STDERR] at org.jboss.cache.TreeCache.callRemoteMethods(TreeCache.java:2159)
      ERROR [STDERR] at org.jboss.cache.TreeCache.callRemoteMethods(TreeCache.java:2181)
      ERROR [STDERR] at org.jboss.cache.interceptors.ReplicationInterceptor.runPreparePhase(ReplicationInterceptor.java:299)2005-01-20 ERROR [STDERR] at org.jboss.cache.interceptors.ReplicationInterceptor$SynchronizationHandler.beforeCompletion(ReplicationInterceptor.java:205)
      ERROR [STDERR] ... 28 more


      *XXX.XXX.XXX.XXX the other server ip.


      Can someone help me please?

        • 1. Re:
          omartin

          I look at the code and it seems that the session replication in jboss 3.2.6 doesn't support session passing by url. Cookies seems supported but i have lost sometimes my session storing in a cookie...

          If someone used session replications without problems, i be very gratefull if he explains what configuration was employed...

          any help will be very appreciate.

          HELP !!!!!! ;)