Search GimmeJob

Type at least 2 characters. Enter also searches by meaning.
QA interview question
Observability & productionMiddleOccasionalTest design

What should a useful production health check verify?

Answer

A health check should be fast, deterministic, bounded by a short timeout and aligned with the action its result triggers. Liveness should prove only that local progress requires no restart; readiness may check the minimum conditions needed to serve traffic, but should not fail for every optional dependency. Test stale caches, degraded dependencies, overload, partial initialization and authentication boundaries, and keep sensitive diagnostics out of public responses while exposing deeper detail to authorized operators.

Strong answer includes

  • designs the check around its operational action
  • separates required from optional dependencies
  • covers degraded and overloaded states

Practical example

A service's readiness check originally pinged every downstream dependency, including an optional recommendations service. When the recommendations service had a brief outage, every instance of the main service was pulled from rotation even though it could still serve core functionality. A QA engineer redesigns the test to distinguish required dependencies (the primary database) from optional ones (recommendations), so readiness now only fails for the database, while a separate internal-only endpoint still reports the recommendations service as degraded for operators.

#health-checks#kubernetes#dependencies#production

Sources

Configure liveness, readiness and startup probesKubernetes · Service health, traffic readiness, recovery and probe failure modesGoogle SRE booksGoogle · Reliability, SLOs, monitoring, incidents and resilience