diff options
author | Julien Lancelot <julien.lancelot@sonarsource.com> | 2018-02-01 13:36:29 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-02-01 13:36:29 +0100 |
commit | e737a37b28a2504aa1a6387606841afd776f2fef (patch) | |
tree | 2ffc650ac5c2e4d3f22621a837db9e8304f1a04b /sonar-application/src/main/java/org/sonar/application | |
parent | 39f671dce022e19460606d9639f3727493a1faf2 (diff) | |
download | sonarqube-e737a37b28a2504aa1a6387606841afd776f2fef.tar.gz sonarqube-e737a37b28a2504aa1a6387606841afd776f2fef.zip |
SONAR-10300 Forbid system properties in api/settings
Diffstat (limited to 'sonar-application/src/main/java/org/sonar/application')
-rw-r--r-- | sonar-application/src/main/java/org/sonar/application/App.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sonar-application/src/main/java/org/sonar/application/App.java b/sonar-application/src/main/java/org/sonar/application/App.java index 5d7e3b64e53..660e2d381b0 100644 --- a/sonar-application/src/main/java/org/sonar/application/App.java +++ b/sonar-application/src/main/java/org/sonar/application/App.java @@ -20,6 +20,8 @@ package org.sonar.application; import java.io.IOException; +import org.sonar.application.command.CommandFactory; +import org.sonar.application.command.CommandFactoryImpl; import org.sonar.application.config.AppSettings; import org.sonar.application.config.AppSettingsLoader; import org.sonar.application.config.AppSettingsLoaderImpl; @@ -29,11 +31,9 @@ import org.sonar.application.process.StopRequestWatcher; import org.sonar.application.process.StopRequestWatcherImpl; import org.sonar.process.System2; import org.sonar.process.SystemExit; -import org.sonar.application.command.CommandFactory; -import org.sonar.application.command.CommandFactoryImpl; import static org.sonar.application.config.SonarQubeVersionHelper.getSonarqubeVersion; -import static org.sonar.process.ProcessProperties.CLUSTER_NAME; +import static org.sonar.process.ProcessProperties.Property.CLUSTER_NAME; public class App { @@ -50,7 +50,7 @@ public class App { try (AppState appState = new AppStateFactory(settings).create()) { appState.registerSonarQubeVersion(getSonarqubeVersion()); - appState.registerClusterName(settings.getProps().nonNullValue(CLUSTER_NAME)); + appState.registerClusterName(settings.getProps().nonNullValue(CLUSTER_NAME.getKey())); AppReloader appReloader = new AppReloaderImpl(settingsLoader, fileSystem, appState, logging); fileSystem.reset(); CommandFactory commandFactory = new CommandFactoryImpl(settings.getProps(), fileSystem.getTempDir(), System2.INSTANCE); |