-
Notifications
You must be signed in to change notification settings - Fork 142
Enable Rollback Support of VAC with Infeasible Errors #487
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Enable Rollback Support of VAC with Infeasible Errors #487
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: sunnylovestiramisu The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
0a9dc85
to
20411cf
Compare
20411cf
to
5cc5fe8
Compare
/lgtm |
@@ -65,6 +65,24 @@ func (ctrl *modifyController) modify(pvc *v1.PersistentVolumeClaim, pv *v1.Persi | |||
} | |||
return ctrl.controllerModifyVolumeWithTarget(pvc, pv, vac, pvcSpecVacName) | |||
} | |||
} else if pvcSpecVacName != nil && curVacName != nil && pvc.Status.ModifyVolumeStatus != nil && *pvcSpecVacName == *curVacName { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can pvcSpecVacName
ever be nil
in this code path? I think that, this code is way harder to read and understand because all the used if
and else
conditions need to be simplified.
What type of PR is this?
/kind bug
What this PR does / why we need it:
ControllerModifyVolume should allow rollback if a modification ends in infeasible state.
Which issue(s) this PR fixes:
Fixes #482 , kubernetes/kubernetes#130597
Special notes for your reviewer:
Does this PR introduce a user-facing change?: