Hi folks, I'm currently investigating a memory leak in a OJB-using application, and it seems as if StringUtils is the culprit at least in terms of memory consumption (OJB uses StringUtils#split, #replace and #indexOfAny). The problem is as follows: upon reloading a really simple webapp in Tomcat (5.5.12, Windows XP SP2, Java 1.5.0_04-b05) 5 times, there are 5 instances of StringUtils (or more precisely, their static fields) still in the memory (seems Tomcat uses a different classloader for StringUtils, but that is a different issue). My problem with StringUtils is now that each of these StringUtils' is using 262.152 bytes of memory in an array of 65535 strings. After a bit of digging in the class, it seems as if it retains a string for every character, and this even if padding is not utilized. My question is now: is there some way this could be changed ? I'm thinking along the lines of lazy initialization, or perhaps in the way BeanUtils handles this (e.g. StringUtilsBean and static StringUtils).
regards, Tom --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]