dcsimg
detect session timeout vs. explicit invalidate() call in servlet 2.2
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Robert_Cote
Posted On:   Friday, April 19, 2002 12:37 PM

I've provided a log-out for my users that makes an explicit call to session.invalidate().


If the session is invalidated due to a timeout, I'd like to store all available data, so when the user comes back, they can pick up where they left off.


The session contains some objects that implement HttpSessionBindingListener, and code in valueUnbound() attempts to store info to the db.


If the user logs out, this db update shouldn't happen. Using servlet 2.2, how can I tell if the session invalidation was the result of a timeout?

Re: detect session timeout vs. explicit invalidate() call in servlet 2.2

Posted By:   pradeep_kanwar  
Posted On:   Friday, April 19, 2002 04:04 PM

you are almost there !!!



specify an attribute like 'currentLoginState' and set it to 'loggedOut' if the user chose to log out and in the valueUnbound() check for this attribute and if ......... rest you know


PK
About | Sitemap | Contact