Health Monitoring
The sidecar instances exposes an HTTP route /health
on port 9000
for health
monitoring from Load Balancers and container orchestrators. It can be accessed
calling the endpoint http://<instance-address>:9000/health
. This route observes
the health of the internal processes and returns a proper HTTP response code and
a JSON blob containing extra information on the status of each of the sidecar
services.
It is important to notice that the health monitoring refers to a single sidecar instance. As a single sidecar can be composed of multiple computing instances, all of them must be monitored in order to guarantee the health of a sidecar.
The JSON
blob returned by the /health
route is the following:
{
"status":"degraded",
"components": {
"alerter": {
"status":"healthy"
},
"mysql-wire": {
"status": "degraded",
"error": "service is initializing",
},
...
},
"timestamp":"0001-01-01T00:00:00Z"
}
The top-level status
can be one of the following:
Sidecar Instance Status | HTTP Response Code | Description |
---|---|---|
healthy | 200 | All the monitored components in the instance are working properly and the it can receive requests normally. |
degraded | 200 | Some services in the instance are not working, but it should be able to accept connections without issues if resiliency mode is active. |
unhealthy | 503 | Not able to accept connections. |
unknown | 503 | Instance components are yet to be tested. |
Each components
object status
can be one the following:
Component Status | Description |
---|---|
healthy | Component is working as expected. |
degraded | Component is not working as expected, but the error is not critical to the sidecar instance functionality. |
unhealthy | Component is not working as expected and error is critical to the sidecar instance functionality. |
As shown in the example JSON
, when the component status is not healthy
the status
message will be accompanied
by an error
field containing more details.