I studied that sessionDestroyed method will be fired when a session is about to invalidate .
To understand this created a program in which I set a session's maximum inactive time as five seconds using setMaxInactiveInterval method of HttpSession
as
and I expect sessionDestroyed method will be invoked before that seconds(5 seconds) which I set using setMaxInactiveInterval method but it did not .
sessionDestroyed method invoked after a minute .
Why is it so ? .I'm using Tomcat 5.5.27 (servlet 2.4 version)
Thanks in advance