]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-4843 Add log when server is restarted
authorSimon Brandhof <simon.brandhof@gmail.com>
Sat, 15 Mar 2014 22:48:29 +0000 (23:48 +0100)
committerSimon Brandhof <simon.brandhof@gmail.com>
Sat, 15 Mar 2014 22:48:29 +0000 (23:48 +0100)
sonar-server/src/main/java/org/sonar/server/platform/ws/RestartHandler.java

index b0da33a74a70c4283cca29e687573bec8c48adf9..94312f1337736f67300853cf011b1da9661de42c 100644 (file)
@@ -19,6 +19,7 @@
  */
 package org.sonar.server.platform.ws;
 
+import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 import org.sonar.api.config.Settings;
 import org.sonar.api.server.ws.Request;
@@ -48,8 +49,10 @@ public class RestartHandler implements RequestHandler {
   @Override
   public void handle(Request request, Response response) {
     if (settings.getBoolean("sonar.dev")) {
-      LoggerFactory.getLogger(getClass()).info("Restart server");
+      Logger logger = LoggerFactory.getLogger(getClass());
+      logger.info("Restart server");
       platform.restartLevel3Container();
+      logger.info("Server restarted");
       response.noContent();
 
     } else {