diff options
author | Duarte Meneses <duarte.meneses@sonarsource.com> | 2019-06-06 14:25:34 -0500 |
---|---|---|
committer | SonarTech <sonartech@sonarsource.com> | 2019-06-11 20:21:12 +0200 |
commit | ced6360cc4637eb6f88b73570d7a7fe3bb10caaf (patch) | |
tree | c95982a2a83a3b9910c9faf343216b4cab4b0d7a | |
parent | 8897cc9d2ee3bea7bca88eb0e29eebf22c737e8b (diff) | |
download | sonarqube-ced6360cc4637eb6f88b73570d7a7fe3bb10caaf.tar.gz sonarqube-ced6360cc4637eb6f88b73570d7a7fe3bb10caaf.zip |
SONAR-12141 Database needs migration : misleading instruction message
3 files changed, 7 insertions, 4 deletions
diff --git a/server/sonar-server/src/main/java/org/sonar/server/platform/DatabaseServerCompatibility.java b/server/sonar-server/src/main/java/org/sonar/server/platform/DatabaseServerCompatibility.java index 311da2f88b7..ea8a7f7e336 100644 --- a/server/sonar-server/src/main/java/org/sonar/server/platform/DatabaseServerCompatibility.java +++ b/server/sonar-server/src/main/java/org/sonar/server/platform/DatabaseServerCompatibility.java @@ -55,7 +55,8 @@ public class DatabaseServerCompatibility implements Startable { } boolean blueGreen = configuration.getBoolean(ProcessProperties.Property.BLUE_GREEN_ENABLED.getKey()).orElse(false); if (!blueGreen) { - String msg = "Database must be upgraded. Please backup database and browse /setup"; + String msg = "The database must be manually upgraded. Please backup the database and browse /setup. " + + "For more information: https://docs.sonarqube.org/latest/setup/upgrading"; Loggers.get(DatabaseServerCompatibility.class).warn(msg); Loggers.get(STARTUP_LOGGER_NAME).warn('\n' + HIGHLIGHTER + '\n' diff --git a/server/sonar-server/src/main/java/org/sonar/server/platform/Platform.java b/server/sonar-server/src/main/java/org/sonar/server/platform/Platform.java index 8b342923e2e..121d08f774a 100644 --- a/server/sonar-server/src/main/java/org/sonar/server/platform/Platform.java +++ b/server/sonar-server/src/main/java/org/sonar/server/platform/Platform.java @@ -107,7 +107,7 @@ public class Platform { // if AutoDbMigration kicked in or no DB migration was required, startup can be resumed in another thread if (dbRequiresMigration()) { - LOGGER.info("Database needs migration"); + LOGGER.info("Database needs to be migrated. Please refer to https://docs.sonarqube.org/latest/setup/upgrading"); } else { this.autoStarter = autoStarterSupplier.get(); this.autoStarter.execute(new AutoStarterRunnable(autoStarter) { diff --git a/server/sonar-server/src/test/java/org/sonar/server/platform/DatabaseServerCompatibilityTest.java b/server/sonar-server/src/test/java/org/sonar/server/platform/DatabaseServerCompatibilityTest.java index 50c58dcb087..3de7281760b 100644 --- a/server/sonar-server/src/test/java/org/sonar/server/platform/DatabaseServerCompatibilityTest.java +++ b/server/sonar-server/src/test/java/org/sonar/server/platform/DatabaseServerCompatibilityTest.java @@ -74,9 +74,11 @@ public class DatabaseServerCompatibilityTest { assertThat(logTester.logs()).hasSize(2); assertThat(logTester.logs(LoggerLevel.WARN)).contains( - "Database must be upgraded. Please backup database and browse /setup", + "The database must be manually upgraded. Please backup the database and browse /setup. " + + "For more information: https://docs.sonarqube.org/latest/setup/upgrading", "\n################################################################################\n" + - " Database must be upgraded. Please backup database and browse /setup\n" + + " The database must be manually upgraded. Please backup the database and browse /setup. " + + "For more information: https://docs.sonarqube.org/latest/setup/upgrading\n" + "################################################################################"); } |