tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chris Wilson" <ch...@wondergeek.com>
Subject RE: session.getMaxInactiveInterval()
Date Wed, 22 May 2002 16:07:42 GMT
Mike,

I'm using Tomcat 4.0.3.  As far as I know, it's supposed to be Servlet
2.3 compliant.


Chris Wilson

chris@wondergeek.com
www.wondergeek.com

> -----Original Message-----
> From: Mike McGuinness [mailto:mmcguinn@lssi.net]
> Sent: Wednesday, May 22, 2002 10:37 AM
> To: Tomcat Users List
> Subject: Re: session.getMaxInactiveInterval()
> 
> Chris,
> 
> Simple question, are you sure you're using a servlet 2.3 compliant
> implementation?
> 
> Mike
> 
>  On Tue, 2002-05-21 at 11:00, Chris Wilson wrote:
> 
>     Hello,
> 
>     I'm calling session.getMaxInactiveInterval() on a session after it
has
>     been invalidated.
> 
>     Tomcat is throwing an IllegalStateException and saying that method
>     cannot be called on an invalid session.  However, the Servlet 2.3
API
>     docs do not state that IllegalStateException should be thrown (as
it
> is
>     with many other methods in HttpSession) from
getMaxInactiveInterval().
> 
>     The reason I've run into this problem is because I'm trying to
write a
>     HttpSessionAttributeListener that determines if the session is
being
>     explicitly invalidated or if it timed out.
> 
>     The Servlet 2.3 spec (section 10.7) states,
> 
>     "It is often useful in tracking sessions to know whether a session
>     became invalid because the container timed out the session, or
because
> a
>     web component within the application called the invalidate method.
The
>     destinction may be determined indirectly using listeners and the
>     HTTPSession API methods."
> 
>     If I can't call getMaxInactiveInterval() on an invalidated
session,
> how
>     can I determine if the session was invalidated due to time out?
Is
> this
>     a bug in Tomcat?  It seems so since it doesn't follow the API docs
for
>     this call.
> 
>     Thanks in advance for any insight.
> 
>     Chris Wilson
> 
>     Web Developer
>     Andrews University
>     cwilson@andrews.edu
> 
> 
>     --
>     To unsubscribe, e-mail:   <mailto:tomcat-user-
> unsubscribe@jakarta.apache.org>
>     For additional commands, e-mail: <mailto:tomcat-user-
> help@jakarta.apache.org>
> 


--
To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-user-help@jakarta.apache.org>


Mime
View raw message