You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Georg Henzler (Jira)" <ji...@apache.org> on 2020/10/08 09:24:00 UTC

[jira] [Commented] (FELIX-6344) HealthCheckExecutor can run into endless failures in case a health check throws a java Error

    [ https://issues.apache.org/jira/browse/FELIX-6344?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17210099#comment-17210099 ] 

Georg Henzler commented on FELIX-6344:
--------------------------------------

[~cschneider] yes, catching the more generic Throwable here is better/safer to ensure {{callback.finished(executionResult)}} is called.

> HealthCheckExecutor can run into endless failures in case a health check throws a java Error
> --------------------------------------------------------------------------------------------
>
>                 Key: FELIX-6344
>                 URL: https://issues.apache.org/jira/browse/FELIX-6344
>             Project: Felix
>          Issue Type: Bug
>          Components: Health Checks
>    Affects Versions: healthcheck.core 2.0.8
>            Reporter: Christian Schneider
>            Priority: Major
>             Fix For: healthcheck.core 2.0.10
>
>
> We had this exception happening on a system every few seconds:
> [https://gist.github.com/cschneider/2840339f86faf5a46d2a8a94f0617e76]
> The root cause was an error in class loading which resulted in the DsComponentsCheck running into a java Error.  
> The problem then was that the finish method in the FutureTask was never called and so the future always stayed in the list of futures to check and always returned the Error again.
>  
> I supected that we simply should catch Throwable in the code below:
> https://github.com/apache/felix-dev/blob/master/healthcheck/core/src/main/java/org/apache/felix/hc/core/impl/executor/HealthCheckFuture.java#L75



--
This message was sent by Atlassian Jira
(v8.3.4#803005)