enh: (helm) - add annotation to wait for all resources to be deleted before removing CR finalizer#4487
Merged
estroz merged 3 commits intooperator-framework:masterfrom Apr 12, 2021
mikeshng:enh-helm-uninstall
Merged
enh: (helm) - add annotation to wait for all resources to be deleted before removing CR finalizer#4487estroz merged 3 commits intooperator-framework:masterfrom mikeshng:enh-helm-uninstall
estroz merged 3 commits intooperator-framework:masterfrom
mikeshng:enh-helm-uninstall
Conversation
…before removing finalizer Signed-off-by: Mike Ng <ming@redhat.com>
| For Helm based-operators, added annotation `helm.sdk.operatorframework.io/uninstall-wait: "true"` | ||
| to allow all resources to be deleted before removing the custom resource's finalizer. | ||
| kind: "addition" | ||
| breaking: false No newline at end of file |
Contributor
There was a problem hiding this comment.
nit : space at the end of the file.
Contributor
Author
There was a problem hiding this comment.
Thanks. Done as suggested.
| _ = r.updateResourceStatus(ctx, o, status) | ||
| return reconcile.Result{}, err | ||
| } | ||
| if !areAllResDeleted { |
Contributor
There was a problem hiding this comment.
Suggested change
| if !areAllResDeleted { | |
| if !isAllResourcesDeleted { |
Contributor
Author
There was a problem hiding this comment.
Thanks. Done as suggested.
Contributor
There was a problem hiding this comment.
This PR is very completed. It is a great work has docs, changelogs and tests 🥇
I am ok with the change. Just added a nit suggestion.
However, would be nice check with @joelanford or any other team member before we add this one.
Otherwise /lgtm
| status.RemoveCondition(types.ConditionReleaseFailed) | ||
| } | ||
|
|
||
| log.Info("Removing finalizer") |
Signed-off-by: Mike Ng <ming@redhat.com>
estroz
reviewed
Apr 12, 2021
estroz
reviewed
Apr 12, 2021
estroz
suggested changes
Apr 12, 2021
Member
estroz
left a comment
There was a problem hiding this comment.
Overall LGTM, just one potential bugfix
…ction Signed-off-by: Mike Ng <ming@redhat.com>
estroz
approved these changes
Apr 12, 2021
2 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Signed-off-by: Mike Ng ming@redhat.com
Description of the change:
For Helm based-operators, added annotation
helm.sdk.operatorframework.io/uninstall-wait: "true"option to allow all resources to be deleted before removing the custom resource's finalizer.Motivation for the change:
Closes #4401
Checklist
If the pull request includes user-facing changes, extra documentation is required:
changelog/fragments(seechangelog/fragments/00-template.yaml)website/content/en/docs