Session timeout using setMaxInactiveInterval [message #834673] |
Mon, 02 April 2012 04:47  |
Eclipse User |
|
|
|
Hi,
We have the following implementation for session time out on Browser close :
1. Detect browser close events using the Polling mechanism (client side js to regularly send requests to the server).
2. Once these requests stop coming, invoke setMaxInactiveInterval on that session with small time interval (we have it set to 2 secs)
3. Added SessionStoreListener, overridden beforeDestroy to release the application created session objects.
Sometimes this doesn't work. The setmaxInactiveInterval is getting invoked on the right session but the code in beforeDestroy does not get executed.
Are there known scenarios where this might fail?
The application is hosted on Tomcat and one observation we made was that for the first few hours after server startup it works fine. Then it fails for one of the sessions and all subsequent requests for session close end up in this state.
Please suggest.
Regards,
Aman
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.24679 seconds