Hi all, Can anyone help me understand better liveness and readiness probes? Fr . . .

Jason Snape:
Hi all,

Can anyone help me understand better liveness and readiness probes?

From my understanding they complement each other, readiness probes help ensure that requests aren’t sent to unavailable containers but can’t restart them. Whereas liveness probes can’t stop requests but can restart the container after the timeout period.

Typically would both liveness probes and readiness probes check the same thing i.e. httpGet or exec command?

Thanks, Jason

Trung Tran:
My opinion:
You want to use liveness to check if the container need to be restart/replace or not.
Readiness doesn’t participate in container lifecycle, it only indicate that the application is ready to receive the request or not.
• liveness = false, the container will be killed by kubelet.
• readiness = false => just do not route traffic to this.

Felipe Savoia:
You could see liveness like a constant healthcheck from your container and readiness like a test to see if it’s ready for receive traffic. You can test to see if your container is connecting with a database for example.

Jason Snape:
Thanks both for the clarification. :+1::skin-tone-2:

unnivkn:
Hi @Jason Snape fyi: https://medium.com/@AADota/kubernetes-liveness-and-readiness-probes-difference-1b659c369e17