ICEfaces
  1. ICEfaces
  2. ICE-5053

Mutating session ids in WebLogic cluster lead to small memory leak in SessionDispatcher

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.8.2-EE-Beta
    • Fix Version/s: 1.8.2-EE-GA, 1.8.3
    • Component/s: Framework
    • Labels:
      None
    • Environment:
      WebLogic cluster
    • Affects:
      Documentation (User Guide, Ref. Guide, etc.)

      Description

      In a WebLogic cluster, the HttpSession.getId() call returns a string that not only includes the session ID but also what WebLogic refers to as JVMIDs. These values indicate which nodes in the cluster are the active and which one is preferred. For example, getId() might return a value that looks like this:

      xdp5KfxT0VhR8WJJFcphQZCTQ1GdlH6T5g392NVlpdZm1qvdTVPT!-2015310958!-1301377968!1256157555082

      The entire string is made up of the actual session id PLUS a couple of unique identifiers (delimited by '!') for cluster nodes (the final value is something else). The JVMIDs are used by the WebLogic plugin (at least) for routing requests. If you shut a cluster node down, the getId() call will return something like this - the node that is down is now indicated as 'NONE':

      xdp5KfxT0VhR8WJJFcphQZCTQ1GdlH6T5g392NVlpdZm1qvdTVPT!-1301377968!NONE!1256157555082

      Starting the node back up shows that a new JVMID is used to indicate the recently restarted node:

      xdp5KfxT0VhR8WJJFcphQZCTQ1GdlH6T5g392NVlpdZm1qvdTVPT!-1301377968!1294882958!1256157555082

      Our SessionDispatcher relies on the session ID as a key to store information in a couple of different collections. The result is that, when the session ID mutates as nodes go up and down, the values that are mapped to the session ID keys can get orphaned. The SessionDispatcher will simply add a new entry to the map, keyed on the the new sessionID. So far I haven't seen and detrimental behaviour (the proper session always appear to be used) but the orphaned values in the map may never be properly garbage collected even when the session expires because the same session ID may never be provided by the container.

      My question is, is this mutating session ID going to cause problems for anything in the core (like the Session Dispatcher) or the EPS?

        Issue Links

          Activity

          Repository Revision Date User Message
          ICEsoft Public SVN Repository #19837 Tue Dec 01 07:49:27 MST 2009 jack.van.ooststroom Fixed JIRA ICE-5053 : Mutating session ids in WebLogic cluster lead to small memory leak in SessionDispatcher
          Files Changed
          Commit graph MODIFY /icefaces/trunk/icefaces/core/src/com/icesoft/faces/webapp/http/servlet/SessionDispatcher.java
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #19833 Tue Dec 01 03:54:46 MST 2009 jack.van.ooststroom Fixed JIRA ICE-5053 : Mutating session ids in WebLogic cluster lead to small memory leak in SessionDispatcher
          Files Changed
          Commit graph MODIFY /icefaces/trunk/icefaces/core/src/com/icesoft/faces/webapp/http/servlet/MainServlet.java
          Commit graph MODIFY /icefaces/trunk/icefaces/core/src/com/icesoft/faces/webapp/http/servlet/SessionDispatcher.java
          Commit graph MODIFY /icefaces/trunk/icefaces/push-server/src/org/icefaces/push/server/PushServlet.java

            People

            • Assignee:
              Unassigned
              Reporter:
              Deryk Sinotte
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: