This is an automated email from the ASF dual-hosted git repository. markt pushed a commit to branch 7.0.x in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/7.0.x by this push: new 06b1e44 Fix BZ 65047 include user info if access log valve can't open log file 06b1e44 is described below commit 06b1e4462b51c3e1609a9d312391717f6f4e7a1c Author: Mark Thomas <ma...@apache.org> AuthorDate: Mon Jan 4 15:26:51 2021 +0000 Fix BZ 65047 include user info if access log valve can't open log file https://bz.apache.org/bugzilla/show_bug.cgi?id=65047 --- java/org/apache/catalina/valves/AccessLogValve.java | 2 +- java/org/apache/catalina/valves/LocalStrings.properties | 2 +- webapps/docs/changelog.xml | 5 +++++ 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/java/org/apache/catalina/valves/AccessLogValve.java b/java/org/apache/catalina/valves/AccessLogValve.java index 6dba9f1..b231dc1 100644 --- a/java/org/apache/catalina/valves/AccessLogValve.java +++ b/java/org/apache/catalina/valves/AccessLogValve.java @@ -1285,7 +1285,7 @@ public class AccessLogValve extends ValveBase implements AccessLog { } catch (IOException e) { writer = null; currentLogFile = null; - log.error(sm.getString("accessLogValve.openFail", pathname), e); + log.error(sm.getString("accessLogValve.openFail", pathname, System.getProperty("user.name")), e); } // Rotating a log file will always trigger a new file to be opened so // when a new file is opened, check to see if any old files need to be diff --git a/java/org/apache/catalina/valves/LocalStrings.properties b/java/org/apache/catalina/valves/LocalStrings.properties index 6ad98b0..5397f43 100644 --- a/java/org/apache/catalina/valves/LocalStrings.properties +++ b/java/org/apache/catalina/valves/LocalStrings.properties @@ -19,7 +19,7 @@ accessLogValve.deleteFail=Failed to delete old access log [{0}] accessLogValve.invalidLocale=Failed to set locale to [{0}] accessLogValve.invalidPortType=Invalid port type [{0}], using server (local) port accessLogValve.openDirFail=Failed to create directory [{0}] for access logs -accessLogValve.openFail=Failed to open access log file [{0}] +accessLogValve.openFail=Failed to open access log file [{0}] Note: running as user [{1}] accessLogValve.renameFail=Failed to rename access log from [{0}] to [{1}] accessLogValve.rotateFail=Failed to rotate access log accessLogValve.unsupportedEncoding=Failed to set encoding to [{0}], will use the system default character set. diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml index 8c15c5e..d410c85 100644 --- a/webapps/docs/changelog.xml +++ b/webapps/docs/changelog.xml @@ -135,6 +135,11 @@ Avoid uncaught InaccessibleObjectException on Java 16 trying to clear references threads. (remm) </fix> + <fix> + <bug>65047</bug>: If the <code>AccessLogValve</code> is unable to open + the access log file, include information on the current user in the + associated log message (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