mirror of
				https://github.com/optim-enterprises-bv/kubernetes.git
				synced 2025-11-03 19:58:17 +00:00 
			
		
		
		
	Merge pull request #82964 from yutedz/csi-drv-sync-err
Check error return from WaitForCacheSync
This commit is contained in:
		@@ -743,7 +743,9 @@ func (p *csiPlugin) skipAttach(driver string) (bool, error) {
 | 
			
		||||
 | 
			
		||||
	kletHost, ok := p.host.(volume.KubeletVolumeHost)
 | 
			
		||||
	if ok {
 | 
			
		||||
		kletHost.WaitForCacheSync()
 | 
			
		||||
		if err := kletHost.WaitForCacheSync(); err != nil {
 | 
			
		||||
			return false, err
 | 
			
		||||
		}
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if p.csiDriverLister == nil {
 | 
			
		||||
@@ -782,7 +784,9 @@ func (p *csiPlugin) supportsVolumeLifecycleMode(driver string, volumeMode storag
 | 
			
		||||
	if p.csiDriverLister != nil {
 | 
			
		||||
		kletHost, ok := p.host.(volume.KubeletVolumeHost)
 | 
			
		||||
		if ok {
 | 
			
		||||
			kletHost.WaitForCacheSync()
 | 
			
		||||
			if err := kletHost.WaitForCacheSync(); err != nil {
 | 
			
		||||
				return err
 | 
			
		||||
			}
 | 
			
		||||
		}
 | 
			
		||||
 | 
			
		||||
		c, err := p.csiDriverLister.Get(driver)
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user