Skip to content

Latest commit

 

History

History
27 lines (14 loc) · 1.13 KB

README.md

File metadata and controls

27 lines (14 loc) · 1.13 KB

Spring Boot and K8 health endpoints example

The Spring Boot project includes Spring Cloud Kubernetes which wraps K8's secrets, config and service discovery.

However, it doesn't add much for k8 liveliness and readiness probes.

K8 Specific Actuators

This exposes two additional actuators, LivelinessActuator and ReadinessActuator.

Liveliness Actuator

This returns an error code if the Spring health endpoints fail, else returns ok.

Readiness Actuator

This checks Tomcat metrics and will fail if the number of currently busy threads is 70% of the Tomcat threadpool.

Utilities

Also in this package:

  • SlowController: http://localhost:8080/ <-- takes 1 second to return
  • CustomHealthActuator <-- want to see your liveliness endpoint fail? Make this health check endpoint fail.
  • bin/ <-- contains scripts to DDoS your machine!