You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: documentation/spring-boot-docs/src/docs/antora/modules/how-to/pages/deployment/cloud.adoc
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -124,6 +124,8 @@ Because this shutdown processing happens in parallel (and due to the nature of d
124
124
125
125
You can configure a sleep execution in a preStop handler to avoid requests being routed to a pod that has already begun shutting down.
126
126
This sleep should be long enough for new requests to stop being routed to the pod and its duration will vary from deployment to deployment.
127
+
The delay should be at least as long as the longest time it takes to process an in-flight request.
128
+
You should not rely on the Spring Boot graceful shutdown period alone, as the platform will not be getting any liveness data in the period that the app is shutting down.
127
129
128
130
If you're using Kubernetes 1.32 or up, the preStop handler can be configured by using the PodSpec in the pod's configuration file as follows:
0 commit comments