Platform

Check Cluster Health

Changed on

Required role: read or higher.

Determine the latest cluster health via the latest cluster monitor event. Each service's unchanged_since reports the approximate time it last transitioned between healthy and unhealthy, bounded by event retention.

The cluster monitor is the only writer of these events. In the enterprise edition it runs within the runner process, so when the runner dies the newest event keeps describing a cluster that no longer exists; elsewhere the monitor is a task in the process that answers this request. Either way a service cannot report its own death, so this endpoint additionally checks how old that event is. A stale response repeats the last recorded statuses instead of describing the cluster now, and counts as unhealthy: monitoring that has died cannot vouch for anything.

get/v0/cluster_healthz

Request

  • The document declares no server URL.
  • Auth: HTTP bearer

Response

All services healthy

all_healthyboolean required

Whether every service is healthy and the monitoring data behind this report is fresh.

staleboolean required

Whether the cluster monitor stopped writing events, which makes the statuses below the last recorded ones rather than current ones.

stale_after_secondsinteger required

Age at which monitoring data counts as stale.

Changes

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status

    • breaking

      removed the required property from the response with the status

    • breaking

      removed the required property from the response with the status

    • breaking

      removed the required property from the response with the status

    • breaking

      removed the required property from the response with the status