openshift / oadp-operator

OADP Operator
Apache License 2.0
78 stars 72 forks source link

OADP-3050: Remove unwanted BSL/VSLs on create/edit DPA #1525

Closed stillalearner closed 1 month ago

stillalearner commented 1 month ago

Fixes #1469 of unwanted BSL or VSLs in the cases:

  1. BSLs/VSLs removed from DPA spec.
  2. BSL/VSLs names modified in-place from DPA spec.
  3. Default-named BSL/VSLs removed from DPA spec.

hope that covers all cases.

openshift-ci-robot commented 1 month ago

@stillalearner: This pull request references OADP-3050 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "4.18.0" version, but no target version was set.

In response to [this](https://github.com/openshift/oadp-operator/pull/1525): >Fixes the issue of unwanted BSL or VSLs in the cases: > >1. BSLs/VSLs removed from DPA spec. >2. BSL/VSLs names modified in-place from DPA spec. >3. Default-named BSL/VSLs removed from DPA spec. > >hope that covers all cases. Instructions for interacting with me using PR comments are available [here](https://prow.ci.openshift.org/command-help?repo=openshift%2Foadp-operator). If you have questions or suggestions related to my behavior, please file an issue against the [openshift-eng/jira-lifecycle-plugin](https://github.com/openshift-eng/jira-lifecycle-plugin/issues/new) repository.
openshift-ci-robot commented 1 month ago

@stillalearner: This pull request references OADP-3050 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "4.18.0" version, but no target version was set.

In response to [this](https://github.com/openshift/oadp-operator/pull/1525): >Fixes the issue #1469 of unwanted BSL or VSLs in the cases: > >1. BSLs/VSLs removed from DPA spec. >2. BSL/VSLs names modified in-place from DPA spec. >3. Default-named BSL/VSLs removed from DPA spec. > >hope that covers all cases. Instructions for interacting with me using PR comments are available [here](https://prow.ci.openshift.org/command-help?repo=openshift%2Foadp-operator). If you have questions or suggestions related to my behavior, please file an issue against the [openshift-eng/jira-lifecycle-plugin](https://github.com/openshift-eng/jira-lifecycle-plugin/issues/new) repository.
stillalearner commented 1 month ago

Have to double check but hopefully this doesn't break the workaround in https://issues.redhat.com/browse/OADP-3630

I think it should not, as these changes only deal with the BSLs having all of the 3 labels.

While the workaround is only adding one of those. What do you think @kaovilai ?

openshift-ci-robot commented 1 month ago

@stillalearner: This pull request references OADP-3050 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the bug to target the "4.18.0" version, but no target version was set.

In response to [this](https://github.com/openshift/oadp-operator/pull/1525): >Fixes #1469 of unwanted BSL or VSLs in the cases: > >1. BSLs/VSLs removed from DPA spec. >2. BSL/VSLs names modified in-place from DPA spec. >3. Default-named BSL/VSLs removed from DPA spec. > >hope that covers all cases. Instructions for interacting with me using PR comments are available [here](https://prow.ci.openshift.org/command-help?repo=openshift%2Foadp-operator). If you have questions or suggestions related to my behavior, please file an issue against the [openshift-eng/jira-lifecycle-plugin](https://github.com/openshift-eng/jira-lifecycle-plugin/issues/new) repository.
stillalearner commented 1 month ago

Did some manual tests with BSL

also good to do some tests with VSL

add new BSL to DPA expect: one creation/no deletion

master ✅ PR ✅

change existing BSL spec from DPA expect: no creation/no deletion

master ✅ PR ✅

change existing BSL name from DPA expect: one creation/one deletion

master ❌ PR ✅

remove existing BSL from DPA expect: no creation/one deletion

master ❌ PR ✅

delete DPA expect: no creation/all deletion

master ✅ PR ✅

Thanks @mateusoliveira43 !! I also performed most of these test cases with BSL and VSL both and some other corner cases as well.

shubham-pampattiwar commented 1 month ago

/retest

mateusoliveira43 commented 1 month ago

/retest

openshift-ci[bot] commented 1 month ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: kaovilai, mateusoliveira43, shubham-pampattiwar, sseago, stillalearner

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files: - ~~[OWNERS](https://github.com/openshift/oadp-operator/blob/master/OWNERS)~~ [kaovilai,mateusoliveira43,shubham-pampattiwar,sseago] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
shubham-pampattiwar commented 1 month ago

/retest

openshift-ci[bot] commented 1 month ago

@stillalearner: all tests passed!

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes-sigs/prow](https://github.com/kubernetes-sigs/prow/issues/new?title=Prow%20issue:) repository. I understand the commands that are listed [here](https://go.k8s.io/bot-commands).
weshayutin commented 1 month ago

/cherry-pick oadp-1.3

openshift-cherrypick-robot commented 1 month ago

@weshayutin: #1525 failed to apply on top of branch "oadp-1.3":

Applying: OADP-3050: Remove unwanted BSL/VSLs on create/edit DPA
Using index info to reconstruct a base tree...
M   controllers/bsl.go
M   controllers/vsl.go
M   tests/e2e/dpa_deployment_suite_test.go
Falling back to patching base and 3-way merge...
Auto-merging tests/e2e/dpa_deployment_suite_test.go
CONFLICT (content): Merge conflict in tests/e2e/dpa_deployment_suite_test.go
Auto-merging controllers/vsl.go
CONFLICT (content): Merge conflict in controllers/vsl.go
Auto-merging controllers/bsl.go
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0001 OADP-3050: Remove unwanted BSL/VSLs on create/edit DPA
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
In response to [this](https://github.com/openshift/oadp-operator/pull/1525#issuecomment-2385999668): >/cherry-pick oadp-1.3 Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes-sigs/prow](https://github.com/kubernetes-sigs/prow/issues/new?title=Prow%20issue:) repository.
weshayutin commented 1 month ago

/cherry-pick oadp-1.4

openshift-cherrypick-robot commented 1 month ago

@weshayutin: #1525 failed to apply on top of branch "oadp-1.4":

Applying: OADP-3050: Remove unwanted BSL/VSLs on create/edit DPA
Using index info to reconstruct a base tree...
M   controllers/bsl.go
M   controllers/vsl.go
M   tests/e2e/dpa_deployment_suite_test.go
Falling back to patching base and 3-way merge...
Auto-merging tests/e2e/dpa_deployment_suite_test.go
Auto-merging controllers/vsl.go
CONFLICT (content): Merge conflict in controllers/vsl.go
Auto-merging controllers/bsl.go
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0001 OADP-3050: Remove unwanted BSL/VSLs on create/edit DPA
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
In response to [this](https://github.com/openshift/oadp-operator/pull/1525#issuecomment-2386006759): >/cherry-pick oadp-1.4 Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes-sigs/prow](https://github.com/kubernetes-sigs/prow/issues/new?title=Prow%20issue:) repository.
weshayutin commented 1 month ago

@stillalearner fyi ^