summaryrefslogtreecommitdiffstats
path: root/configserver
diff options
context:
space:
mode:
Diffstat (limited to 'configserver')
-rw-r--r--configserver/src/main/java/com/yahoo/vespa/config/server/ApplicationRepository.java11
1 files changed, 9 insertions, 2 deletions
diff --git a/configserver/src/main/java/com/yahoo/vespa/config/server/ApplicationRepository.java b/configserver/src/main/java/com/yahoo/vespa/config/server/ApplicationRepository.java
index 1aeaebafd84..a78eeb902c0 100644
--- a/configserver/src/main/java/com/yahoo/vespa/config/server/ApplicationRepository.java
+++ b/configserver/src/main/java/com/yahoo/vespa/config/server/ApplicationRepository.java
@@ -476,10 +476,17 @@ public class ApplicationRepository implements com.yahoo.config.provision.Deploye
.flatMap(ApplicationData::lastDeployedSession);
if (lastDeployedSession.isEmpty()) return activationTime(application);
- Instant createTime = getRemoteSession(tenant, lastDeployedSession.get()).getCreateTime();
+ Optional<Instant> createTime;
+ try {
+ createTime = Optional.of(getRemoteSession(tenant, lastDeployedSession.get()).getCreateTime());
+ }
+ catch (Exception e) {
+ // Fallback to activation time, e.g. when last deployment failed before writing session data for new session
+ createTime = activationTime(application);
+ }
log.log(Level.FINEST, application + " last deployed " + createTime);
- return Optional.of(createTime);
+ return createTime;
}
@Override