It looks like the StandardSession class, in the 4.x line, uses two variables  
thisAccessedTime and lastAccessedTime to keep track of the sessions last 
accessed time.  The method access(), which is called in the StandardHostValue 
class every time a user makes a request, contains the following code:

    public void access() {
        this.isNew = false;
        this.lastAccessedTime = this.thisAccessedTime;
        this.thisAccessedTime = System.currentTimeMillis();
    }

The problem is that lastAccessedTime is used to determine if the session has 
expired.  So it takes two "clicks" by a user to keep their session active.  
The variable thisAccessedTime is private and not really used except in this 
method.  My question is why is this done?  Is there some reason why the 
thisAccessedTime variable is needed at all?  It seems like setting 
lastAccessedTime equal the System.currentTimeMillis() would work as expected  
and keep the session alive with only one "click".  I've made this change and 
it looks to work.

Thanks
- Michael Tildahl
Aplia Inc.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to