From cee19d1e6eafc38b90dd2a4f8ed442784cec3169 Mon Sep 17 00:00:00 2001 From: Kevin Parsons Date: Wed, 29 May 2019 16:39:50 -0700 Subject: [PATCH] Change restart delay for Windows service to 15s Previously we waited for 60 seconds after the service faults to restart it. However, there isn't much benefit to waiting this long. We expect 15 seconds to be a more reasonable delay. Signed-off-by: Kevin Parsons --- cmd/containerd/command/service_windows.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/containerd/command/service_windows.go b/cmd/containerd/command/service_windows.go index 791af3aa8..47722178c 100644 --- a/cmd/containerd/command/service_windows.go +++ b/cmd/containerd/command/service_windows.go @@ -270,8 +270,8 @@ func registerService() error { Delay uint32 } t := []scAction{ - {Type: scActionRestart, Delay: uint32(60 * time.Second / time.Millisecond)}, - {Type: scActionRestart, Delay: uint32(60 * time.Second / time.Millisecond)}, + {Type: scActionRestart, Delay: uint32(15 * time.Second / time.Millisecond)}, + {Type: scActionRestart, Delay: uint32(15 * time.Second / time.Millisecond)}, {Type: scActionNone}, } lpInfo := serviceFailureActions{ResetPeriod: uint32(24 * time.Hour / time.Second), ActionsCount: uint32(3), Actions: uintptr(unsafe.Pointer(&t[0]))}