Author: markt Date: Mon Oct 10 13:06:12 2016 New Revision: 1764083 URL: http://svn.apache.org/viewvc?rev=1764083&view=rev Log: Exclude JAR files in /WEB-INF/lib from the static resource cache.
Modified: tomcat/trunk/java/org/apache/catalina/webresources/Cache.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/catalina/webresources/Cache.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/webresources/Cache.java?rev=1764083&r1=1764082&r2=1764083&view=diff ============================================================================== --- tomcat/trunk/java/org/apache/catalina/webresources/Cache.java (original) +++ tomcat/trunk/java/org/apache/catalina/webresources/Cache.java Mon Oct 10 13:06:12 2016 @@ -200,9 +200,11 @@ public class Cache { private boolean noCache(String path) { // Don't cache classes. The class loader handles this. - if (path.endsWith(".class") && - (path.startsWith("/WEB-INF/classes/") || - path.startsWith("/WEB-INF/lib/"))) { + // Don't cache JARs. The ResourceSet handles this. + if ((path.endsWith(".class") && + (path.startsWith("/WEB-INF/classes/") || path.startsWith("/WEB-INF/lib/"))) + || + (path.startsWith("/WEB-INF/lib/") && path.endsWith(".jar"))) { return true; } return false; Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1764083&r1=1764082&r2=1764083&view=diff ============================================================================== --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Mon Oct 10 13:06:12 2016 @@ -64,6 +64,10 @@ Include the Context name in the log message when an item cannot be added to the cache. (markt) </fix> + <fix> + Exclude JAR files in <code>/WEB-INF/lib</code> from the static resource + cache. (markt) + </fix> </changelog> </subsection> <subsection name="Jasper"> --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org