Skip to content

Commit

Permalink
Merge pull request kubernetes#106633 from ahg-g/automated-cherry-pick…
Browse files Browse the repository at this point in the history
…-of-#106412-upstream-release-1.22

Automated cherry pick of kubernetes#106412: kube-scheduler: Increase the duration to expire an assumed
  • Loading branch information
k8s-ci-robot committed Nov 26, 2021
2 parents 8fa0073 + c2493e4 commit 125966a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pkg/scheduler/scheduler.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@ const (
SchedulerError = "SchedulerError"
// Percentage of plugin metrics to be sampled.
pluginMetricsSamplePercent = 10
// Duration the scheduler will wait before expiring an assumed pod.
// See issue #106361 for more details about this parameter and its value.
durationToExpireAssumedPod = 2 * time.Minute
)

// Scheduler watches for new unscheduled pods. It attempts to find
Expand Down Expand Up @@ -239,7 +242,7 @@ func New(client clientset.Interface,
}
options.profiles = cfg.Profiles
}
schedulerCache := internalcache.New(30*time.Second, stopEverything)
schedulerCache := internalcache.New(durationToExpireAssumedPod, stopEverything)

registry := frameworkplugins.NewInTreeRegistry()
if err := registry.Merge(options.frameworkOutOfTreeRegistry); err != nil {
Expand Down

0 comments on commit 125966a

Please sign in to comment.