diff options
3 files changed, 21 insertions, 18 deletions
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 84d18350993..ee30f6fd471 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 @@ -434,15 +434,16 @@ public abstract class ControllerHttpClient { private static DeploymentLog.Status valueOf(String status) { switch (status) { - case "running": return DeploymentLog.Status.running; - case "aborted": return DeploymentLog.Status.aborted; - case "error": return DeploymentLog.Status.error; - case "testFailure": return DeploymentLog.Status.testFailure; - case "outOfCapacity": return DeploymentLog.Status.outOfCapacity; - case "installationFailed": return DeploymentLog.Status.installationFailed; - case "deploymentFailed": return DeploymentLog.Status.deploymentFailed; - case "success": return DeploymentLog.Status.success; - default: throw new IllegalArgumentException("Unexpected status '" + status + "'"); + case "running": return DeploymentLog.Status.running; + case "aborted": return DeploymentLog.Status.aborted; + case "error": return DeploymentLog.Status.error; + case "testFailure": return DeploymentLog.Status.testFailure; + case "outOfCapacity": return DeploymentLog.Status.outOfCapacity; + case "installationFailed": return DeploymentLog.Status.installationFailed; + case "deploymentFailed": return DeploymentLog.Status.deploymentFailed; + case "endpointCertificateTimeout": return DeploymentLog.Status.endpointCertificateTimeout; + case "success": return DeploymentLog.Status.success; + default: throw new IllegalArgumentException("Unexpected status '" + status + "'"); } } diff --git a/hosted-api/src/main/java/ai/vespa/hosted/api/DeploymentLog.java b/hosted-api/src/main/java/ai/vespa/hosted/api/DeploymentLog.java index 9eae9a33cff..90e973da49d 100644 --- a/hosted-api/src/main/java/ai/vespa/hosted/api/DeploymentLog.java +++ b/hosted-api/src/main/java/ai/vespa/hosted/api/DeploymentLog.java @@ -112,6 +112,7 @@ public class DeploymentLog { outOfCapacity, installationFailed, deploymentFailed, + endpointCertificateTimeout, success; } diff --git a/vespa-maven-plugin/src/main/java/ai/vespa/hosted/plugin/DeployMojo.java b/vespa-maven-plugin/src/main/java/ai/vespa/hosted/plugin/DeployMojo.java index cc714f38290..a798c2ad6df 100644 --- a/vespa-maven-plugin/src/main/java/ai/vespa/hosted/plugin/DeployMojo.java +++ b/vespa-maven-plugin/src/main/java/ai/vespa/hosted/plugin/DeployMojo.java @@ -62,15 +62,16 @@ public class DeployMojo extends AbstractVespaDeploymentMojo { private void tailLogs(ApplicationId id, ZoneId zone, long run) throws MojoFailureException, MojoExecutionException { DeploymentLog log = controller.followDeploymentUntilDone(id, zone, run, this::print); switch (log.status()) { - case success: return; - case error: throw new MojoExecutionException("Unexpected error during deployment; see log for details"); - case aborted: throw new MojoFailureException("Deployment was aborted, probably by a newer deployment"); - case outOfCapacity: throw new MojoFailureException("No capacity left in zone; please contact the Vespa team"); - case deploymentFailed: throw new MojoFailureException("Deployment failed; see log for details"); - case installationFailed: throw new MojoFailureException("Installation failed; see Vespa log for details"); - case running: throw new MojoFailureException("Deployment not completed"); - case testFailure: throw new IllegalStateException("Unexpected status; tests are not run for manual deployments"); - default: throw new IllegalArgumentException("Unexpected status '" + log.status() + "'"); + case success: return; + case error: throw new MojoExecutionException("Unexpected error during deployment; see log for details"); + case aborted: throw new MojoFailureException("Deployment was aborted, probably by a newer deployment"); + case outOfCapacity: throw new MojoFailureException("No capacity left in zone; please contact the Vespa team"); + case deploymentFailed: throw new MojoFailureException("Deployment failed; see log for details"); + case installationFailed: throw new MojoFailureException("Installation failed; see Vespa log for details"); + case running: throw new MojoFailureException("Deployment not completed"); + case endpointCertificateTimeout: throw new MojoFailureException("Endpoint certificate not ready in time; please contact Vespa team"); + case testFailure: throw new IllegalStateException("Unexpected status; tests are not run for manual deployments"); + default: throw new IllegalArgumentException("Unexpected status '" + log.status() + "'"); } } |