Skip to content

Commit 0bb4c7c

Browse files
authored
Merge pull request #2069 from halimsam/release-1.17-remove-logs
Remove no-op Watcher logs for GKE Data Cache in 1.17 release branch
2 parents 352f679 + bfd8ebf commit 0bb4c7c

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

pkg/gce-pd-csi-driver/cache.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -491,7 +491,6 @@ func createVg(volumeGroupName string, raidedLocalSsds string) error {
491491

492492
func reduceVolumeGroup(volumeGroupName string, force bool) {
493493
if !checkVgExists(volumeGroupName) {
494-
klog.V(2).Infof("Volume group %v not found, no further action needed", volumeGroupName)
495494
return
496495
}
497496
args := []string{
@@ -646,7 +645,7 @@ func watchDiskDetaches(watcher *fsnotify.Watcher, nodeName string, errorCh chan
646645
case err := <-watcher.Errors:
647646
errorCh <- fmt.Errorf("disk update event errored: %v", err)
648647
// watch for events
649-
case event := <-watcher.Events:
648+
case <-watcher.Events:
650649
// In case of an event i.e. creation or deletion of any new PV, we update the VG metadata.
651650
// This might include some non-LVM changes, no harm in updating metadata multiple times.
652651
args := []string{
@@ -658,7 +657,6 @@ func watchDiskDetaches(watcher *fsnotify.Watcher, nodeName string, errorCh chan
658657
klog.Errorf("Error updating volume group's metadata: %v", err)
659658
}
660659
reduceVolumeGroup(getVolumeGroupName(nodeName), true)
661-
klog.V(6).Infof("disk attach/detach event %#v\n", event)
662660
}
663661
}
664662
}

0 commit comments

Comments
 (0)