aboutsummaryrefslogtreecommitdiffstats
path: root/flags
diff options
context:
space:
mode:
authorMartin Polden <mpolden@mpolden.no>2020-05-26 16:11:12 +0200
committerMartin Polden <mpolden@mpolden.no>2020-05-27 15:08:24 +0200
commite8d4b2c1ce8b5d52143d39682849e55d74d2ad54 (patch)
treeec58f4aaa7a47247cd4d6f866a8fa4b14470929e /flags
parent9be54355fa8938c3537fbf9b0ede5c0e597b997c (diff)
Rename PreprovisionCapacity -> HostCapacity
Diffstat (limited to 'flags')
-rw-r--r--flags/src/main/java/com/yahoo/vespa/flags/Flags.java12
-rw-r--r--flags/src/main/java/com/yahoo/vespa/flags/custom/HostCapacity.java (renamed from flags/src/main/java/com/yahoo/vespa/flags/custom/PreprovisionCapacity.java)14
2 files changed, 13 insertions, 13 deletions
diff --git a/flags/src/main/java/com/yahoo/vespa/flags/Flags.java b/flags/src/main/java/com/yahoo/vespa/flags/Flags.java
index 60daddc7ee0..108a1fe1bb9 100644
--- a/flags/src/main/java/com/yahoo/vespa/flags/Flags.java
+++ b/flags/src/main/java/com/yahoo/vespa/flags/Flags.java
@@ -3,7 +3,7 @@ package com.yahoo.vespa.flags;
import com.yahoo.component.Vtag;
import com.yahoo.vespa.defaults.Defaults;
-import com.yahoo.vespa.flags.custom.PreprovisionCapacity;
+import com.yahoo.vespa.flags.custom.HostCapacity;
import java.util.List;
import java.util.Optional;
@@ -122,11 +122,11 @@ public class Flags {
"Takes effect on the next run of RetiredExpirer.",
HOSTNAME);
- public static final UnboundListFlag<PreprovisionCapacity> PREPROVISION_CAPACITY = defineListFlag(
- "preprovision-capacity", List.of(), PreprovisionCapacity.class,
- "List of node resources and their count that should be present in zone to receive new deployments. When a " +
- "preprovisioned is taken, new will be provisioned within next iteration of maintainer.",
- "Takes effect on next iteration of HostProvisionMaintainer.");
+ public static final UnboundListFlag<HostCapacity> PREPROVISION_CAPACITY = defineListFlag(
+ "preprovision-capacity", List.of(), HostCapacity.class,
+ "List of node resources and their count that should be unallocated in zone to receive new deployments. When a " +
+ "preprovisioned host is taken, another one will be provisioned within next iteration of maintainer.",
+ "Takes effect on next iteration of DynamicProvisioningMaintainer.");
public static final UnboundDoubleFlag DEFAULT_TERM_WISE_LIMIT = defineDoubleFlag(
"default-term-wise-limit", 1.0,
diff --git a/flags/src/main/java/com/yahoo/vespa/flags/custom/PreprovisionCapacity.java b/flags/src/main/java/com/yahoo/vespa/flags/custom/HostCapacity.java
index 01eab8dfb9c..947520ca2d7 100644
--- a/flags/src/main/java/com/yahoo/vespa/flags/custom/PreprovisionCapacity.java
+++ b/flags/src/main/java/com/yahoo/vespa/flags/custom/HostCapacity.java
@@ -10,7 +10,7 @@ import java.util.Objects;
* @author freva
*/
@JsonIgnoreProperties(ignoreUnknown = true)
-public class PreprovisionCapacity {
+public class HostCapacity {
@JsonProperty("vcpu")
private final double vcpu;
@@ -23,10 +23,10 @@ public class PreprovisionCapacity {
@JsonProperty("count")
private final int count;
- public PreprovisionCapacity(@JsonProperty("vcpu") double vcpu,
- @JsonProperty("memoryGb") double memoryGb,
- @JsonProperty("diskGb") double diskGb,
- @JsonProperty("count") int count) {
+ public HostCapacity(@JsonProperty("vcpu") double vcpu,
+ @JsonProperty("memoryGb") double memoryGb,
+ @JsonProperty("diskGb") double diskGb,
+ @JsonProperty("count") int count) {
this.vcpu = requirePositive("vcpu", vcpu);
this.memoryGb = requirePositive("memoryGb", memoryGb);
this.diskGb = requirePositive("diskGb", diskGb);
@@ -59,7 +59,7 @@ public class PreprovisionCapacity {
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
- PreprovisionCapacity that = (PreprovisionCapacity) o;
+ HostCapacity that = (HostCapacity) o;
return Double.compare(that.vcpu, vcpu) == 0 &&
Double.compare(that.memoryGb, memoryGb) == 0 &&
Double.compare(that.diskGb, diskGb) == 0 &&
@@ -70,4 +70,4 @@ public class PreprovisionCapacity {
public int hashCode() {
return Objects.hash(vcpu, memoryGb, diskGb, count);
}
-} \ No newline at end of file
+}