diff options
author | Harald Musum <musum@yahooinc.com> | 2023-04-13 15:06:07 +0200 |
---|---|---|
committer | Harald Musum <musum@yahooinc.com> | 2023-04-13 15:06:07 +0200 |
commit | f95354bf26d37b9cca812d49c10e3f8d95899c5d (patch) | |
tree | 249ae7c5baff0b36bce99a522f3d4f551807deb5 /controller-server | |
parent | 1406f2c7124198e4fe05650719a9d33d2737d5b3 (diff) |
Add link to doc for exception when plan does not support deployment
Diffstat (limited to 'controller-server')
2 files changed, 4 insertions, 3 deletions
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 80098ff8ca9..08a8440fbe2 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 @@ -1064,10 +1064,10 @@ public class ApplicationController { var planId = controller.serviceRegistry().billingController().getPlan(tenantName); Optional<Plan> plan = controller.serviceRegistry().planRegistry().plan(planId); if (plan.isEmpty()) - throw new IllegalArgumentException("Tenant '" + tenantName.value() + "' has no plan, not allowed to deploy"); + throw new IllegalArgumentException("Tenant '" + tenantName.value() + "' has no plan, not allowed to deploy. See https://cloud.vespa.ai/support"); if (plan.get().quota().calculate().equals(Quota.zero())) throw new IllegalArgumentException("Tenant '" + tenantName.value() + "' has a plan '" + - plan.get().displayName() + "' with zero quota, not allowed to deploy"); + plan.get().displayName() + "' with zero quota, not allowed to deploy. See https://cloud.vespa.ai/support"); } } 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 c641aaf0c85..a9a6fe602b6 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 @@ -1523,7 +1523,8 @@ public class ControllerTest { tester.controller().applications().verifyPlan(tenant); fail("should have thrown an exception"); } catch (IllegalArgumentException e) { - assertEquals("Tenant 'tenant' has a plan 'None Plan - for testing purposes' with zero quota, not allowed to deploy", e.getMessage()); + assertEquals("Tenant 'tenant' has a plan 'None Plan - for testing purposes' with zero quota, not allowed to deploy. " + + "See https://cloud.vespa.ai/support", e.getMessage()); } } |