Skip to content

Commit

Permalink
Merge pull request #93052 from andyzhangx/fix-initial-delay
Browse files Browse the repository at this point in the history
fix: initial delay in mounting azure disk & file
  • Loading branch information
k8s-ci-robot authored Jul 17, 2020
2 parents fbbc3ed + 82b8b07 commit 58893f3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pkg/volume/azure_dd/attacher.go
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ func (a *azureDiskAttacher) WaitForAttach(spec *volume.Spec, devicePath string,

newDevicePath := ""

err = wait.Poll(1*time.Second, timeout, func() (bool, error) {
err = wait.PollImmediate(1*time.Second, timeout, func() (bool, error) {
if newDevicePath, err = findDiskByLun(int(lun), io, exec); err != nil {
return false, fmt.Errorf("azureDisk - WaitForAttach ticker failed node (%s) disk (%s) lun(%v) err(%s)", nodeName, diskName, lun, err)
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/volume/azure_file/azure_file.go
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ func (b *azureFileMounter) SetUpAt(dir string, mounterArgs volume.MounterArgs) e
}

mountComplete := false
err = wait.Poll(5*time.Second, 10*time.Minute, func() (bool, error) {
err = wait.PollImmediate(1*time.Second, 2*time.Minute, func() (bool, error) {
err := b.mounter.MountSensitive(source, dir, "cifs", mountOptions, sensitiveMountOptions)
mountComplete = true
return true, err
Expand Down

0 comments on commit 58893f3

Please sign in to comment.