Liveness probe
A liveness probe determines whether an application process is alive and capable of responding. In this course, the Go API exposes GET /healthz as a cheap endpoint that does not contact MySQL, Redis, or Kafka.
Minimal example
func Healthz(w http.ResponseWriter, r *http.Request) {
w.WriteHeader(http.StatusOK)
w.Write([]byte("ok"))
}Learn this concept
Lesson 7.5 · HTTPS health and migration gatesPrerequisite conceptsHTTP handler