PV controller changes to support PV Deletion protection finalizer
Signed-off-by: Deepak Kinni <dkinni@vmware.com>
This commit is contained in:
@@ -537,10 +537,9 @@ func (ctrl *PersistentVolumeController) syncBoundClaim(claim *v1.PersistentVolum
|
||||
// these events.
|
||||
func (ctrl *PersistentVolumeController) syncVolume(ctx context.Context, volume *v1.PersistentVolume) error {
|
||||
klog.V(4).Infof("synchronizing PersistentVolume[%s]: %s", volume.Name, getVolumeStatusForLogging(volume))
|
||||
|
||||
// Set correct "migrated-to" annotations on PV and update in API server if
|
||||
// Set correct "migrated-to" annotations and modify finalizers on PV and update in API server if
|
||||
// necessary
|
||||
newVolume, err := ctrl.updateVolumeMigrationAnnotations(ctx, volume)
|
||||
newVolume, err := ctrl.updateVolumeMigrationAnnotationsAndFinalizers(ctx, volume)
|
||||
if err != nil {
|
||||
// Nothing was saved; we will fall back into the same
|
||||
// condition in the next call to this method
|
||||
|
Reference in New Issue
Block a user