Skip to content

Commit d015dc1

Browse files
committed
Hardens getClusterObjectsReport against exceptions when making listClusterObjects requests
1 parent 535dfba commit d015dc1

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

grails-app/services/io/xh/hoist/admin/ClusterObjectsService.groovy

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,9 @@ class ClusterObjectsService extends BaseService {
3232
ClusterObjectsReport getClusterObjectsReport() {
3333
def startTimestamp = currentTimeMillis(),
3434
info = runOnAllInstancesAsJson(this.&listClusterObjects)
35-
.collectMany { parseArray(it.value.value) }
36-
35+
.collectMany { key, value ->
36+
value.exception ? [] : parseArray(value.value as String)
37+
}
3738
return new ClusterObjectsReport(info, startTimestamp, currentTimeMillis())
3839
}
3940

0 commit comments

Comments
 (0)