Merge pull request #37808 from hex108/add_retry_interval

Automatic merge from submit-queue (batch tested with PRs 37094, 37663, 37442, 37808, 37826)

Add some sleep between each retry to set container's oom scroe

Ref https://github.com/kubernetes/kubernetes/issues/23607#issuecomment-264135015
This commit is contained in:
Kubernetes Submit Queue 2016-12-03 04:27:52 -08:00 committed by GitHub
commit b926fa5009

View File

@ -25,6 +25,7 @@ import (
"path"
"path/filepath"
"strconv"
"time"
cmutil "k8s.io/kubernetes/pkg/kubelet/cm/util"
@ -72,6 +73,7 @@ func applyOOMScoreAdj(pid int, oomScoreAdj int) error {
}
glog.V(3).Info(err)
time.Sleep(100 * time.Millisecond)
continue
}
return nil