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
Enable API server's watch termination grace period by default
By default, the API server doesn't terminate long-running watches
during shutdown: Active watch traffic is subject to regular HTTP server
shutdown behavior and will delay the shutdown until the overall HTTP
request timeout is reached. Previously, k0s relied on a fixed supervisor
stop timeout of five seconds, which did not account for this behavior
under realistic load.
Enable the API server's shutdown watch termination grace period by
default so active watch streams are drained during shutdown. Since watch
traffic accounts for most long-running API activity in normal clusters,
this allows for generally faster API server shutdowns, aligning with
k0s's requirement to promptly respond to shutdown requests from the
init system.
Derive the supervisor stop timeout from the API server flags, then
clamp it to the range of 5 to 20 seconds to stay within the typical init
system stop time budget. Set the watch termination grace period to the
stop timeout minus two seconds, if not explicitly specified by the user.
Finally, add a k0s controller command line flag to explicitly set the
API server's stop timeout and bypass its automatic calculation.
Signed-off-by: Tom Wieczorek <twieczorek@mirantis.com>
0 commit comments