aboutsummaryrefslogtreecommitdiffstats
path: root/server
diff options
context:
space:
mode:
authorDaniel Schwarz <daniel.schwarz@sonarsource.com>2017-10-02 09:20:54 +0200
committerDaniel Schwarz <bartfastiel@users.noreply.github.com>2017-10-02 10:29:19 +0200
commit2c819392f3d7d67d100e51cc2afa30b32a48cb6e (patch)
tree533929c758da22f46f1fa42699d0d0e3e053e1ee /server
parent8115d8b7e41c38120650bac7432291c722b9a7c3 (diff)
downloadsonarqube-2c819392f3d7d67d100e51cc2afa30b32a48cb6e.tar.gz
sonarqube-2c819392f3d7d67d100e51cc2afa30b32a48cb6e.zip
SONAR-9811 fix quality flaws
Renamed variable to avoid misunderstandings
Diffstat (limited to 'server')
-rw-r--r--server/sonar-main/src/main/java/org/sonar/application/es/EsFileSystem.java10
-rw-r--r--server/sonar-main/src/main/java/org/sonar/application/process/ProcessLauncherImpl.java2
2 files changed, 6 insertions, 6 deletions
diff --git a/server/sonar-main/src/main/java/org/sonar/application/es/EsFileSystem.java b/server/sonar-main/src/main/java/org/sonar/application/es/EsFileSystem.java
index b7f87df7a76..1fb91dc5287 100644
--- a/server/sonar-main/src/main/java/org/sonar/application/es/EsFileSystem.java
+++ b/server/sonar-main/src/main/java/org/sonar/application/es/EsFileSystem.java
@@ -35,7 +35,7 @@ import org.sonar.process.Props;
*/
public class EsFileSystem {
private final File homeDirectory;
- private final List<File> outdatedDataDirectories;
+ private final List<File> outdatedSearchDirectories;
private final File dataDirectory;
private final File confDirectory;
private final File logDirectory;
@@ -44,13 +44,13 @@ public class EsFileSystem {
File sqHomeDir = props.nonNullValueAsFile(ProcessProperties.PATH_HOME);
this.homeDirectory = new File(sqHomeDir, "elasticsearch");
- this.outdatedDataDirectories = buildOutdatedDataDirs(props);
+ this.outdatedSearchDirectories = buildOutdatedSearchDirs(props);
this.dataDirectory = buildDataDir(props);
this.confDirectory = buildConfDir(props);
this.logDirectory = buildLogPath(props);
}
- private static List<File> buildOutdatedDataDirs(Props props) {
+ private static List<File> buildOutdatedSearchDirs(Props props) {
String dataPath = props.nonNullValue(ProcessProperties.PATH_DATA);
return Collections.singletonList(new File(dataPath, "es"));
}
@@ -73,8 +73,8 @@ public class EsFileSystem {
return homeDirectory;
}
- public List<File> getOutdatedDataDirectories() {
- return Collections.unmodifiableList(outdatedDataDirectories);
+ public List<File> getOutdatedSearchDirectories() {
+ return Collections.unmodifiableList(outdatedSearchDirectories);
}
public File getDataDirectory() {
diff --git a/server/sonar-main/src/main/java/org/sonar/application/process/ProcessLauncherImpl.java b/server/sonar-main/src/main/java/org/sonar/application/process/ProcessLauncherImpl.java
index 0f172a9530f..802d53bdf16 100644
--- a/server/sonar-main/src/main/java/org/sonar/application/process/ProcessLauncherImpl.java
+++ b/server/sonar-main/src/main/java/org/sonar/application/process/ProcessLauncherImpl.java
@@ -92,7 +92,7 @@ public class ProcessLauncherImpl implements ProcessLauncher {
private static void cleanupOutdatedEsData(EsCommand esCommand) {
EsFileSystem esFileSystem = esCommand.getFileSystem();
- esFileSystem.getOutdatedDataDirectories().forEach(outdatedDir -> {
+ esFileSystem.getOutdatedSearchDirectories().forEach(outdatedDir -> {
if (outdatedDir.exists()) {
LOG.info("Deleting outdated search index data directory {}", outdatedDir.getAbsolutePath());
try {