terminationGracePeriodSeconds

The pod setting for how long Kubernetes waits after sending SIGTERM before killing the container with SIGKILL, 30 seconds by default.

In more detail

If shutdown takes longer than this, in-flight requests are cut off. Set it longer than your slowest request plus the readiness propagation delay.

Example

Go: server.Shutdown with a context deadline shorter than the grace period

Related terms

Taught in

References