Author: markt Date: Fri Feb 19 19:03:04 2016 New Revision: 1731284 URL: http://svn.apache.org/viewvc?rev=1731284&view=rev Log: Fix https://bz.apache.org/bugzilla/show_bug.cgi?id=57809 Remove the custom context attribute that held the effective web.xml. Components needing access to configuration information may access it via the Servlet API.
Modified: tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java tomcat/trunk/java/org/apache/tomcat/util/scan/Constants.java tomcat/trunk/webapps/docs/changelog.xml Modified: tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java?rev=1731284&r1=1731283&r2=1731284&view=diff ============================================================================== --- tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java (original) +++ tomcat/trunk/java/org/apache/catalina/startup/ContextConfig.java Fri Feb 19 19:03:04 2016 @@ -1191,16 +1191,8 @@ public class ContextConfig implements Li configureContext(webXml); } - // Step 9a. Make the merged web.xml available to other - // components, specifically Jasper, to save those components - // from having to re-generate it. - // TODO Use a ServletContainerInitializer for Jasper - String mergedWebXml = webXml.toXml(); - sContext.setAttribute( - org.apache.tomcat.util.scan.Constants.MERGED_WEB_XML, - mergedWebXml); if (context.getLogEffectiveWebXml()) { - log.info("web.xml:\n" + mergedWebXml); + log.info("web.xml:\n" + webXml.toXml()); } // Always need to look for static resources Modified: tomcat/trunk/java/org/apache/tomcat/util/scan/Constants.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/util/scan/Constants.java?rev=1731284&r1=1731283&r2=1731284&view=diff ============================================================================== --- tomcat/trunk/java/org/apache/tomcat/util/scan/Constants.java (original) +++ tomcat/trunk/java/org/apache/tomcat/util/scan/Constants.java Fri Feb 19 19:03:04 2016 @@ -34,11 +34,4 @@ public final class Constants { public static final String JAR_EXT = ".jar"; public static final String WEB_INF_LIB = "/WEB-INF/lib/"; public static final String WEB_INF_CLASSES = "/WEB-INF/classes"; - - /* Context attributes */ - @Deprecated // Third party components should use standard Servlet API - // mechanisms such as a ServletContainerInitializer to access - // configuration information - public static final String MERGED_WEB_XML = - "org.apache.tomcat.util.scan.MergedWebXml"; } Modified: tomcat/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/trunk/webapps/docs/changelog.xml?rev=1731284&r1=1731283&r2=1731284&view=diff ============================================================================== --- tomcat/trunk/webapps/docs/changelog.xml (original) +++ tomcat/trunk/webapps/docs/changelog.xml Fri Feb 19 19:03:04 2016 @@ -103,6 +103,11 @@ Switch to the web application class loader to the <code>ParallelWebappClassLoader</code> by default. (markt) </update> + <fix> + <bug>57809</bug>: Remove the custom context attribute that held the + effective web.xml. Components needing access to configuration + information may access it via the Servlet API. (markt) + </fix> </changelog> </subsection> <subsection name="Coyote"> --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org