Author: violetagg Date: Mon Apr 4 12:08:00 2016 New Revision: 1737666 URL: http://svn.apache.org/viewvc?rev=1737666&view=rev Log: Merged revision 1737664 from tomcat/trunk: Ensure the exceptions caused by Valves/Authenticators will be available in the log files so that they can be evaluated when o.a.catalina.valves.ErrorReportValve.showReport=false. Patch is provided by Svetlin Zarev via mailing list http://marc.info/?l=tomcat-user&m=145951730303576&w=2
Modified: tomcat/tc8.5.x/trunk/ (props changed) tomcat/tc8.5.x/trunk/java/org/apache/catalina/core/StandardHostValve.java tomcat/tc8.5.x/trunk/webapps/docs/changelog.xml Propchange: tomcat/tc8.5.x/trunk/ ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo Mon Apr 4 12:08:00 2016 @@ -1 +1 @@ -/tomcat/trunk:1734785,1734799,1734845,1734928,1735041,1735044,1735480,1735577,1735597,1735599-1735600,1735615,1736145,1736162,1736209,1736280,1736297,1736299,1736489,1736646,1736703,1736836,1736849,1737104-1737105,1737112,1737117,1737119-1737120,1737155,1737157,1737192,1737280,1737339,1737632 +/tomcat/trunk:1734785,1734799,1734845,1734928,1735041,1735044,1735480,1735577,1735597,1735599-1735600,1735615,1736145,1736162,1736209,1736280,1736297,1736299,1736489,1736646,1736703,1736836,1736849,1737104-1737105,1737112,1737117,1737119-1737120,1737155,1737157,1737192,1737280,1737339,1737632,1737664 Modified: tomcat/tc8.5.x/trunk/java/org/apache/catalina/core/StandardHostValve.java URL: http://svn.apache.org/viewvc/tomcat/tc8.5.x/trunk/java/org/apache/catalina/core/StandardHostValve.java?rev=1737666&r1=1737665&r2=1737666&view=diff ============================================================================== --- tomcat/tc8.5.x/trunk/java/org/apache/catalina/core/StandardHostValve.java (original) +++ tomcat/tc8.5.x/trunk/java/org/apache/catalina/core/StandardHostValve.java Mon Apr 4 12:08:00 2016 @@ -147,13 +147,10 @@ final class StandardHostValve extends Va } } catch (Throwable t) { ExceptionUtils.handleThrowable(t); + container.getLogger().error("Exception Processing " + request.getRequestURI(), t); // If a new error occurred while trying to report a previous - // error simply log the new error and allow the original error - // to be reported. - if (response.isErrorReportRequired()) { - container.getLogger().error("Exception Processing " + - request.getRequestURI(), t); - } else { + // error allow the original error to be reported. + if (!response.isErrorReportRequired()) { request.setAttribute(RequestDispatcher.ERROR_EXCEPTION, t); throwable(request, response, t); } Modified: tomcat/tc8.5.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc8.5.x/trunk/webapps/docs/changelog.xml?rev=1737666&r1=1737665&r2=1737666&view=diff ============================================================================== --- tomcat/tc8.5.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc8.5.x/trunk/webapps/docs/changelog.xml Mon Apr 4 12:08:00 2016 @@ -86,6 +86,12 @@ attributes in WebServlet and WebFilter annotations is not allowed. (violetagg) </fix> + <fix> + Ensure the exceptions caused by Valves will be available in the log + files so that they can be evaluated when + <code>o.a.catalina.valves.ErrorReportValve.showReport</code> is + disabled. Patch is provided by Svetlin Zarev. (violetagg) + </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