From eb3927fff15edaffedf89817378f4b73ce2eef49 Mon Sep 17 00:00:00 2001 From: Valerij Fredriksen Date: Tue, 11 Jun 2019 22:29:28 +0200 Subject: Remove vaas --- .../controller/api/integration/deployment/JobType.java | 4 ---- .../yahoo/vespa/hosted/controller/api/role/RoleTest.java | 16 ++++++++-------- 2 files changed, 8 insertions(+), 12 deletions(-) (limited to 'controller-api') diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java index 585a8f84fb2..94e111455ac 100644 --- a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java +++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java @@ -15,7 +15,6 @@ import java.util.stream.Stream; import static com.yahoo.config.provision.SystemName.PublicCd; import static com.yahoo.config.provision.SystemName.cd; import static com.yahoo.config.provision.SystemName.main; -import static com.yahoo.config.provision.SystemName.vaas; /** Job types that exist in the build system */ public enum JobType { @@ -88,9 +87,6 @@ public enum JobType { devCdUsCentral1 ("dev-cd-us-central-1", Map.of(cd , ZoneId.from("dev" , "cd-us-central-1"))), - devAwsUsEast1b ("dev-aws-us-east-1b", - Map.of(vaas, ZoneId.from("dev" , "vaas-aws-us-east-1b"))), - devAwsUsEast1c ("dev-aws-us-east-1c", Map.of(PublicCd, ZoneId.from("dev", "aws-us-east-1c"))), diff --git a/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java b/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java index 4c11da3b697..d141ef6c73e 100644 --- a/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java +++ b/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java @@ -17,7 +17,7 @@ import static org.junit.Assert.assertTrue; public class RoleTest { private static final Enforcer mainEnforcer = new Enforcer(SystemName.main); - private static final Enforcer vaasEnforcer = new Enforcer(SystemName.vaas); + private static final Enforcer publicEnforcer = new Enforcer(SystemName.Public); @Test public void operator_membership() { @@ -40,18 +40,18 @@ public class RoleTest { assertTrue(mainEnforcer.allows(role, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); Role publicSystem = Role.athenzTenantAdmin(TenantName.from("t1")); - assertFalse(vaasEnforcer.allows(publicSystem, Action.read, URI.create("/controller/v1/foo"))); - assertTrue(vaasEnforcer.allows(publicSystem, Action.read, URI.create("/badge/v1/badge"))); - assertTrue(vaasEnforcer.allows(publicSystem, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); + assertFalse(publicEnforcer.allows(publicSystem, Action.read, URI.create("/controller/v1/foo"))); + assertTrue(publicEnforcer.allows(publicSystem, Action.read, URI.create("/badge/v1/badge"))); + assertTrue(publicEnforcer.allows(publicSystem, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); } @Test public void build_service_membership() { Role role = Role.tenantPipeline(TenantName.from("t1"), ApplicationName.from("a1")); - assertFalse(vaasEnforcer.allows(role, Action.create, URI.create("/not/explicitly/defined"))); - assertFalse(vaasEnforcer.allows(role, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); - assertTrue(vaasEnforcer.allows(role, Action.create, URI.create("/application/v4/tenant/t1/application/a1/jobreport"))); - assertFalse("No global read access", vaasEnforcer.allows(role, Action.read, URI.create("/controller/v1/foo"))); + assertFalse(publicEnforcer.allows(role, Action.create, URI.create("/not/explicitly/defined"))); + assertFalse(publicEnforcer.allows(role, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); + assertTrue(publicEnforcer.allows(role, Action.create, URI.create("/application/v4/tenant/t1/application/a1/jobreport"))); + assertFalse("No global read access", publicEnforcer.allows(role, Action.read, URI.create("/controller/v1/foo"))); } @Test -- cgit v1.2.3 From a7a5e809c4261e34b8545ee0e73ed96e609d1411 Mon Sep 17 00:00:00 2001 From: Harald Musum Date: Wed, 12 Jun 2019 07:50:21 +0200 Subject: Revert "Remove vaas" --- config-provisioning/abi-spec.json | 3 ++- .../main/java/com/yahoo/config/provision/SystemName.java | 7 ++++++- .../java/com/yahoo/config/provision/SystemNameTest.java | 4 ++-- .../controller/api/integration/deployment/JobType.java | 4 ++++ .../yahoo/vespa/hosted/controller/api/role/RoleTest.java | 16 ++++++++-------- .../vespa/hosted/controller/application/Endpoint.java | 1 + .../java/ai/vespa/hosted/api/ControllerHttpClient.java | 3 ++- 7 files changed, 25 insertions(+), 13 deletions(-) (limited to 'controller-api') diff --git a/config-provisioning/abi-spec.json b/config-provisioning/abi-spec.json index 18f4d317019..aa9b196c0e4 100644 --- a/config-provisioning/abi-spec.json +++ b/config-provisioning/abi-spec.json @@ -790,7 +790,8 @@ "public static final enum com.yahoo.config.provision.SystemName main", "public static final enum com.yahoo.config.provision.SystemName Public", "public static final enum com.yahoo.config.provision.SystemName PublicCd", - "public static final enum com.yahoo.config.provision.SystemName dev" + "public static final enum com.yahoo.config.provision.SystemName dev", + "public static final enum com.yahoo.config.provision.SystemName vaas" ] }, "com.yahoo.config.provision.TenantName": { diff --git a/config-provisioning/src/main/java/com/yahoo/config/provision/SystemName.java b/config-provisioning/src/main/java/com/yahoo/config/provision/SystemName.java index 45962fc596a..ba462b9eb64 100644 --- a/config-provisioning/src/main/java/com/yahoo/config/provision/SystemName.java +++ b/config-provisioning/src/main/java/com/yahoo/config/provision/SystemName.java @@ -27,7 +27,10 @@ public enum SystemName { PublicCd(true, true), /** Local development system */ - dev(false, false); // TODO: Remove this and use public everywhere + dev(false, false), + + /** VaaS */ + vaas(true, true); // TODO: Remove this and use public everywhere private final boolean isPublic; private final boolean isCd; @@ -48,6 +51,7 @@ public enum SystemName { case "main": return main; case "public": return Public; case "publiccd": return PublicCd; + case "vaas": return vaas; default: throw new IllegalArgumentException(String.format("'%s' is not a valid system", value)); } } @@ -59,6 +63,7 @@ public enum SystemName { case main: return "main"; case Public: return "public"; case PublicCd: return "publiccd"; + case vaas: return "vaas"; default : throw new IllegalStateException(); } } diff --git a/config-provisioning/src/test/java/com/yahoo/config/provision/SystemNameTest.java b/config-provisioning/src/test/java/com/yahoo/config/provision/SystemNameTest.java index f50005edd52..eb066958254 100644 --- a/config-provisioning/src/test/java/com/yahoo/config/provision/SystemNameTest.java +++ b/config-provisioning/src/test/java/com/yahoo/config/provision/SystemNameTest.java @@ -20,7 +20,7 @@ public class SystemNameTest { @Test public void allOf() { - assertEquals(Set.of(SystemName.cd, SystemName.PublicCd), SystemName.allOf(SystemName::isCd)); - assertEquals(Set.of(SystemName.PublicCd, SystemName.Public), SystemName.allOf(SystemName::isPublic)); + assertEquals(Set.of(SystemName.cd, SystemName.PublicCd, SystemName.vaas), SystemName.allOf(SystemName::isCd)); + assertEquals(Set.of(SystemName.PublicCd, SystemName.Public, SystemName.vaas), SystemName.allOf(SystemName::isPublic)); } } \ No newline at end of file diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java index 94e111455ac..585a8f84fb2 100644 --- a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java +++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java @@ -15,6 +15,7 @@ import java.util.stream.Stream; import static com.yahoo.config.provision.SystemName.PublicCd; import static com.yahoo.config.provision.SystemName.cd; import static com.yahoo.config.provision.SystemName.main; +import static com.yahoo.config.provision.SystemName.vaas; /** Job types that exist in the build system */ public enum JobType { @@ -87,6 +88,9 @@ public enum JobType { devCdUsCentral1 ("dev-cd-us-central-1", Map.of(cd , ZoneId.from("dev" , "cd-us-central-1"))), + devAwsUsEast1b ("dev-aws-us-east-1b", + Map.of(vaas, ZoneId.from("dev" , "vaas-aws-us-east-1b"))), + devAwsUsEast1c ("dev-aws-us-east-1c", Map.of(PublicCd, ZoneId.from("dev", "aws-us-east-1c"))), diff --git a/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java b/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java index d141ef6c73e..4c11da3b697 100644 --- a/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java +++ b/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java @@ -17,7 +17,7 @@ import static org.junit.Assert.assertTrue; public class RoleTest { private static final Enforcer mainEnforcer = new Enforcer(SystemName.main); - private static final Enforcer publicEnforcer = new Enforcer(SystemName.Public); + private static final Enforcer vaasEnforcer = new Enforcer(SystemName.vaas); @Test public void operator_membership() { @@ -40,18 +40,18 @@ public class RoleTest { assertTrue(mainEnforcer.allows(role, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); Role publicSystem = Role.athenzTenantAdmin(TenantName.from("t1")); - assertFalse(publicEnforcer.allows(publicSystem, Action.read, URI.create("/controller/v1/foo"))); - assertTrue(publicEnforcer.allows(publicSystem, Action.read, URI.create("/badge/v1/badge"))); - assertTrue(publicEnforcer.allows(publicSystem, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); + assertFalse(vaasEnforcer.allows(publicSystem, Action.read, URI.create("/controller/v1/foo"))); + assertTrue(vaasEnforcer.allows(publicSystem, Action.read, URI.create("/badge/v1/badge"))); + assertTrue(vaasEnforcer.allows(publicSystem, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); } @Test public void build_service_membership() { Role role = Role.tenantPipeline(TenantName.from("t1"), ApplicationName.from("a1")); - assertFalse(publicEnforcer.allows(role, Action.create, URI.create("/not/explicitly/defined"))); - assertFalse(publicEnforcer.allows(role, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); - assertTrue(publicEnforcer.allows(role, Action.create, URI.create("/application/v4/tenant/t1/application/a1/jobreport"))); - assertFalse("No global read access", publicEnforcer.allows(role, Action.read, URI.create("/controller/v1/foo"))); + assertFalse(vaasEnforcer.allows(role, Action.create, URI.create("/not/explicitly/defined"))); + assertFalse(vaasEnforcer.allows(role, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); + assertTrue(vaasEnforcer.allows(role, Action.create, URI.create("/application/v4/tenant/t1/application/a1/jobreport"))); + assertFalse("No global read access", vaasEnforcer.allows(role, Action.read, URI.create("/controller/v1/foo"))); } @Test diff --git a/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/application/Endpoint.java b/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/application/Endpoint.java index 5026ca75a83..6c9b8dd0784 100644 --- a/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/application/Endpoint.java +++ b/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/application/Endpoint.java @@ -152,6 +152,7 @@ public class Endpoint { if (legacy) return YAHOO_DNS_SUFFIX; return OATH_DNS_SUFFIX; case Public: + case vaas: return PUBLIC_DNS_SUFFIX; case PublicCd: return PUBLIC_CD_DNS_SUFFIX; diff --git a/hosted-api/src/main/java/ai/vespa/hosted/api/ControllerHttpClient.java b/hosted-api/src/main/java/ai/vespa/hosted/api/ControllerHttpClient.java index d59eb166e2b..421d946c5db 100644 --- a/hosted-api/src/main/java/ai/vespa/hosted/api/ControllerHttpClient.java +++ b/hosted-api/src/main/java/ai/vespa/hosted/api/ControllerHttpClient.java @@ -201,8 +201,9 @@ public abstract class ControllerHttpClient { + URLEncoder.encode(name, UTF_8) + "=" + URLEncoder.encode(value, UTF_8)); } + // TODO jvenstad: remove when vaas is no longer part of region names. private static String jobNameOf(ZoneId zone) { - return zone.environment().value() + "-" + zone.region().value(); + return zone.environment().value() + "-" + zone.region().value().replaceAll("vaas-", ""); } private HttpResponse send(HttpRequest request) { -- cgit v1.2.3 From e8353801a955ba2d9a4648bf7bca019a45de944d Mon Sep 17 00:00:00 2001 From: Harald Musum Date: Wed, 12 Jun 2019 08:18:54 +0200 Subject: Revert "Revert "Remove vaas"" --- config-provisioning/abi-spec.json | 3 +-- .../main/java/com/yahoo/config/provision/SystemName.java | 7 +------ .../java/com/yahoo/config/provision/SystemNameTest.java | 4 ++-- .../controller/api/integration/deployment/JobType.java | 4 ---- .../yahoo/vespa/hosted/controller/api/role/RoleTest.java | 16 ++++++++-------- .../vespa/hosted/controller/application/Endpoint.java | 1 - .../java/ai/vespa/hosted/api/ControllerHttpClient.java | 3 +-- 7 files changed, 13 insertions(+), 25 deletions(-) (limited to 'controller-api') diff --git a/config-provisioning/abi-spec.json b/config-provisioning/abi-spec.json index aa9b196c0e4..18f4d317019 100644 --- a/config-provisioning/abi-spec.json +++ b/config-provisioning/abi-spec.json @@ -790,8 +790,7 @@ "public static final enum com.yahoo.config.provision.SystemName main", "public static final enum com.yahoo.config.provision.SystemName Public", "public static final enum com.yahoo.config.provision.SystemName PublicCd", - "public static final enum com.yahoo.config.provision.SystemName dev", - "public static final enum com.yahoo.config.provision.SystemName vaas" + "public static final enum com.yahoo.config.provision.SystemName dev" ] }, "com.yahoo.config.provision.TenantName": { diff --git a/config-provisioning/src/main/java/com/yahoo/config/provision/SystemName.java b/config-provisioning/src/main/java/com/yahoo/config/provision/SystemName.java index ba462b9eb64..45962fc596a 100644 --- a/config-provisioning/src/main/java/com/yahoo/config/provision/SystemName.java +++ b/config-provisioning/src/main/java/com/yahoo/config/provision/SystemName.java @@ -27,10 +27,7 @@ public enum SystemName { PublicCd(true, true), /** Local development system */ - dev(false, false), - - /** VaaS */ - vaas(true, true); // TODO: Remove this and use public everywhere + dev(false, false); // TODO: Remove this and use public everywhere private final boolean isPublic; private final boolean isCd; @@ -51,7 +48,6 @@ public enum SystemName { case "main": return main; case "public": return Public; case "publiccd": return PublicCd; - case "vaas": return vaas; default: throw new IllegalArgumentException(String.format("'%s' is not a valid system", value)); } } @@ -63,7 +59,6 @@ public enum SystemName { case main: return "main"; case Public: return "public"; case PublicCd: return "publiccd"; - case vaas: return "vaas"; default : throw new IllegalStateException(); } } diff --git a/config-provisioning/src/test/java/com/yahoo/config/provision/SystemNameTest.java b/config-provisioning/src/test/java/com/yahoo/config/provision/SystemNameTest.java index eb066958254..f50005edd52 100644 --- a/config-provisioning/src/test/java/com/yahoo/config/provision/SystemNameTest.java +++ b/config-provisioning/src/test/java/com/yahoo/config/provision/SystemNameTest.java @@ -20,7 +20,7 @@ public class SystemNameTest { @Test public void allOf() { - assertEquals(Set.of(SystemName.cd, SystemName.PublicCd, SystemName.vaas), SystemName.allOf(SystemName::isCd)); - assertEquals(Set.of(SystemName.PublicCd, SystemName.Public, SystemName.vaas), SystemName.allOf(SystemName::isPublic)); + assertEquals(Set.of(SystemName.cd, SystemName.PublicCd), SystemName.allOf(SystemName::isCd)); + assertEquals(Set.of(SystemName.PublicCd, SystemName.Public), SystemName.allOf(SystemName::isPublic)); } } \ No newline at end of file diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java index 585a8f84fb2..94e111455ac 100644 --- a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java +++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/deployment/JobType.java @@ -15,7 +15,6 @@ import java.util.stream.Stream; import static com.yahoo.config.provision.SystemName.PublicCd; import static com.yahoo.config.provision.SystemName.cd; import static com.yahoo.config.provision.SystemName.main; -import static com.yahoo.config.provision.SystemName.vaas; /** Job types that exist in the build system */ public enum JobType { @@ -88,9 +87,6 @@ public enum JobType { devCdUsCentral1 ("dev-cd-us-central-1", Map.of(cd , ZoneId.from("dev" , "cd-us-central-1"))), - devAwsUsEast1b ("dev-aws-us-east-1b", - Map.of(vaas, ZoneId.from("dev" , "vaas-aws-us-east-1b"))), - devAwsUsEast1c ("dev-aws-us-east-1c", Map.of(PublicCd, ZoneId.from("dev", "aws-us-east-1c"))), diff --git a/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java b/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java index 4c11da3b697..d141ef6c73e 100644 --- a/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java +++ b/controller-api/src/test/java/com/yahoo/vespa/hosted/controller/api/role/RoleTest.java @@ -17,7 +17,7 @@ import static org.junit.Assert.assertTrue; public class RoleTest { private static final Enforcer mainEnforcer = new Enforcer(SystemName.main); - private static final Enforcer vaasEnforcer = new Enforcer(SystemName.vaas); + private static final Enforcer publicEnforcer = new Enforcer(SystemName.Public); @Test public void operator_membership() { @@ -40,18 +40,18 @@ public class RoleTest { assertTrue(mainEnforcer.allows(role, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); Role publicSystem = Role.athenzTenantAdmin(TenantName.from("t1")); - assertFalse(vaasEnforcer.allows(publicSystem, Action.read, URI.create("/controller/v1/foo"))); - assertTrue(vaasEnforcer.allows(publicSystem, Action.read, URI.create("/badge/v1/badge"))); - assertTrue(vaasEnforcer.allows(publicSystem, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); + assertFalse(publicEnforcer.allows(publicSystem, Action.read, URI.create("/controller/v1/foo"))); + assertTrue(publicEnforcer.allows(publicSystem, Action.read, URI.create("/badge/v1/badge"))); + assertTrue(publicEnforcer.allows(publicSystem, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); } @Test public void build_service_membership() { Role role = Role.tenantPipeline(TenantName.from("t1"), ApplicationName.from("a1")); - assertFalse(vaasEnforcer.allows(role, Action.create, URI.create("/not/explicitly/defined"))); - assertFalse(vaasEnforcer.allows(role, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); - assertTrue(vaasEnforcer.allows(role, Action.create, URI.create("/application/v4/tenant/t1/application/a1/jobreport"))); - assertFalse("No global read access", vaasEnforcer.allows(role, Action.read, URI.create("/controller/v1/foo"))); + assertFalse(publicEnforcer.allows(role, Action.create, URI.create("/not/explicitly/defined"))); + assertFalse(publicEnforcer.allows(role, Action.update, URI.create("/application/v4/tenant/t1/application/a1"))); + assertTrue(publicEnforcer.allows(role, Action.create, URI.create("/application/v4/tenant/t1/application/a1/jobreport"))); + assertFalse("No global read access", publicEnforcer.allows(role, Action.read, URI.create("/controller/v1/foo"))); } @Test diff --git a/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/application/Endpoint.java b/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/application/Endpoint.java index 6c9b8dd0784..5026ca75a83 100644 --- a/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/application/Endpoint.java +++ b/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/application/Endpoint.java @@ -152,7 +152,6 @@ public class Endpoint { if (legacy) return YAHOO_DNS_SUFFIX; return OATH_DNS_SUFFIX; case Public: - case vaas: return PUBLIC_DNS_SUFFIX; case PublicCd: return PUBLIC_CD_DNS_SUFFIX; diff --git a/hosted-api/src/main/java/ai/vespa/hosted/api/ControllerHttpClient.java b/hosted-api/src/main/java/ai/vespa/hosted/api/ControllerHttpClient.java index 421d946c5db..d59eb166e2b 100644 --- a/hosted-api/src/main/java/ai/vespa/hosted/api/ControllerHttpClient.java +++ b/hosted-api/src/main/java/ai/vespa/hosted/api/ControllerHttpClient.java @@ -201,9 +201,8 @@ public abstract class ControllerHttpClient { + URLEncoder.encode(name, UTF_8) + "=" + URLEncoder.encode(value, UTF_8)); } - // TODO jvenstad: remove when vaas is no longer part of region names. private static String jobNameOf(ZoneId zone) { - return zone.environment().value() + "-" + zone.region().value().replaceAll("vaas-", ""); + return zone.environment().value() + "-" + zone.region().value(); } private HttpResponse send(HttpRequest request) { -- cgit v1.2.3 From f5a7023f55b354e8d3985cf36ea331eb765180e1 Mon Sep 17 00:00:00 2001 From: Jon Marius Venstad Date: Tue, 11 Jun 2019 16:08:21 +0200 Subject: Expose routing endpoints per cluster in RoutingGenerator --- .../controller/api/integration/routing/RoutingGenerator.java | 7 +++++++ .../hosted/controller/integration/RoutingGeneratorMock.java | 11 +++++++++++ 2 files changed, 18 insertions(+) (limited to 'controller-api') diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/routing/RoutingGenerator.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/routing/RoutingGenerator.java index 276e19da8f6..f5c82018ac6 100644 --- a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/routing/RoutingGenerator.java +++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/routing/RoutingGenerator.java @@ -1,9 +1,12 @@ // Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. package com.yahoo.vespa.hosted.controller.api.integration.routing; +import com.yahoo.config.provision.ClusterSpec; import com.yahoo.vespa.hosted.controller.api.identifiers.DeploymentId; +import java.net.URI; import java.util.List; +import java.util.Map; /** * @author bratseth @@ -16,4 +19,8 @@ public interface RoutingGenerator { * @return List of endpoints for that deploymentId */ List endpoints(DeploymentId deploymentId); + + /** Returns the endpoints of each cluster in the given deployment — nothing global. */ + Map clusterEndpoints(DeploymentId deploymentId); + } diff --git a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/RoutingGeneratorMock.java b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/RoutingGeneratorMock.java index 410d7950e97..98b2dd2f7f3 100644 --- a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/RoutingGeneratorMock.java +++ b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/RoutingGeneratorMock.java @@ -1,14 +1,17 @@ // Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. package com.yahoo.vespa.hosted.controller.integration; +import com.yahoo.config.provision.ClusterSpec; import com.yahoo.vespa.hosted.controller.api.identifiers.DeploymentId; import com.yahoo.vespa.hosted.controller.api.integration.routing.RoutingEndpoint; import com.yahoo.vespa.hosted.controller.api.integration.routing.RoutingGenerator; +import java.net.URI; import java.util.Collections; import java.util.List; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; +import java.util.stream.Collectors; /** * Returns a default set of endpoints on every query if it has no mappings, or those added by the user, otherwise. @@ -34,6 +37,14 @@ public class RoutingGeneratorMock implements RoutingGenerator { : routingTable.getOrDefault(deployment, Collections.emptyList()); } + @Override + public Map clusterEndpoints(DeploymentId deployment) { + return endpoints(deployment).stream() + .limit(1) + .collect(Collectors.toMap(__ -> ClusterSpec.Id.from("default"), + endpoint -> URI.create(endpoint.endpoint()))); + } + public void putEndpoints(DeploymentId deployment, List endpoints) { routingTable.put(deployment, endpoints); } -- cgit v1.2.3 From 85badff5f9bc6c9cc5eb441dc2a5bfda88bb4d4b Mon Sep 17 00:00:00 2001 From: Martin Polden Date: Thu, 13 Jun 2019 10:43:40 +0200 Subject: Remove artificial distinction between cnames and rotation names --- .../api/integration/configserver/ConfigServer.java | 2 +- .../hosted/controller/ApplicationController.java | 24 ++++++++++------------ .../vespa/hosted/controller/ControllerTest.java | 2 +- .../controller/integration/ConfigServerMock.java | 11 +++++----- 4 files changed, 18 insertions(+), 21 deletions(-) (limited to 'controller-api') diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java index 03b3d586b73..0c6bee4073d 100644 --- a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java +++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java @@ -31,7 +31,7 @@ public interface ConfigServer { PrepareResponse prepareResponse(); } - PreparedApplication deploy(DeploymentId deployment, DeployOptions deployOptions, Set rotationCnames, Set rotationNames, byte[] content); + PreparedApplication deploy(DeploymentId deployment, DeployOptions deployOptions, Set rotationNames, byte[] content); void restart(DeploymentId deployment, Optional hostname); diff --git a/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/ApplicationController.java b/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/ApplicationController.java index e0a73d994d1..72ab32280f5 100644 --- a/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/ApplicationController.java +++ b/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/ApplicationController.java @@ -208,7 +208,7 @@ public class ApplicationController { return findGlobalEndpoint(deployment).map(endpoint -> { try { EndpointStatus status = configServer.getGlobalRotationStatus(deployment, endpoint.upstreamName()); - return Collections.singletonMap(endpoint, status); + return Map.of(endpoint, status); } catch (IOException e) { throw new UncheckedIOException("Failed to get rotation status of " + deployment, e); } @@ -284,7 +284,6 @@ public class ApplicationController { ApplicationVersion applicationVersion; ApplicationPackage applicationPackage; Set rotationNames = new HashSet<>(); - Set cnames; try (Lock lock = lock(applicationId)) { LockedApplication application = new LockedApplication(require(applicationId), lock); @@ -326,9 +325,9 @@ public class ApplicationController { application = withRotation(application, zone); Application app = application.get(); // Include global DNS names - cnames = app.endpointsIn(controller.system()).asList().stream().map(Endpoint::dnsName).collect(Collectors.toSet()); + app.endpointsIn(controller.system()).asList().stream().map(Endpoint::dnsName).forEach(rotationNames::add); // Include rotation ID to ensure that deployment can respond to health checks with rotation ID as Host header - app.rotations().stream().map(RotationId::asString).forEach(cnames::add); + app.rotations().stream().map(RotationId::asString).forEach(rotationNames::add); // Update application with information from application package if ( ! preferOldestVersion @@ -340,7 +339,7 @@ public class ApplicationController { // Carry out deployment without holding the application lock. options = withVersion(platformVersion, options); - ActivateResult result = deploy(applicationId, applicationPackage, zone, options, rotationNames, cnames); + ActivateResult result = deploy(applicationId, applicationPackage, zone, options, rotationNames); lockOrThrow(applicationId, application -> store(application.withNewDeployment(zone, applicationVersion, platformVersion, clock.instant(), @@ -407,7 +406,7 @@ public class ApplicationController { artifactRepository.getSystemApplicationPackage(application.id(), zone, version) ); DeployOptions options = withVersion(version, DeployOptions.none()); - return deploy(application.id(), applicationPackage, zone, options, Set.of(), Set.of()); + return deploy(application.id(), applicationPackage, zone, options, Set.of()); } else { throw new RuntimeException("This system application does not have an application package: " + application.id().toShortString()); } @@ -415,16 +414,15 @@ public class ApplicationController { /** Deploys the given tester application to the given zone. */ public ActivateResult deployTester(TesterId tester, ApplicationPackage applicationPackage, ZoneId zone, DeployOptions options) { - return deploy(tester.id(), applicationPackage, zone, options, Collections.emptySet(), Collections.emptySet()); + return deploy(tester.id(), applicationPackage, zone, options, Set.of()); } private ActivateResult deploy(ApplicationId application, ApplicationPackage applicationPackage, ZoneId zone, DeployOptions deployOptions, - Set rotationNames, Set cnames) { + Set rotationNames) { DeploymentId deploymentId = new DeploymentId(application, zone); ConfigServer.PreparedApplication preparedApplication = - configServer.deploy(deploymentId, deployOptions, cnames, rotationNames, - applicationPackage.zippedContent()); + configServer.deploy(deploymentId, deployOptions, rotationNames, applicationPackage.zippedContent()); // Refresh routing policies on successful deployment. At this point we can safely assume that the config server // has allocated load balancers for the deployment. @@ -468,8 +466,8 @@ public class ApplicationController { logEntry.message = "Ignoring deployment of application '" + application + "' to " + zone + " as a deployment is not currently expected"; PrepareResponse prepareResponse = new PrepareResponse(); - prepareResponse.log = Collections.singletonList(logEntry); - prepareResponse.configChangeActions = new ConfigChangeActions(Collections.emptyList(), Collections.emptyList()); + prepareResponse.log = List.of(logEntry); + prepareResponse.configChangeActions = new ConfigChangeActions(List.of(), List.of()); return new ActivateResult(new RevisionId("0"), prepareResponse, 0); } @@ -780,7 +778,7 @@ public class ApplicationController { if (!"warn".equalsIgnoreCase(log.level) && !"warning".equalsIgnoreCase(log.level)) continue; warnings.merge(DeploymentMetrics.Warning.all, 1, Integer::sum); } - return Collections.unmodifiableMap(warnings); + return Map.copyOf(warnings); } } diff --git a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/ControllerTest.java b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/ControllerTest.java index 3fca94ef21f..de31f1f67f9 100644 --- a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/ControllerTest.java +++ b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/ControllerTest.java @@ -293,7 +293,7 @@ public class ControllerTest { "app1--tenant1.global.vespa.oath.cloud", "app1.tenant1.global.vespa.yahooapis.com", "app1--tenant1.global.vespa.yahooapis.com"), - tester.configServer().rotationCnames().get(new DeploymentId(application.id(), deployment.zone()))); + tester.configServer().rotationNames().get(new DeploymentId(application.id(), deployment.zone()))); } tester.flushDnsRequests(); assertEquals(3, tester.controllerTester().nameService().records().size()); diff --git a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java index 1894a51adc3..cb39e066e16 100644 --- a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java +++ b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java @@ -59,7 +59,7 @@ public class ConfigServerMock extends AbstractComponent implements ConfigServer private final Set suspendedApplications = new HashSet<>(); private final Map> loadBalancers = new HashMap<>(); private final Map> warnings = new HashMap<>(); - private final Map> rotationCnames = new HashMap<>(); + private final Map> rotationNames = new HashMap<>(); private Version lastPrepareVersion = null; private RuntimeException prepareException = null; @@ -180,8 +180,8 @@ public class ConfigServerMock extends AbstractComponent implements ConfigServer warnings.put(deployment, List.copyOf(logs)); } - public Map> rotationCnames() { - return Collections.unmodifiableMap(rotationCnames); + public Map> rotationNames() { + return Collections.unmodifiableMap(rotationNames); } @Override @@ -223,8 +223,7 @@ public class ConfigServerMock extends AbstractComponent implements ConfigServer } @Override - public PreparedApplication deploy(DeploymentId deployment, DeployOptions deployOptions, Set rotationCnames, - Set rotationNames, byte[] content) { + public PreparedApplication deploy(DeploymentId deployment, DeployOptions deployOptions, Set rotationNames, byte[] content) { lastPrepareVersion = deployOptions.vespaVersion.map(Version::fromString).orElse(null); if (prepareException != null) { RuntimeException prepareException = this.prepareException; @@ -236,7 +235,7 @@ public class ConfigServerMock extends AbstractComponent implements ConfigServer if (nodeRepository().list(deployment.zoneId(), deployment.applicationId()).isEmpty()) provision(deployment.zoneId(), deployment.applicationId()); - this.rotationCnames.put(deployment, Set.copyOf(rotationCnames)); + this.rotationNames.put(deployment, Set.copyOf(rotationNames)); return new PreparedApplication() { -- cgit v1.2.3 From c3fe12576146bde732a98495fb9b6fa87b6275e1 Mon Sep 17 00:00:00 2001 From: Harald Musum Date: Thu, 13 Jun 2019 14:23:53 +0200 Subject: Prepare for removing unused methods, change to be empty default methods --- .../api/integration/configserver/ConfigServer.java | 4 +- .../controller/integration/ConfigServerMock.java | 87 ++++++++-------------- 2 files changed, 34 insertions(+), 57 deletions(-) (limited to 'controller-api') diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java index 0c6bee4073d..68711e25958 100644 --- a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java +++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java @@ -26,8 +26,8 @@ public interface ConfigServer { interface PreparedApplication { // TODO: Remove the two methods below - void activate(); - List messages(); + default void activate() {} + default List messages() { return List.of(); } PrepareResponse prepareResponse(); } diff --git a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java index cb39e066e16..2b9296d21cf 100644 --- a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java +++ b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java @@ -237,62 +237,39 @@ public class ConfigServerMock extends AbstractComponent implements ConfigServer this.rotationNames.put(deployment, Set.copyOf(rotationNames)); - return new PreparedApplication() { - - // TODO: Remove when no longer part of interface - public void activate() {} - - // TODO: Remove when no longer part of interface - public List messages() { - Log warning = new Log(); - warning.level = "WARNING"; - warning.time = 1; - warning.message = "The warning"; - - Log info = new Log(); - info.level = "INFO"; - info.time = 2; - info.message = "The info"; - - return List.of(warning, info); + return () -> { + Application application = applications.get(deployment.applicationId()); + application.activate(); + List nodes = nodeRepository.list(deployment.zoneId(), deployment.applicationId()); + for (Node node : nodes) { + nodeRepository.putByHostname(deployment.zoneId(), new Node(node.hostname(), + Node.State.active, + node.type(), + node.owner(), + node.currentVersion(), + application.version().get())); } - - @Override - public PrepareResponse prepareResponse() { - Application application = applications.get(deployment.applicationId()); - application.activate(); - List nodes = nodeRepository.list(deployment.zoneId(), deployment.applicationId()); - for (Node node : nodes) { - nodeRepository.putByHostname(deployment.zoneId(), new Node(node.hostname(), - Node.State.active, - node.type(), - node.owner(), - node.currentVersion(), - application.version().get())); - } - serviceStatus.put(deployment, new ServiceConvergence(deployment.applicationId(), - deployment.zoneId(), - false, - 2, - nodes.stream() - .map(node -> new ServiceConvergence.Status(node.hostname(), - 43, - "container", - 1)) - .collect(Collectors.toList()))); - - PrepareResponse prepareResponse = new PrepareResponse(); - prepareResponse.message = "foo"; - prepareResponse.configChangeActions = configChangeActions != null - ? configChangeActions - : new ConfigChangeActions(Collections.emptyList(), - Collections.emptyList()); - setConfigChangeActions(null); - prepareResponse.tenant = new TenantId("tenant"); - prepareResponse.log = warnings.getOrDefault(deployment, Collections.emptyList()); - return prepareResponse; - } - + serviceStatus.put(deployment, new ServiceConvergence(deployment.applicationId(), + deployment.zoneId(), + false, + 2, + nodes.stream() + .map(node -> new ServiceConvergence.Status(node.hostname(), + 43, + "container", + 1)) + .collect(Collectors.toList()))); + + PrepareResponse prepareResponse = new PrepareResponse(); + prepareResponse.message = "foo"; + prepareResponse.configChangeActions = configChangeActions != null + ? configChangeActions + : new ConfigChangeActions(Collections.emptyList(), + Collections.emptyList()); + setConfigChangeActions(null); + prepareResponse.tenant = new TenantId("tenant"); + prepareResponse.log = warnings.getOrDefault(deployment, Collections.emptyList()); + return prepareResponse; }; } -- cgit v1.2.3 From 33c29c4faea7762e53cb5a6491ae446944c08e2a Mon Sep 17 00:00:00 2001 From: Martin Polden Date: Thu, 13 Jun 2019 14:34:19 +0200 Subject: Add support for containerEndpoints deploy parameter --- .../api/integration/configserver/ConfigServer.java | 3 +- .../configserver/ContainerEndpoint.java | 59 ++++++++++++++++++++++ .../hosted/controller/ApplicationController.java | 3 +- .../controller/integration/ConfigServerMock.java | 4 +- 4 files changed, 65 insertions(+), 4 deletions(-) create mode 100644 controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ContainerEndpoint.java (limited to 'controller-api') diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java index 0c6bee4073d..cfd1ba8d9ed 100644 --- a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java +++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java @@ -31,7 +31,8 @@ public interface ConfigServer { PrepareResponse prepareResponse(); } - PreparedApplication deploy(DeploymentId deployment, DeployOptions deployOptions, Set rotationNames, byte[] content); + PreparedApplication deploy(DeploymentId deployment, DeployOptions deployOptions, Set rotationNames, + List containerEndpoints, byte[] content); void restart(DeploymentId deployment, Optional hostname); diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ContainerEndpoint.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ContainerEndpoint.java new file mode 100644 index 00000000000..2134320bdc1 --- /dev/null +++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ContainerEndpoint.java @@ -0,0 +1,59 @@ +// Copyright 2019 Oath Inc. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +package com.yahoo.vespa.hosted.controller.api.integration.configserver; + +import java.util.List; +import java.util.Objects; + +/** + * This represents a list of one or more names for a container cluster. + * + * @author mpolden + */ +public class ContainerEndpoint { + + private final String clusterId; + private final List names; + + public ContainerEndpoint(String clusterId, List names) { + this.clusterId = nonEmpty(clusterId, "message must be non-empty"); + this.names = List.copyOf(Objects.requireNonNull(names, "names must be non-null")); + } + + /** ID of the cluster to which this points */ + public String clusterId() { + return clusterId; + } + + /** + * All valid DNS names for this endpoint. This can contain both proper DNS names and synthetic identifiers used for + * routing, such as a Host header value that is not necessarily a proper DNS name. + */ + public List names() { + return names; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + ContainerEndpoint that = (ContainerEndpoint) o; + return clusterId.equals(that.clusterId) && + names.equals(that.names); + } + + @Override + public int hashCode() { + return Objects.hash(clusterId, names); + } + + @Override + public String toString() { + return "container endpoint for " + clusterId + " " + names; + } + + private static String nonEmpty(String s, String message) { + if (s == null || s.isBlank()) throw new IllegalArgumentException(message); + return s; + } + +} diff --git a/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/ApplicationController.java b/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/ApplicationController.java index c1a92ca0abd..0b9349b67a9 100644 --- a/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/ApplicationController.java +++ b/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/ApplicationController.java @@ -90,7 +90,6 @@ import java.util.Optional; import java.util.Set; import java.util.TreeMap; import java.util.function.Consumer; -import java.util.function.Predicate; import java.util.logging.Level; import java.util.logging.Logger; import java.util.stream.Collectors; @@ -426,7 +425,7 @@ public class ApplicationController { Set rotationNames) { DeploymentId deploymentId = new DeploymentId(application, zone); ConfigServer.PreparedApplication preparedApplication = - configServer.deploy(deploymentId, deployOptions, rotationNames, applicationPackage.zippedContent()); + configServer.deploy(deploymentId, deployOptions, rotationNames, List.of(), applicationPackage.zippedContent()); // Refresh routing policies on successful deployment. At this point we can safely assume that the config server // has allocated load balancers for the deployment. diff --git a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java index cb39e066e16..f70154d8f8c 100644 --- a/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java +++ b/controller-server/src/test/java/com/yahoo/vespa/hosted/controller/integration/ConfigServerMock.java @@ -16,6 +16,7 @@ import com.yahoo.vespa.hosted.controller.api.identifiers.Hostname; import com.yahoo.vespa.hosted.controller.api.identifiers.Identifier; import com.yahoo.vespa.hosted.controller.api.identifiers.TenantId; import com.yahoo.vespa.hosted.controller.api.integration.configserver.ConfigServer; +import com.yahoo.vespa.hosted.controller.api.integration.configserver.ContainerEndpoint; import com.yahoo.vespa.hosted.controller.api.integration.configserver.LoadBalancer; import com.yahoo.vespa.hosted.controller.api.integration.configserver.Log; import com.yahoo.vespa.hosted.controller.api.integration.configserver.Node; @@ -223,7 +224,8 @@ public class ConfigServerMock extends AbstractComponent implements ConfigServer } @Override - public PreparedApplication deploy(DeploymentId deployment, DeployOptions deployOptions, Set rotationNames, byte[] content) { + public PreparedApplication deploy(DeploymentId deployment, DeployOptions deployOptions, Set rotationNames, + List containerEndpoints, byte[] content) { lastPrepareVersion = deployOptions.vespaVersion.map(Version::fromString).orElse(null); if (prepareException != null) { RuntimeException prepareException = this.prepareException; -- cgit v1.2.3 From df9795aaaf4a13270d2f3f3487ed0792788f8127 Mon Sep 17 00:00:00 2001 From: Harald Musum Date: Fri, 14 Jun 2019 11:20:53 +0200 Subject: Remove unused methods --- .../hosted/controller/api/integration/configserver/ConfigServer.java | 3 --- 1 file changed, 3 deletions(-) (limited to 'controller-api') diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java index 56d05f3ce9d..20469e6449a 100644 --- a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java +++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServer.java @@ -25,9 +25,6 @@ import java.util.Set; public interface ConfigServer { interface PreparedApplication { - // TODO: Remove the two methods below - default void activate() {} - default List messages() { return List.of(); } PrepareResponse prepareResponse(); } -- cgit v1.2.3