summaryrefslogtreecommitdiffstats
path: root/controller-api
diff options
context:
space:
mode:
authorHåkon Hallingstad <hakon@verizonmedia.com>2020-01-16 11:41:17 +0100
committerHåkon Hallingstad <hakon@verizonmedia.com>2020-01-16 11:41:17 +0100
commit9b60c77f82fb50f3b115f67ef2c7bac8d5b3ea01 (patch)
tree061d9234e33d04e54bc81e1f6f42d0e58a8e75e9 /controller-api
parent3569aed27599882b26039c7d25a89bce10cbc02b (diff)
Improve deploy messages
Remove misleading prefix of some deploy messages parent-host-not-ready: 0/1 hosts for vespa.album-recommendation.default-t have completed provisioning and bootstrapping, still waiting for h33908.staging.aws-us-east-1c.vespa-external-cd.aws.oath.cloud load-balancer-not-ready: Failed to (re)configure load balancer for CLUSTER in APPLICATION, targeting: REALS. The operation will be retried on next deployment out-of-capacity one of: Could not satisfy request for 3 nodes with... Not enough capacity to start 3 r4.xlarge instances... No host flavor matches [vcpu: 2, memory: ...], nearest matching host flavor...
Diffstat (limited to 'controller-api')
-rw-r--r--controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServerException.java15
1 files changed, 11 insertions, 4 deletions
diff --git a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServerException.java b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServerException.java
index 780969206a2..4240b0d9fa6 100644
--- a/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServerException.java
+++ b/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/ConfigServerException.java
@@ -2,6 +2,7 @@
package com.yahoo.vespa.hosted.controller.api.integration.configserver;
import java.net.URI;
+import java.util.Objects;
/**
* @author Tony Vaagenes
@@ -10,11 +11,13 @@ public class ConfigServerException extends RuntimeException {
private final URI serverUri;
private final ErrorCode errorCode;
+ private final String serverMessage;
- public ConfigServerException(URI serverUri, String message, ErrorCode errorCode, Throwable cause) {
- super(message, cause);
- this.serverUri = serverUri;
- this.errorCode = errorCode;
+ public ConfigServerException(URI serverUri, String context, String serverMessage, ErrorCode errorCode, Throwable cause) {
+ super(context + ": " + serverMessage, cause);
+ this.serverUri = Objects.requireNonNull(serverUri);
+ this.errorCode = Objects.requireNonNull(errorCode);
+ this.serverMessage = Objects.requireNonNull(serverMessage);
}
public ErrorCode getErrorCode() {
@@ -25,6 +28,10 @@ public class ConfigServerException extends RuntimeException {
return serverUri;
}
+ public String getServerMessage() {
+ return serverMessage;
+ }
+
// TODO: Copied from Vespa. Expose these in Vespa and use them here
public enum ErrorCode {
APPLICATION_LOCK_FAILURE,