Skip to content

Commit 30586c3

Browse files
author
NerdyNick
committed
dropwizard#783 - Report HealthCheck as unhealthy on exception
1 parent c6a6c0c commit 30586c3

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

metrics-healthchecks/src/main/java/com/codahale/metrics/health/HealthCheckRegistry.java

+1
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ public Result call() throws Exception {
102102
results.put(entry.getKey(), entry.getValue().get());
103103
} catch (Exception e) {
104104
LOGGER.warn("Error executing health check {}", entry.getKey(), e);
105+
results.put(entry.getKey(), HealthCheck.Result.unhealthy(e));
105106
}
106107
}
107108
return Collections.unmodifiableSortedMap(results);

0 commit comments

Comments
 (0)