diff options
author | Håkon Hallingstad <hakon@verizonmedia.com> | 2021-08-17 14:59:45 +0200 |
---|---|---|
committer | Håkon Hallingstad <hakon@verizonmedia.com> | 2021-08-17 14:59:45 +0200 |
commit | 662ab0f5f14f85e5bf7b5d9d50e047aa1da94657 (patch) | |
tree | 67e499b739576244aeef6930a6bc8adbe4d9cac6 /node-repository/src/test/java/com/yahoo | |
parent | 252ed45c65d37440ed8908b0f3d6c78eff159c23 (diff) |
Trigger redeployment of hosted-vespa.routing if there are any ready proxy nodes
Diffstat (limited to 'node-repository/src/test/java/com/yahoo')
-rw-r--r-- | node-repository/src/test/java/com/yahoo/vespa/hosted/provision/maintenance/ExpeditedChangeApplicationMaintainerTest.java | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/node-repository/src/test/java/com/yahoo/vespa/hosted/provision/maintenance/ExpeditedChangeApplicationMaintainerTest.java b/node-repository/src/test/java/com/yahoo/vespa/hosted/provision/maintenance/ExpeditedChangeApplicationMaintainerTest.java index 62d09c99f16..9766ade56c9 100644 --- a/node-repository/src/test/java/com/yahoo/vespa/hosted/provision/maintenance/ExpeditedChangeApplicationMaintainerTest.java +++ b/node-repository/src/test/java/com/yahoo/vespa/hosted/provision/maintenance/ExpeditedChangeApplicationMaintainerTest.java @@ -68,9 +68,15 @@ public class ExpeditedChangeApplicationMaintainerTest { maintainer.maintain(); assertEquals("Operator change -> redeployment", 5, fixture.deployer.redeployments); + clock.advance(Duration.ofSeconds(1)); + fixture.tester.makeReadyNodes(1, fixture.nodeResources, NodeType.proxy); + clock.advance(Duration.ofMinutes(2)); + maintainer.maintain(); + assertEquals("Ready proxy node -> redeployment", 6, fixture.deployer.redeployments); + clock.advance(Duration.ofMinutes(2)); maintainer.maintain(); - assertEquals("No further operator changes -> no (new) redeployments", 5, fixture.deployer.redeployments); + assertEquals("No further operator changes -> no (new) redeployments", 6, fixture.deployer.redeployments); } private static class Fixture { @@ -82,7 +88,7 @@ public class ExpeditedChangeApplicationMaintainerTest { final NodeResources nodeResources = new NodeResources(2, 8, 50, 1); final ApplicationId app1 = ApplicationId.from(TenantName.from("foo1"), ApplicationName.from("bar"), InstanceName.from("fuz")); final ApplicationId app2 = ApplicationId.from(TenantName.from("foo2"), ApplicationName.from("bar"), InstanceName.from("fuz")); - final ApplicationId app3 = ApplicationId.from(TenantName.from("vespa-hosted"), ApplicationName.from("routing"), InstanceName.from("default")); + final ApplicationId app3 = ApplicationId.from(TenantName.from("hosted-vespa"), ApplicationName.from("routing"), InstanceName.from("default")); final ClusterSpec clusterApp1 = ClusterSpec.request(ClusterSpec.Type.container, ClusterSpec.Id.from("test")).vespaVersion("6.42").build(); final ClusterSpec clusterApp2 = ClusterSpec.request(ClusterSpec.Type.content, ClusterSpec.Id.from("test")).vespaVersion("6.42").build(); final ClusterSpec clusterApp3 = ClusterSpec.request(ClusterSpec.Type.content, ClusterSpec.Id.from("routing")).vespaVersion("6.42").build(); |