// Do not edit directly!
// This file was generated by camel-quarkus-maven-plugin:update-extension-doc-page
[id="extensions-microprofile-health"]
= MicroProfile Health
:page-aliases: extensions/microprofile-health.adoc
:linkattrs:
:cq-artifact-id: camel-quarkus-microprofile-health
:cq-native-supported: true
:cq-status: Stable
:cq-status-deprecation: Stable
:cq-description: Expose Camel health checks via MicroProfile Health
:cq-deprecated: false
:cq-jvm-since: 0.3.0
:cq-native-since: 0.3.0

ifeval::[{doc-show-badges} == true]
[.badges]
[.badge-key]##JVM since##[.badge-supported]##0.3.0## [.badge-key]##Native since##[.badge-supported]##0.3.0##
endif::[]

Expose Camel health checks via MicroProfile Health

[id="extensions-microprofile-health-whats-inside"]
== What's inside

* xref:{cq-camel-components}:others:microprofile-health.adoc[Microprofile Health]

Please refer to the above link for usage and configuration details.

[id="extensions-microprofile-health-maven-coordinates"]
== Maven coordinates

https://{link-quarkus-code-generator}/?extension-search=camel-quarkus-microprofile-health[Create a new project with this extension on {link-quarkus-code-generator}, window="_blank"]

Or add the coordinates to your existing project:

[source,xml]
----
<dependency>
    <groupId>org.apache.camel.quarkus</groupId>
    <artifactId>camel-quarkus-microprofile-health</artifactId>
</dependency>
----
ifeval::[{doc-show-user-guide-link} == true]
Check the xref:user-guide/index.adoc[User guide] for more information about writing Camel Quarkus applications.
endif::[]

[id="extensions-microprofile-health-usage"]
== Usage
You can register health checks for your applications with the xref:manual::health-check.adoc[Camel health check API].

By default, classes extending `AbstractHealthCheck` are registered as both liveness and readiness checks. You can override the `isReadiness` method to control this behaviour.

Any checks provided by your application are automatically discovered and bound to the Camel registry. They will be available via
the Quarkus health endpoints `/q/health/live` and `/q/health/ready`.

You can also provide custom `HealthCheckRepository` implementations and these are also automatically discovered and bound to the Camel registry for you.

Refer to the https://quarkus.io/guides/health-guide[Quarkus health guide] for further information.

[id="extensions-microprofile-health-usage-provided-health-checks"]
=== Provided health checks

Some checks are automatically registered for your application.

[id="extensions-microprofile-health-usage-camel-context-health"]
==== Camel Context Health

Inspects the Camel Context status and causes the health check status to be `DOWN` if the status is anything other than 'Started'.

[id="extensions-microprofile-health-usage-camel-route-health"]
==== Camel Route Health

Inspects the status of each route and causes the health check status to be `DOWN` if any route status is not 'Started'.


[id="extensions-microprofile-health-additional-camel-quarkus-configuration"]
== Additional Camel Quarkus configuration

[width="100%",cols="80,5,15",options="header"]
|===
| Configuration property | Type | Default


a|icon:lock[title=Fixed at build time] [[quarkus-camel-health-enabled]]`link:#quarkus-camel-health-enabled[quarkus.camel.health.enabled]`

Set whether to enable Camel health checks
| `boolean`
| `true`
|===

[.configuration-legend]
{doc-link-icon-lock}[title=Fixed at build time] Configuration property fixed at build time. All other configuration properties are overridable at runtime.

