karmada icon indicating copy to clipboard operation
karmada copied to clipboard

skip cleanup when the poliyMarks changed

Open zhzhuang-zju opened this issue 6 months ago • 14 comments

What type of PR is this? /kind bug

What this PR does / why we need it: Refer to #5307, there is a chance that poliy marks be lost when deleting the old pp/cpp and binding a new one. When performing a clean up of marks on rb/crb, we can compare the value of the label policyv1alpha1.ClusterPropagationPolicyPermanentIDLabel/policyv1alpha1.PolicyPermanentIDLabel on the cb/crb with the policyId value of the deleted CPP/PP. If they are not the same, it indicates that the rb/crb has already claimed to a new CPP/PP, and there is no need to clean up the label/annotation.

Which issue(s) this PR fixes: Fixes #5307

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

`karmada-controller-manager`: Fixed an issue that poliyMarks might be lost when deleting the old pp/cpp and binding a new one

zhzhuang-zju avatar Aug 07 '24 02:08 zhzhuang-zju