summaryrefslogtreecommitdiffstats
path: root/config-model/src/main/java/com/yahoo
diff options
context:
space:
mode:
authorGeir Storli <geirst@verizonmedia.com>2021-07-16 15:16:21 +0200
committerGitHub <noreply@github.com>2021-07-16 15:16:21 +0200
commitc026937694b26a94719c531d29f6bd0be05c0251 (patch)
treef254cac7d99f5fd0921e2b948d830a0872bf0b95 /config-model/src/main/java/com/yahoo
parentd82075621c0474e2dc1e0d3c03bdc605cd685348 (diff)
parent6b3f45e1972fc0a02922c1a6cfb5c1b9433a413f (diff)
Merge pull request #18630 from vespa-engine/geirst/min-node-ratio-per-group-feature-flag
Add feature flag for min-node-ratio-per-group.
Diffstat (limited to 'config-model/src/main/java/com/yahoo')
-rw-r--r--config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java7
-rw-r--r--config-model/src/main/java/com/yahoo/vespa/model/content/ClusterControllerConfig.java2
2 files changed, 8 insertions, 1 deletions
diff --git a/config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java b/config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java
index 62c192e2c99..a891e16e165 100644
--- a/config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java
+++ b/config-model/src/main/java/com/yahoo/config/model/deploy/TestProperties.java
@@ -66,6 +66,7 @@ public class TestProperties implements ModelContext.Properties, ModelContext.Fea
private List<X509Certificate> operatorCertificates = Collections.emptyList();
private double resourceLimitDisk = 0.8;
private double resourceLimitMemory = 0.8;
+ private double minNodeRatioPerGroup = 0.0;
@Override public ModelContext.FeatureFlags featureFlags() { return this; }
@Override public boolean multitenant() { return multitenant; }
@@ -111,6 +112,7 @@ public class TestProperties implements ModelContext.Properties, ModelContext.Fea
@Override public boolean dryRunOnnxOnSetup() { return dryRunOnnxOnSetup; }
@Override public double resourceLimitDisk() { return resourceLimitDisk; }
@Override public double resourceLimitMemory() { return resourceLimitMemory; }
+ @Override public double minNodeRatioPerGroup() { return minNodeRatioPerGroup; }
public TestProperties setDryRunOnnxOnSetup(boolean value) {
dryRunOnnxOnSetup = value;
@@ -274,6 +276,11 @@ public class TestProperties implements ModelContext.Properties, ModelContext.Fea
return this;
}
+ public TestProperties setMinNodeRatioPerGroup(double value) {
+ this.minNodeRatioPerGroup = value;
+ return this;
+ }
+
public static class Spec implements ConfigServerSpec {
private final String hostName;
diff --git a/config-model/src/main/java/com/yahoo/vespa/model/content/ClusterControllerConfig.java b/config-model/src/main/java/com/yahoo/vespa/model/content/ClusterControllerConfig.java
index 66ec0d81947..b3d03bbbfdb 100644
--- a/config-model/src/main/java/com/yahoo/vespa/model/content/ClusterControllerConfig.java
+++ b/config-model/src/main/java/com/yahoo/vespa/model/content/ClusterControllerConfig.java
@@ -35,7 +35,7 @@ public class ClusterControllerConfig extends AbstractConfigProducer<ClusterContr
ModelElement clusterTuning = clusterElement.child("tuning");
Integer bucketSplittingMinimumBits = null;
- Double minNodeRatioPerGroup = null;
+ Double minNodeRatioPerGroup = deployState.getProperties().featureFlags().minNodeRatioPerGroup();
if (clusterTuning != null) {
tuning = clusterTuning.child("cluster-controller");
minNodeRatioPerGroup = clusterTuning.childAsDouble("min-node-ratio-per-group");