aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-main
diff options
context:
space:
mode:
authorSimon Brandhof <simon.brandhof@sonarsource.com>2018-04-27 11:21:12 +0200
committerSonarTech <sonartech@sonarsource.com>2018-05-10 20:20:55 +0200
commit8282e6a7e3d1568637e734c957013fba14bc5aff (patch)
treed1fbcf7d568340584b67f7ed46e1fd62aef665e6 /server/sonar-main
parent4c006dfe398bbf0fc47f7742dd3170296e1d75aa (diff)
downloadsonarqube-8282e6a7e3d1568637e734c957013fba14bc5aff.tar.gz
sonarqube-8282e6a7e3d1568637e734c957013fba14bc5aff.zip
SONAR-10604 ignore sonar.cluster.node.port on search nodes
Diffstat (limited to 'server/sonar-main')
-rw-r--r--server/sonar-main/src/main/java/org/sonar/application/config/ClusterSettings.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/server/sonar-main/src/main/java/org/sonar/application/config/ClusterSettings.java b/server/sonar-main/src/main/java/org/sonar/application/config/ClusterSettings.java
index ddd71cda2fb..1aafe77daa1 100644
--- a/server/sonar-main/src/main/java/org/sonar/application/config/ClusterSettings.java
+++ b/server/sonar-main/src/main/java/org/sonar/application/config/ClusterSettings.java
@@ -26,6 +26,7 @@ import java.util.Arrays;
import java.util.List;
import java.util.function.Consumer;
import org.apache.commons.lang.StringUtils;
+import org.slf4j.LoggerFactory;
import org.sonar.process.MessageException;
import org.sonar.process.NetworkUtils;
import org.sonar.process.ProcessId;
@@ -42,6 +43,7 @@ import static org.sonar.process.ProcessProperties.Property.AUTH_JWT_SECRET;
import static org.sonar.process.ProcessProperties.Property.CLUSTER_ENABLED;
import static org.sonar.process.ProcessProperties.Property.CLUSTER_HOSTS;
import static org.sonar.process.ProcessProperties.Property.CLUSTER_NODE_HOST;
+import static org.sonar.process.ProcessProperties.Property.CLUSTER_NODE_PORT;
import static org.sonar.process.ProcessProperties.Property.CLUSTER_NODE_TYPE;
import static org.sonar.process.ProcessProperties.Property.CLUSTER_SEARCH_HOSTS;
import static org.sonar.process.ProcessProperties.Property.CLUSTER_WEB_STARTUP_LEADER;
@@ -78,6 +80,9 @@ public class ClusterSettings implements Consumer<Props> {
case SEARCH:
requireValue(props, SEARCH_HOST.getKey());
ensureLocalButNotLoopbackAddress(props, SEARCH_HOST.getKey());
+ if (props.contains(CLUSTER_NODE_PORT.getKey())) {
+ LoggerFactory.getLogger(getClass()).warn("Property {} is ignored on search nodes since 7.2", CLUSTER_NODE_PORT.getKey());
+ }
break;
default:
throw new UnsupportedOperationException("Unknown value: " + nodeType);