tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christopher K. St. John" <>
Subject PersistentManagerBase.processMaxActiveSwaps()
Date Wed, 19 Dec 2001 18:13:02 GMT

 I've been messing around with PersistentManager,
trying to get sessions to swap out based on maxActiveSessions.
There's a check in processMaxActiveSwaps():

        Session sessions[] = findSessions();
        // FIXME: Smarter algorithm (LRU)
        if (getMaxActiveSessions() >= sessions.length)

 And also one in createSession():

      if ((maxActiveSessions >= 0) &&
          (sessions.size() >= maxActiveSessions))
            throw new IllegalStateException

 I'm not seeing any way that the check in processMaxActiveSwaps()
could ever fail, since createSessions() will refuse to 
create more than maxActiveSession Sessions. Which would
mean that processMaxActiveSwaps() never gets any farther
than that check, and never swaps anything out.

Christopher St. John

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message