Skip to content

Commit

Permalink
Merge pull request #1066 from grootstebozewolf/noReturnValueForUnhealhty
Browse files Browse the repository at this point in the history
Added return value of unhealthy code path.
  • Loading branch information
Jesse Eichar committed Jun 29, 2015
2 parents 30bca5f + 294afaf commit 457822f
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -29,7 +29,7 @@ protected Result check() throws Exception {
long free = unixMXBean.getMaxFileDescriptorCount() - unixMXBean.getOpenFileDescriptorCount();
double fivePercent = Math.max(2.0, ((double) unixMXBean.getMaxFileDescriptorCount()) * 0.01);
if (free < fivePercent) {
Result.unhealthy("There are insufficient free file handles. Connections free:" + free);
return Result.unhealthy("There are insufficient free file handles. Connections free:" + free);
}
}
return Result.healthy();
Expand Down

0 comments on commit 457822f

Please sign in to comment.