aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSébastien Lesaint <sebastien.lesaint@sonarsource.com>2017-02-20 18:27:42 +0100
committerSébastien Lesaint <sebastien.lesaint@sonarsource.com>2017-02-24 20:27:07 +0100
commit6f7c07a6b2a4f8bf3f8674f82592bd8018e3a88d (patch)
tree4cf930bcf2af5a6cf4b488920fe539343051faeb
parentf8304edef63a6648ab1f05843a6be4e99af9dc71 (diff)
downloadsonarqube-6f7c07a6b2a4f8bf3f8674f82592bd8018e3a88d.tar.gz
sonarqube-6f7c07a6b2a4f8bf3f8674f82592bd8018e3a88d.zip
SONAR-7500 TomcatAccessLog must log at DEBUG level
the information that the web server is started/stopped is already logged by other classes with logger name more relevant to the labels of the logs
-rw-r--r--server/sonar-server/src/main/java/org/sonar/server/app/TomcatAccessLog.java4
-rw-r--r--server/sonar-server/src/test/java/org/sonar/server/app/TomcatAccessLogTest.java4
2 files changed, 4 insertions, 4 deletions
diff --git a/server/sonar-server/src/main/java/org/sonar/server/app/TomcatAccessLog.java b/server/sonar-server/src/main/java/org/sonar/server/app/TomcatAccessLog.java
index fcd441d8122..a51db1fbe15 100644
--- a/server/sonar-server/src/main/java/org/sonar/server/app/TomcatAccessLog.java
+++ b/server/sonar-server/src/main/java/org/sonar/server/app/TomcatAccessLog.java
@@ -68,10 +68,10 @@ class TomcatAccessLog {
@Override
public void lifecycleEvent(LifecycleEvent event) {
if ("after_start".equals(event.getType())) {
- logger.info("Web server is started");
+ logger.debug("Tomcat is started");
} else if ("after_destroy".equals(event.getType())) {
- logger.info("Web server is stopped");
+ logger.debug("Tomcat is stopped");
}
}
}
diff --git a/server/sonar-server/src/test/java/org/sonar/server/app/TomcatAccessLogTest.java b/server/sonar-server/src/test/java/org/sonar/server/app/TomcatAccessLogTest.java
index d63a6a3cc1d..0d4f290ce36 100644
--- a/server/sonar-server/src/test/java/org/sonar/server/app/TomcatAccessLogTest.java
+++ b/server/sonar-server/src/test/java/org/sonar/server/app/TomcatAccessLogTest.java
@@ -71,10 +71,10 @@ public class TomcatAccessLogTest {
event = new LifecycleEvent(mock(Lifecycle.class), "after_start", null);
listener.lifecycleEvent(event);
- verify(logger).info("Web server is started");
+ verify(logger).debug("Tomcat is started");
event = new LifecycleEvent(mock(Lifecycle.class), "after_destroy", null);
listener.lifecycleEvent(event);
- verify(logger).info("Web server is stopped");
+ verify(logger).debug("Tomcat is stopped");
}
}