Hi ,
I can now re-create the stack overflow problem with the two attached
servlets. The problem only occurs when you put something into the session
(in my case I'm using the deprecated getValue, putValue for compatibility
with Websphere etc but I *have* tried it with getAttribute / setAttribute
and it still falls over).
Fire up Servlet SESSIONTEST2 gets a session looks for value sessionValidated
, if it doesn't find it hands control to SESSIONTEST which creates a
sessionValidated object with a value "Yes it is" , sets the
sessionMaxInactive to 10 seconds and returns control to SESSIONTEST2 . If
you wait approx 30seconds and press refresh on SESSIONTEST2 you get a stack
overflow. switch back to tomcat 31 and it disappears.
regards
Richard
-----Original Message-----
From: Richard Downey [mailto:[EMAIL PROTECTED]]
Sent: 12 February 2001 10:47
To: [EMAIL PROTECTED]
Subject: RE: req.getSession(true) problems with 3.2.1
Hi ,
Thanks for the info on the random number generator that explains the delay
on first loading a session it does indeed only happen on the first session
of a tomcat run.
I am cutting down some code to get a mini test of this problem and will post
it shortly. Will also try re.getSession() .
thanks
Richard
-----Original Message-----
From: Kief Morris [mailto:[EMAIL PROTECTED]]
Sent: 12 February 2001 10:14
To: [EMAIL PROTECTED]
Subject: Re: req.getSession(true) problems with 3.2.1
Richard Downey typed the following on 09:45 AM 2/12/2001 +0000
>I am moving working applications from 3.1.1 to 3.2.1 and after getting over
>the strictly enforced case rules everything seemed to be OK , however I've
>noticed that whenever a session expires using HttpSession session =
>req.getSession(true); seems to trigger a loop leading to a stack overflow.
>This can be replicated and the problem disappears when I switch back to
>3.1.1 .
Can you give us a very simple test case so we can replicate this? Does
the same thing happen with req.getSession()?
>I have also observed that the initial getSession is slower than under 3.1.1
>(5 seconds 3.2.1 versus a time in milliseconds for 3.1.1) I've checked that
>it wasn't some kind of cookie conflict between 3.1.1 and 3.2.1 by getting
>rid of the cookies. Any ideas would be gratefully received.
This is due to the random number generator being initialized, it should only
happen the first time a session is gotten after the server is re-started.
Kief
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]
SESSIONTEST.java
SESSIONTEST2.java
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]