tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thorsten Möller <ThorstenMoel...@web.de>
Subject Re: HttpSessionListener
Date Tue, 30 Sep 2003 14:11:21 GMT
Jon Wingfield <jon.wingfield@mkodo.com> wrote:
> In servlet spec version 2.4 (proposed final draft 3) the javadoc
> comments for sessionDestroyed are now:
>
> "Notification that a session is about to be invalidated."
>
> Tomcat 4.x.x implements the former spec, Tomcat 5 will implement the
> 2.4 spec.
In the meantime I tested this on Tomcat 5.0.9. But it seems that Tomcat
calls the method after it has invalidated the session. I get an exception:

14:51:34,893 INFO [ManagerBase] Session event listener threw exception
java.lang.IllegalStateException: getAttribute: Session already invalidated
at
org.apache.catalina.session.StandardSession.getAttribute(StandardSession.jav
a:982)
at
org.apache.catalina.session.StandardSessionFacade.getAttribute(StandardSessi
onFacade.java:166)
at
de.jexam.web.servlet.WebUserSessionLoginManager.sessionDestroyed(WebUserSess
ionLoginManager.java:99)
at
org.apache.catalina.session.StandardSession.expire(StandardSession.java:683)
at
org.apache.catalina.session.StandardSession.expire(StandardSession.java:641)
at
org.apache.catalina.session.StandardManager.processExpires(StandardManager.j
ava:819)
at
org.apache.catalina.core.StandardContext.backgroundProcess(StandardContext.j
ava:4363)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processC
hildren(ContainerBase.java:1660)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processC
hildren(ContainerBase.java:1669)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processC
hildren(ContainerBase.java:1669)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(Cont
ainerBase.java:1649)
at java.lang.Thread.run(Thread.java:536)


If I interpret the Servlet 2.4 draft specification right than Tomcat shows a
wrong behaviour. Maybe it's time to open a bug?



Thorsten


Mime
View raw message