aboutsummaryrefslogtreecommitdiffstats
path: root/controller-api
diff options
context:
space:
mode:
authorMartin Polden <mpolden@mpolden.no>2019-07-18 15:39:51 +0200
committerMartin Polden <mpolden@mpolden.no>2019-07-18 15:51:48 +0200
commitbe249271130dde76e55d87810ca2fd9f608586e0 (patch)
tree8460b0c361fc94260aa8640d684d0f33a8baf837 /controller-api
parent128592fc4a5a8342cefcc241f17d23a9186c100f (diff)
Create ALIAS records for DeploymentSpec endpoints
ALIAS records (global endpoints for directly routed zones) will now be created from endpoints declared in `DeploymentSpec`.
Diffstat (limited to 'controller-api')
-rw-r--r--controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/LoadBalancer.java12
1 files changed, 12 insertions, 0 deletions
diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/LoadBalancer.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/LoadBalancer.java
index 9f686570da1..1b0c0b9d982 100644
--- a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/LoadBalancer.java
+++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/LoadBalancer.java
@@ -25,6 +25,8 @@ public class LoadBalancer {
private final Optional<String> dnsZone;
private final Set<RotationName> rotations;
+ // TODO(mpolden): Kept for API compatibility with internal code. This constructor can be removed when all usages are
+ // TODO(mpolden): removed
public LoadBalancer(String id, ApplicationId application, ClusterSpec.Id cluster, HostName hostname,
Optional<String> dnsZone, Set<RotationName> rotations) {
this.id = Objects.requireNonNull(id, "id must be non-null");
@@ -35,6 +37,16 @@ public class LoadBalancer {
this.rotations = ImmutableSortedSet.copyOf(Objects.requireNonNull(rotations, "rotations must be non-null"));
}
+ public LoadBalancer(String id, ApplicationId application, ClusterSpec.Id cluster, HostName hostname,
+ Optional<String> dnsZone) {
+ this.id = Objects.requireNonNull(id, "id must be non-null");
+ this.application = Objects.requireNonNull(application, "application must be non-null");
+ this.cluster = Objects.requireNonNull(cluster, "cluster must be non-null");
+ this.hostname = Objects.requireNonNull(hostname, "hostname must be non-null");
+ this.dnsZone = Objects.requireNonNull(dnsZone, "dnsZone must be non-null");
+ this.rotations = Set.of();
+ }
+
public String id() {
return id;
}