close

Filter

loading table of contents...

Operations Basics / Version 2512.1

Table Of Contents

4.10.2.2 Health Endpoints in the Context of a Kubernetes Deployment

In a Kubernetes deployment, you have three different probing mechanism to determine the state of your pod.

  • a startupProbe to delay adding the pod to the loadbalancing until it is ready for business. This probe is especially relevant if an application takes a long initialization time aside from being ready.

  • a readinessProbe to signal the loadbalancing that the application pod is ready to accept traffic.

  • a livenessProbe to signal that the application pod is alive and should not be removed for rescheduling.

In order to use these probes, there are dedicated endpoints below the health endpoint:

  • container:8081/actuator/health/readiness

  • container:8081/actuator/health/liveness

These endpoints are activated by the following Spring Boot properties, which are enabled by default in the Blueprint workspace:

management.endpoint.health.probes.enabled=true
management.health.livenessstate.enabled=true
management.health.readinessstate.enabled=true

In UAPI clients, the readinessState health indicator, and therefore the readiness health endpoint, also reflects the state of the UAPI connection: it reports OUT_OF_SERVICE if the content repository is offline, disrupted, or announced an upcoming runlevel change. This signals Kubernetes to remove the pod from loadbalancing and deny further traffic. The runlevel switch can then be triggered using the Section 4.10.7, “Content Server Runlevel Endpoint” with a grace period in the content-server pod during a preStop lifecycle hook followed by a sleep timeout equal to the grace period. This way, the grace period and the sleep timeout are defining the connection draining period of the client.

The application’s own readiness state (ApplicationAvailability) is not changed by this check, so only the health endpoints are affected.

This behavior is enabled by default. To restore the plain Spring Boot readinessState health indicator, which ignores the UAPI connection, set the following Spring Boot property:

management.health.uapiConnectionReadiness.enabled=false
Note

Note

Earlier versions required including the uapiConnectionReadiness health indicator in the readiness group via management.endpoint.health.group.readiness.include=readinessState,uapiConnectionReadiness. This configuration still works, but is no longer necessary and can be removed.

Search Results

Table Of Contents
warning

Your Internet Explorer is no longer supported.

Please use Mozilla Firefox, Google Chrome, or Microsoft Edge.