From 7b0c25b33fbeedf1bffb24628d0d8219215cb661 Mon Sep 17 00:00:00 2001 From: csuzhangxc Date: Wed, 11 Jan 2023 06:41:24 +0000 Subject: [PATCH] add comment --- pkg/manager/volumes/delegation/interface.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/manager/volumes/delegation/interface.go b/pkg/manager/volumes/delegation/interface.go index ea0e24e210f..8c31fee5cbb 100644 --- a/pkg/manager/volumes/delegation/interface.go +++ b/pkg/manager/volumes/delegation/interface.go @@ -23,7 +23,8 @@ import ( type VolumeModifier interface { MinWaitDuration() time.Duration - // ModifyVolume modifies the underlay volume of pvc to match the args of storageclass + // ModifyVolume modifies the underlay volume of pvc to match the args of storageclass. + // If no PV permission (e.g `-cluster-permission-pv=false`), the `pv` may be nil and will return `false, nil`. ModifyVolume(ctx context.Context, pvc *corev1.PersistentVolumeClaim, pv *corev1.PersistentVolume, sc *storagev1.StorageClass) (bool, error) Validate(spvc, dpvc *corev1.PersistentVolumeClaim, ssc, dsc *storagev1.StorageClass) error