Closed iPraveenParihar closed 16 hours ago
@iPraveenParihar anything pending on this one?
@iPraveenParihar anything pending on this one?
This PR covers the Reconciling of existing PVCs(with no ReclaimSpace annotation) when ReclaimSpace annotation is added on SC.
it looks like we will skip these pvcs, won't this cause a problem when an annotation is deleted on the storageclass and the controller-added annotation exists on the PVC, IMO we need an owner to identify who added the annotation is it by the controller or not.
Right now am working on the above scenario - I think we can merge this PR? and I'll raise different PR to cover the above case?
@nixpanic @Rakshith-R PTAL
resolved conflicts
Currently, If annotations are set on StorageClass this will only affect new PVCs created from this StorageClass for ReclaimSpace operations. To include existing PVCs, one needs to restart the controller.
This commit eliminates the need of restarting the controller by watching the StorageClass object and Equeue all PVCs of it, this will then allow considering the existing PVCs and annotations will be set.
Initial testing -
RBD StorageClass
RBD PVC
Annotate the StorageClass and see that the PVCs created before are annotated
manager logs
Created new RBD PVC and annotations are set
manager logs