glassfish
  1. glassfish
  2. GLASSFISH-3796

Add support for AJP/mod_jk load balancing balancing

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 9.1peur1
    • Fix Version/s: 9.1peur1_dev
    • Component/s: web_container
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

    • Issuezilla Id:
      3,796
    • Status Whiteboard:
      Hide

      91ur1Approved

      Show
      91ur1Approved

      Description

      The current appserv-webtier/src/java/org/apache/catalina/session/ManaferBase has
      the following commented:

      /*
      String jvmRoute = getJvmRoute();
      // @todo Move appending of jvmRoute generateSessionId()???
      if (jvmRoute != null)

      { sessionId += '.' + jvmRoute; }

      */
      /*
      synchronized (sessions) {
      while (sessions.get(sessionId) != null){ // Guarantee uniqueness
      duplicates++;
      sessionId = generateSessionId();
      // @todo Move appending of jvmRoute generateSessionId()???
      if (jvmRoute != null)

      { sessionId += '.' + jvmRoute; }

      }
      }
      */
      //end HERCULES:mod

      This prevent Apache + mod_jk to works properly. The above code must be
      uncommented out/executed when mod_jk is enabled (when property
      com.sun.enterprise.web.connetor.enableJK=true) More information can be found here:

      http://forums.java.net/jive/thread.jspa?messageID=241790

      Assign to Larry first.

        Activity

        Hide
        jluehe added a comment -

        Added unit test: /cvs/glassfish/appserv-tests/devtests/web/sessionJvmRoute

        Show
        jluehe added a comment - Added unit test: /cvs/glassfish/appserv-tests/devtests/web/sessionJvmRoute
        Hide
        jluehe added a comment -

        Incremental fix: When processing a request's session id, consider "." as a
        jvmRoute separator only if the jvmRoute mechanism has been enabled.

        Checking in CoyoteAdapter.java;
        /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/CoyoteAdapter.java,v
        <-- CoyoteAdapter.java
        new revision: 1.32.2.1.2.2; previous revision: 1.32.2.1.2.1
        done
        Checking in CoyoteRequest.java;
        /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/CoyoteRequest.java,v
        <-- CoyoteRequest.java
        new revision: 1.67.4.2; previous revision: 1.67.4.1
        done

        Show
        jluehe added a comment - Incremental fix: When processing a request's session id, consider "." as a jvmRoute separator only if the jvmRoute mechanism has been enabled. Checking in CoyoteAdapter.java; /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/CoyoteAdapter.java,v <-- CoyoteAdapter.java new revision: 1.32.2.1.2.2; previous revision: 1.32.2.1.2.1 done Checking in CoyoteRequest.java; /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/CoyoteRequest.java,v <-- CoyoteRequest.java new revision: 1.67.4.2; previous revision: 1.67.4.1 done
        Hide
        Joe Fialli added a comment -
            • Issue 3855 has been marked as a duplicate of this issue. ***
        Show
        Joe Fialli added a comment - Issue 3855 has been marked as a duplicate of this issue. ***
        Hide
        jluehe added a comment -

        Ported fix to SJSAS91_FCS_BRANCH:

        Checking in apache/catalina/core/StandardContext.java;
        /cvs/glassfish/appserv-webtier/src/java/org/apache/catalina/core/StandardContext.java,v
        <-- StandardContext.java
        new revision: 1.48.2.7; previous revision: 1.48.2.6
        done
        Checking in apache/catalina/session/ManagerBase.java;
        /cvs/glassfish/appserv-webtier/src/java/org/apache/catalina/session/ManagerBase.java,v
        <-- ManagerBase.java
        new revision: 1.23.2.2; previous revision: 1.23.2.1
        done
        Checking in apache/coyote/tomcat5/CoyoteAdapter.java;
        /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/CoyoteAdapter.java,v
        <-- CoyoteAdapter.java
        new revision: 1.32.2.4; previous revision: 1.32.2.3
        done
        Checking in apache/coyote/tomcat5/CoyoteRequest.java;
        /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/CoyoteRequest.java,v
        <-- CoyoteRequest.java
        new revision: 1.67.2.5; previous revision: 1.67.2.4
        done
        Checking in apache/coyote/tomcat5/CoyoteResponse.java;
        /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/CoyoteResponse.java,v
        <-- CoyoteResponse.java
        new revision: 1.22.6.2; previous revision: 1.22.6.1
        done
        Checking in apache/coyote/tomcat5/OutputBuffer.java;
        /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/OutputBuffer.java,v
        <-- OutputBuffer.java
        new revision: 1.16.6.2; previous revision: 1.16.6.1
        done
        Checking in WebContainer.java;
        /cvs/glassfish/appserv-core/src/java/com/sun/enterprise/web/WebContainer.java,v
        <-- WebContainer.java
        new revision: 1.100.2.7; previous revision: 1.100.2.6
        done

        Show
        jluehe added a comment - Ported fix to SJSAS91_FCS_BRANCH: Checking in apache/catalina/core/StandardContext.java; /cvs/glassfish/appserv-webtier/src/java/org/apache/catalina/core/StandardContext.java,v <-- StandardContext.java new revision: 1.48.2.7; previous revision: 1.48.2.6 done Checking in apache/catalina/session/ManagerBase.java; /cvs/glassfish/appserv-webtier/src/java/org/apache/catalina/session/ManagerBase.java,v <-- ManagerBase.java new revision: 1.23.2.2; previous revision: 1.23.2.1 done Checking in apache/coyote/tomcat5/CoyoteAdapter.java; /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/CoyoteAdapter.java,v <-- CoyoteAdapter.java new revision: 1.32.2.4; previous revision: 1.32.2.3 done Checking in apache/coyote/tomcat5/CoyoteRequest.java; /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/CoyoteRequest.java,v <-- CoyoteRequest.java new revision: 1.67.2.5; previous revision: 1.67.2.4 done Checking in apache/coyote/tomcat5/CoyoteResponse.java; /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/CoyoteResponse.java,v <-- CoyoteResponse.java new revision: 1.22.6.2; previous revision: 1.22.6.1 done Checking in apache/coyote/tomcat5/OutputBuffer.java; /cvs/glassfish/appserv-webtier/src/java/org/apache/coyote/tomcat5/OutputBuffer.java,v <-- OutputBuffer.java new revision: 1.16.6.2; previous revision: 1.16.6.1 done Checking in WebContainer.java; /cvs/glassfish/appserv-core/src/java/com/sun/enterprise/web/WebContainer.java,v <-- WebContainer.java new revision: 1.100.2.7; previous revision: 1.100.2.6 done
        Hide
        jluehe added a comment -

        Ported fix to V3:

        Sending web/webtier/src/main/java/com/sun/enterprise/web/WebContainer.java
        Sending
        web/webtier/src/main/java/org/apache/catalina/core/StandardContext.java
        Sending
        web/webtier/src/main/java/org/apache/catalina/session/ManagerBase.java
        Sending
        web/webtier/src/main/java/org/apache/coyote/tomcat5/CoyoteAdapter.java
        Sending
        web/webtier/src/main/java/org/apache/coyote/tomcat5/CoyoteRequest.java
        Sending
        web/webtier/src/main/java/org/apache/coyote/tomcat5/CoyoteResponse.java
        Sending web/webtier/src/main/java/org/apache/coyote/tomcat5/OutputBuffer.java
        Transmitting file data .......
        Committed revision 20372.

        Show
        jluehe added a comment - Ported fix to V3: Sending web/webtier/src/main/java/com/sun/enterprise/web/WebContainer.java Sending web/webtier/src/main/java/org/apache/catalina/core/StandardContext.java Sending web/webtier/src/main/java/org/apache/catalina/session/ManagerBase.java Sending web/webtier/src/main/java/org/apache/coyote/tomcat5/CoyoteAdapter.java Sending web/webtier/src/main/java/org/apache/coyote/tomcat5/CoyoteRequest.java Sending web/webtier/src/main/java/org/apache/coyote/tomcat5/CoyoteResponse.java Sending web/webtier/src/main/java/org/apache/coyote/tomcat5/OutputBuffer.java Transmitting file data ....... Committed revision 20372.

          People

          • Assignee:
            jluehe
            Reporter:
            jfarcand
          • Votes:
            2 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: