tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Thomas <ma...@apache.org>
Subject Re: how to programmatically expire inactive sessions?
Date Wed, 10 Oct 2012 18:35:53 GMT
On 10/10/2012 19:30, Kirill Kireyev wrote:
> Thanks Mark!
> 
> So currently ContainerBackgroundProcessor is sleeping:
> 0x5f31    0    27.4   
> "ContainerBackgroundProcessor[StandardEngine[Catalina]]" daemon prio=10
> tid=0x000000000306c800 nid=0x5f31 sleeping[0x00007fa2e9dcb000]
> 
> What should I be looking for in terms of that thread?

Look at it over time. Make sure it isn't deadlocked. That is the thread
that does session expiration. I have seen deadlocks stop session expiration.

The other check is to attach a debugger and put a break point in
org.apache.catalina.session.ManagerBase.backgroundProcess()

and then check what is going on.

Mark

> 
> -Kirill
> 
> 
> On 10/10/12 12:27 PM, Mark Thomas wrote:
>> On 10/10/2012 19:24, Kirill Kireyev wrote:
>>> Thanks Shanti!
>>>
>>> I think your hypothesis is that these sessions remain active, due to
>>> client-side polling. However, I don't think that's the case - these
>>> sessions are listed as *inactive* (or rather inactive for longer than 20
>>> mins) in the Tomcat manager web application. And hitting "Expire
>>> (sessions > 20mins)" causes them to expire! So they are inactive
>>> sessions, but are somehow not expired automatically.
>> Again:
>>
>> Thread dumps.
>>
>> Look at the ContainerBackgroundProcessor thread.
>>
>> If you continue to ignore folks giving you advice don't expect the
>> advice to continue.
>>
>> Mark
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
> 
> 
> -- 
> *Kirill Kireyev, PhD*
> Founder/CTO instaGrok.com <http://www.instagrok.com>
> kirill@instagrok.com
> Twitter: @instaGrok <http://twitter.com/InstaGrok>
> FB: facebook.com/instagrok <http://www.facebook.com/instagrok>
> <http://www.instagrok.com>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message