You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2005/09/10 21:34:51 UTC

DO NOT REPLY [Bug 36594] New: - Hang (infinite loop) in ResourceCache under high load

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=36594>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=36594

           Summary: Hang (infinite loop) in ResourceCache under high load
           Product: Tomcat 5
           Version: 5.5.9
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: major
          Priority: P2
         Component: Catalina
        AssignedTo: tomcat-dev@jakarta.apache.org
        ReportedBy: anil@busybuddha.org


Under sustained high loads (100-200 requests per sec) over 12+ hour periods we
were regularly hitting a situation where all of the serving threads would be
blocked except for one thread looping infinitely in
org.apache.naming.resources.ResourceCache#allocate().

After quite a bit of effort, we tracked this down to a number of minor bugs in
the ResourceCache code, two having to do with the cacheSize accounting, and one
to do with an off-by-one error in the range of the random generation of an index
to consider for freeing.

We've created a local patch, and we've verified that this fixes the issue for
us, actually monitoring the correctness of the cacheSize accounting.  I will be
attaching a patched source for ResourceCache.java.  Please consider
incorporating these fixes into subsequent revisions.  The bug appears both in
Tomcat 5.0.30 and the latest trunk code.

Anil Gangolli (anil@busybuddha.org / gangolli@apache.org)

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

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