summaryrefslogtreecommitdiffstats
path: root/controller-server/src
diff options
context:
space:
mode:
authorBjørn Christian Seime <bjorncs@verizonmedia.com>2020-12-03 10:00:37 +0100
committerGitHub <noreply@github.com>2020-12-03 10:00:37 +0100
commit19457390f69bf350079fb7a7054132866e9992d9 (patch)
tree998e61a3dca055585aefad53e5046e29f3e4ca6b /controller-server/src
parent24c54f7e09d4885ed94c191233dc7242b0155b2d (diff)
parentddfa6454f9e7c13fa4e11e4d498fbfedeb8f8c8c (diff)
Merge pull request #15620 from vespa-engine/jonmv/fix-reindexing-responze-parsing
Status for a cluster may be null
Diffstat (limited to 'controller-server/src')
-rw-r--r--controller-server/src/main/java/com/yahoo/vespa/hosted/controller/restapi/application/ApplicationApiHandler.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/restapi/application/ApplicationApiHandler.java b/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/restapi/application/ApplicationApiHandler.java
index 4a6d6e2e72d..cbf6307f5e6 100644
--- a/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/restapi/application/ApplicationApiHandler.java
+++ b/controller-server/src/main/java/com/yahoo/vespa/hosted/controller/restapi/application/ApplicationApiHandler.java
@@ -1576,7 +1576,7 @@ public class ApplicationApiHandler extends LoggingRequestHandler {
.forEach(cluster -> {
Cursor clusterObject = clustersArray.addObject();
clusterObject.setString("name", cluster.getKey());
- setStatus(clusterObject.setObject("status"), cluster.getValue().common());
+ cluster.getValue().common().ifPresent(common -> setStatus(clusterObject.setObject("status"), common));
Cursor pendingArray = clusterObject.setArray("pending");
cluster.getValue().pending().entrySet().stream().sorted(comparingByKey())