A database connection health check verifies whether an application's configured JDBC connection is working. Quarkus automatically exposes this as a readiness check when the application uses a JDBC data source. section 10.2.1
Apply the check in a Quarkus service by:
- Running the service and inspecting the Health UI or /q/health endpoint. section 10.2.1
- Using /q/ready when only readiness checks are needed. section 10.2.1
Detecting an unavailable database
With the database running, the overall status and database check report UP. Stopping the MySQL container changes the overall status to DOWN and reports a communications-link failure.
