Tomcat does not release timedout sessions

I'm working with Tomcat 5 under JBoss.

When my application is running for a long while I can see that there are some sessions that although their timeout has passed still were not invalidated by Tomcat.

These sessions getLastAccessedTime() is about 30 sec after creation.

Their time out is set to 420sec (7min).

Trying to invalidate those works just fine, after invalidating them they are just gone.

Important to remember that most sessions are invalidated automatically by Tomcat.

Are there any known defects in Tomcat creating this behavior?

Thanks,

Yohai

[613 byte] By [ydaroma] at [2007-10-2 5:50:00]
# 1
Tomcat periodically checks for timed out sessions and invalidates them. The process is not instantaneous. You can configure how often Tomcat does these checks by setting the managerChecksFrequency attribute. http://tomcat.apache.org/tomcat-5.0-doc/config/context.html
tolmanka at 2007-7-16 1:59:25 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2
Thanks.This might have been true if Tomcat would have not released any session.However, the problem here is inconsistency.Most of the sessions are invalidated within the a few seconds but some lasts forever (i.e. 21 days)Yohai
ydaroma at 2007-7-16 1:59:25 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3
The I would check the code to make sure that the session getMaxInactiveInterval is not being set for the session not to time out.
tolmanka at 2007-7-16 1:59:25 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 4
Can you reproduce this failure with a very simple example? If so, it's likely a Tomcat bug, if not it's most likely a bug in your code.Here's a [url= http://issues.apache.org/bugzilla/show_bug.cgi?id=37356]tomcat bug report [/url]that looks a lot like this, is it yours?
pkwoostera at 2007-7-16 1:59:25 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 5
Had I opened a bug it would have been the exact one you have likned me to.Thanks.
ydaroma at 2007-7-16 1:59:25 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...