2 Replies Latest reply on Jul 23, 2002 12:10 PM by dcartier

    Distributed HTTPSessions and IP Migration/Failover

    dcartier

      Hello,
      I have been struggling with trying to have an HTTP session to fail over to a different JBoss host *without* a new session being created instead of the old one being reused.

      I think I have setup the DistributedHTTPsession's correctly (I am using the ALL config, with the jbossha-httpsession.sar added to deploy).

      To perform the IP failover and load balancing, I am using Wackamole running on spread. The IP's are migrating properly.

      The problem is that after an IP is migrated/load balanced to a new JBoss host, the session is always created from scratch, even when using a fresh session that was just used moments before.

      Where am I going wrong? Do I have to mark my war file distributable in order for the HTTP sessions to be distributed? If so where?

      Thanks for any insight anyone can provide

      Dennis

        • 1. Re: Distributed HTTPSessions and IP Migration/Failover
          dcartier

          Oops sorry forgot to mention ...

          I am using JBoss 3.0.1RC1.

          I am determining the session reuse by showing the session.getId() value. I have made the assumption that a different Id = different session.

          Dennis

          • 2. Re: Distributed HTTPSessions and IP Migration/Failover
            dcartier

            Well no one else has answered this ... so I will answer it myself incase other people are struggling with it now or in the future. Put in the web.xml file right after the tag.

            Yes, you must mark the webapp distributable. Once you do this, you will get much longer sessionId.

            You should also set a snapshot interval so the sessions get distributed back to the returning member. You set this in the jbossweb.sar/META-INF/jboss-service.xml file.

            Make sure JBoss is booted and ready *Before* your IP load balancer starts redirecting requests back to the returning member.

            Dennis