mirror of https://github.com/k3s-io/k3s
Merge pull request #66938 from sjenning/avoid-mount-delay
Automatic merge from submit-queue (batch tested with PRs 62901, 66562, 66938, 66927, 66926). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. kubelet: volumemanager: poll immediate when waiting for volume attachment Currently, `WaitForAttachAndMount()` introduces a 300ms minimum delay by using `wait.Poll()` rather than `wait.PollImmediate()`. This wait constitutes >99% of the total processing time for `syncPod()`. Changing this reduced `syncPod()` processing time for a simple busybox pod with one emptyDir volume from 302ms to 2ms. @derekwaynecarr @pmorie @smarterclayton @jsafrane /sig node /release-note-nonepull/8/head
commit
6a33d1ba10
|
@ -352,7 +352,7 @@ func (vm *volumeManager) WaitForAttachAndMount(pod *v1.Pod) error {
|
|||
// like Downward API, depend on this to update the contents of the volume).
|
||||
vm.desiredStateOfWorldPopulator.ReprocessPod(uniquePodName)
|
||||
|
||||
err := wait.Poll(
|
||||
err := wait.PollImmediate(
|
||||
podAttachAndMountRetryInterval,
|
||||
podAttachAndMountTimeout,
|
||||
vm.verifyVolumesMountedFunc(uniquePodName, expectedVolumes))
|
||||
|
|
Loading…
Reference in New Issue