https://issues.apache.org/bugzilla/show_bug.cgi?id=53081
Bug #: 53081 Summary: WebappClassLoader causes java.lang.OutOfMemoryError in findResourceInternal() Product: Tomcat 7 Version: 7.0.26 Platform: PC Status: NEW Severity: normal Priority: P2 Component: Catalina AssignedTo: dev@tomcat.apache.org ReportedBy: dm...@mail.ru Classification: Unclassified When examining the code of WebappClassLoader#findResourceInternal() (http://grepcode.com/file/repo1.maven.org/maven2/org.apache.tomcat/tomcat-catalina/7.0.26/org/apache/catalina/loader/WebappClassLoader.java#3098) I came to the conclusion that findResourceInternal() always loads the binary content of the resource, however binary content is only used in e.g. findClassInternal() and obviously not needed in findResource(). In certain cases this can cause OutOfMemoryError, for example when a big media file is packaged with application. The example of stack trace is given here: http://stackoverflow.com/questions/10100480 Solution: the binary content should be loaded for certain types of resources (.classpath or .properties [only if fileNeedConvert is true]). -- 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