Skip to content

Commit 04e31de

Browse files
committed
Log on removal as well
1 parent 6b20072 commit 04e31de

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

pkg/linkcache/cache.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,10 @@ func (d *linkCache) BrokenSymlink(symlink string) {
170170
}
171171

172172
func (d *linkCache) RemoveDevice(symlink string) {
173-
delete(d.devices, symlink)
173+
if entry, ok := d.devices[symlink]; ok {
174+
klog.Infof("Removing device %s with path %s from cache, brokenSymlink: %t", symlink, entry.path, entry.brokenSymlink)
175+
delete(d.devices, symlink)
176+
}
174177
}
175178

176179
func (d *linkCache) DeviceIDs() []string {

0 commit comments

Comments
 (0)