https://issues.apache.org/bugzilla/show_bug.cgi?id=51124

--- Comment #5 from Ramiro <ram...@conductiva.com> 2011-05-05 07:42:04 UTC ---
No plans for us to upgrade to 7.0 in the near future. We are already testing
6.0.32 with the patch in #2, so no binary patch needed for us, thanks. We will
apply Mark patch in trunk to our build to test with the same code.

Although with an OOME we almost always need to restart a JVM in some
applications I think this is not always the case with Tomcat (or other server
applications) if the lack of memory is due to a server traffic peak and
servlets in the applications use many tags with big buffered content. Of course
it depends on which point the OOME is thrown.

When this happens the affected request is aborted and all local resources are
freed, including huge buffers allocated by tags (which are the cause of the
problem for us), so it is not strange that the server can recover in some cases
without needing to restart the JVM. 

If this happens (that JVM can free memory after the first OOME to handle
following requests) Tomcat is still unusable because of BodyContentImpl
instances with an invalid buffer are pooled in PageContext instances at
JspFactoryImpl. 

Although the invalid BodyContentImpl instances should be recycled by
PageContextImpl.release, in our experience the instances with the invalid
buffer are used after the OOME.

Last time we saw this problem, our server seemed to recover from the error
after some time (several minutes) throwing the ArrayIndexOutOfBoundsException
(AIOOBE) in certain requests very often. After some time working fine (more
than 30 minutes) AIOOBE started again in some requests (without any other
OOME), we supose because pooled PageContextImpl instances with invalid
BodyContextImpl instances were used again needing a big buffer.

So, and always with our experience, we think that in certain circumstances
Tomcat can recover from an OOME in BodyContentImp.reAllocBuff, but these pooled
invalid BodyContentImpl instances will force to restart JVM to clean them.

Of course, we would like the patch in trunk applied also to 6.0.x ;)

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to