Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
The moose likes Servlets and the fly likes Session Listener Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Session Listener" Watch "Session Listener" New topic
Author

Session Listener

Vels Manian
Greenhorn

Joined: Jun 28, 2001
Posts: 22
Hi,
I have a doubt in Session Listener. Will the sessionDestroyed method in the SessionListener called even if the session gets inactivated itself based on the session timeout set in the web server.
Thanks & Regards
Vels
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12682
    
    5
That is exactly what it means - when the server inactivates the session, that method is called.
For many purposes I like SessionBindingListener better - it is also called when the session is inactivated.
All this is detailed in the servlet API which you can download from java.sun.com.
Bill
[ August 14, 2002: Message edited by: William Brogden ]

Java Resources at www.wbrogden.com
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Session Listener
 
Similar Threads
executing code when session dies
Servlet listeners-HttpSessionListener and HttpSessionAttributeListener
Checking for valid session
Firefox window open on unload
getting the IP when the session is created