[ 
https://issues.apache.org/jira/browse/CAMEL-17426?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

James Netherton resolved CAMEL-17426.
-------------------------------------
    Resolution: Fixed

> microprofile healt checks: do not conflate camel checks
> -------------------------------------------------------
>
>                 Key: CAMEL-17426
>                 URL: https://issues.apache.org/jira/browse/CAMEL-17426
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-microprofile-health
>            Reporter: Luca Burgazzoli
>            Assignee: James Netherton
>            Priority: Major
>             Fix For: 3.15.0
>
>
> While running the [camel quarkus healt 
> example|https://github.com/apache/camel-quarkus-examples/tree/main/health], I 
> noticed that the health checks from camel are conflated so as example, the 
> liveness block looks as follow:
> {code:json}
> {
>     "checks": [
>         {
>             "data": {
>                 "consumer:netty": "DOWN",
>                 "consumer:timer": "UP",
>                 "context": "UP",
>                 "context.name": "camel-7",
>                 "context.status": "Started",
>                 "context.version": "3.14.0",
>                 "failure.count": "0",
>                 "invocation.count": "5",
>                 "invocation.time": 
> "2022-01-04T11:32:56.024411+01:00[Europe/Rome]",
>                 "route.context.name": "camel-7",
>                 "route.id": "netty",
>                 "route.status": "Stopped",
>                 "route:netty": "UP",
>                 "route:timer": "UP",
>                 "success.count": "5",
>                 "toolong": "UP"
>             },
>             "name": "camel-readiness-checks",
>             "status": "DOWN"
>         }
>     ],
>     "status": "DOWN"
> }
> {code}
> As you may notice, there are inconsistencies, like, multiple routes are 
> conflated and only the latest one appears: 
> {code:json}
> {
>   "route.id": "netty",
>   "route.status": "Stopped",
>   "route:netty": "UP",
>   "route:timer": "UP"
> }
> {code}
> The issue seems to be cause by the fact that the camel-microprofile-health 
> component does not mirrors the checks from camel but instead it aggregate 
> them (see 
> [AbstractCamelMicroProfileHealthCheck.java|https://github.com/apache/camel/blob/main/components/camel-microprofile/camel-microprofile-health/src/main/java/org/apache/camel/microprofile/health/AbstractCamelMicroProfileHealthCheck.java])
>  
> SmallRye offers a sort of 
> [registry|https://github.com/smallrye/smallrye-health/tree/main/implementation/src/main/java/io/smallrye/health/registry]
>  so we should probably register the camel health checks to the SmallRye 
> registry (this may have the side effect to make the camel-microprofile-health 
> smallrye dependant)
> In addition, it would be nice of SmallRye would allow to discovery registries



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to