tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ben Walding <...@walding.com>
Subject Re: How to keep track of sessions
Date Wed, 14 Aug 2002 12:58:31 GMT
You could use an application context listener to write out the sessions 
when the context is shutdown and reread them when it starts up.

I tried to work out how the manager application (part of  the 
distribution) worked (as it knows about sessions), but gave up as it 
looked like to much work and too much poking about inside tomcat.

for my tastes (which didn't include
Mark O'Driscoll wrote:

>I am trying to keep track of the current sessions that are active in my web
>application.
>
>I have a HttpSessionListener that is correctly called on
>sessionCreated/sessionDeleted. I keep a reference to each session in the
>servletContext as a Vector.
>
>If tomcat is restarted then the sessions are persisted fine. However my
>vector of sessions is lost so I have no record of sessions that were created
>during a previous tomcat run.
>
>Any idea how I could find or keep the list of previously created sessions?
>
>Is there any way I can find a list of the current sessions without keeping a
>list (that would be my preference)
>
>TIA
>
>- Mark
>
>
>--
>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