summaryrefslogtreecommitdiffstats
path: root/orchestrator
diff options
context:
space:
mode:
authorHåkon Hallingstad <hakon@oath.com>2018-06-21 14:33:56 +0200
committerHåkon Hallingstad <hakon@oath.com>2018-06-21 14:33:56 +0200
commit9669d70f775f5502b7252a390824a99a59a973fe (patch)
treed37e3b16b09d68af1ca7c95382f700d76f06b7b9 /orchestrator
parent3b3920201ae893730e78fb1211f292233014d4df (diff)
Use UncheckedTimeoutException from guava
Diffstat (limited to 'orchestrator')
-rw-r--r--orchestrator/src/main/java/com/yahoo/vespa/orchestrator/OrchestratorContext.java3
-rw-r--r--orchestrator/src/main/java/com/yahoo/vespa/orchestrator/controller/ClusterControllerClient.java6
2 files changed, 5 insertions, 4 deletions
diff --git a/orchestrator/src/main/java/com/yahoo/vespa/orchestrator/OrchestratorContext.java b/orchestrator/src/main/java/com/yahoo/vespa/orchestrator/OrchestratorContext.java
index 8c9e624c8ff..880eab0c755 100644
--- a/orchestrator/src/main/java/com/yahoo/vespa/orchestrator/OrchestratorContext.java
+++ b/orchestrator/src/main/java/com/yahoo/vespa/orchestrator/OrchestratorContext.java
@@ -1,6 +1,7 @@
// Copyright 2018 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.vespa.orchestrator;
+import com.google.common.util.concurrent.UncheckedTimeoutException;
import com.yahoo.time.TimeBudget;
import java.time.Clock;
@@ -28,7 +29,7 @@ public class OrchestratorContext {
/**
* Get number of seconds until the deadline, or empty if there's no deadline, or throw
- * an TimeoutException if timed out.
+ * an {@link UncheckedTimeoutException} if timed out.
*/
public Optional<Float> getSuboperationTimeoutInSeconds() {
return Optional.of((float) (timeBudget.timeLeftOrThrow().toMillis() / 1000.0));
diff --git a/orchestrator/src/main/java/com/yahoo/vespa/orchestrator/controller/ClusterControllerClient.java b/orchestrator/src/main/java/com/yahoo/vespa/orchestrator/controller/ClusterControllerClient.java
index 45d258241cf..15ae69b3a0d 100644
--- a/orchestrator/src/main/java/com/yahoo/vespa/orchestrator/controller/ClusterControllerClient.java
+++ b/orchestrator/src/main/java/com/yahoo/vespa/orchestrator/controller/ClusterControllerClient.java
@@ -1,7 +1,7 @@
// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.vespa.orchestrator.controller;
-import com.yahoo.time.TimeoutException;
+import com.google.common.util.concurrent.UncheckedTimeoutException;
import com.yahoo.vespa.orchestrator.OrchestratorContext;
import java.io.IOException;
@@ -15,7 +15,7 @@ public interface ClusterControllerClient {
* Requests that a cluster controller sets the requested node to the requested state.
*
* @throws IOException if there was a problem communicating with the cluster controller
- * @throws TimeoutException if operation times out
+ * @throws UncheckedTimeoutException if operation times out
*/
ClusterControllerStateResponse setNodeState(OrchestratorContext context, int storageNodeIndex, ClusterControllerNodeState wantedState) throws IOException;
@@ -23,7 +23,7 @@ public interface ClusterControllerClient {
* Requests that a cluster controller sets all nodes in the cluster to the requested state.
*
* @throws IOException if there was a problem communicating with the cluster controller
- * @throws TimeoutException if operation times out
+ * @throws UncheckedTimeoutException if operation times out
*/
ClusterControllerStateResponse setApplicationState(OrchestratorContext context, ClusterControllerNodeState wantedState) throws IOException;