summaryrefslogtreecommitdiffstats
path: root/zkfacade
diff options
context:
space:
mode:
Diffstat (limited to 'zkfacade')
-rw-r--r--zkfacade/src/main/java/com/yahoo/vespa/curator/CuratorCompletionWaiter.java14
1 files changed, 13 insertions, 1 deletions
diff --git a/zkfacade/src/main/java/com/yahoo/vespa/curator/CuratorCompletionWaiter.java b/zkfacade/src/main/java/com/yahoo/vespa/curator/CuratorCompletionWaiter.java
index 69923c25998..7d9cbf3f41c 100644
--- a/zkfacade/src/main/java/com/yahoo/vespa/curator/CuratorCompletionWaiter.java
+++ b/zkfacade/src/main/java/com/yahoo/vespa/curator/CuratorCompletionWaiter.java
@@ -4,6 +4,7 @@ package com.yahoo.vespa.curator;
import com.yahoo.log.LogLevel;
import com.yahoo.path.Path;
import org.apache.curator.framework.CuratorFramework;
+import org.apache.zookeeper.KeeperException;
import java.time.Clock;
import java.time.Duration;
@@ -74,7 +75,18 @@ class CuratorCompletionWaiter implements Curator.CompletionWaiter {
}
private void notifyInternal() throws Exception {
- curator.create().forPath(myId);
+ try {
+ curator.create().forPath(myId);
+ } catch (RuntimeException e) {
+ // Throw only if we get something else than NoNodeException -- NoNodeException might happen when
+ // an application have been deleted and this method has not been called yet for the previous deployment
+ // on a minority of the config servers (see awaitInternal() method in this class)
+ if (e.getCause().getClass() != KeeperException.NoNodeException.class) {
+ throw e;
+ } else {
+ log.log(LogLevel.INFO, "Not able to notify completion at path: " + myId +", node has been deleted");
+ }
+ }
}
@Override