Skip to content
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

provider: add annotation to StorageCluster about deployment mode #2717

Merged
merged 1 commit into from
Jul 31, 2024

Conversation

leelavg
Copy link
Contributor

@leelavg leelavg commented Jul 29, 2024

setting an annotation on the storagecluster allows to only look at metadata for finding the configured mode rather than parsing the spec.

this helps for client-operator to decide reconciliation.

@leelavg
Copy link
Contributor Author

leelavg commented Jul 29, 2024

/hold

for more testing

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 29, 2024
@@ -330,11 +331,18 @@ func (r *StorageClusterReconciler) reconcilePhases(

// Check GetDeletionTimestamp to determine if the object is under deletion
if instance.GetDeletionTimestamp().IsZero() {
var instanceUpdateRequired bool
if instance.Spec.AllowRemoteStorageConsumers && util.AddAnnotation(instance, "mode", "provider") {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use a standardized annotation name ocs.openshift.io/deployment_mode or something similar

@nb-ohad
Copy link
Contributor

nb-ohad commented Jul 30, 2024

LGTM, but prefer the @iamniting will also take a look

Copy link
Member

@iamniting iamniting left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pls add in the commit msg why do we need this annotation?

Add a comment as well in the code.

setting an annotation on the storagecluster allows to only look at
metadata for finding the configured mode rather than parsing the spec.

Signed-off-by: Leela Venkaiah G <[email protected]>
@leelavg
Copy link
Contributor Author

leelavg commented Jul 31, 2024

/unhold

@openshift-ci openshift-ci bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 31, 2024
@leelavg
Copy link
Contributor Author

leelavg commented Jul 31, 2024

/cherry-pick release-4.16

@openshift-cherrypick-robot

@leelavg: once the present PR merges, I will cherry-pick it on top of release-4.16 in a new PR and assign it to you.

In response to this:

/cherry-pick release-4.16

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@leelavg
Copy link
Contributor Author

leelavg commented Jul 31, 2024

Tested as mentioned in red-hat-storage/ocs-client-operator#196 (comment)

@leelavg leelavg requested review from nb-ohad and iamniting July 31, 2024 05:13
@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jul 31, 2024
Copy link
Contributor

openshift-ci bot commented Jul 31, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: iamniting, leelavg

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:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 31, 2024
@openshift-merge-bot openshift-merge-bot bot merged commit 930a78b into red-hat-storage:main Jul 31, 2024
11 checks passed
@openshift-cherrypick-robot

@leelavg: new pull request created: #2724

In response to this:

/cherry-pick release-4.16

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@leelavg
Copy link
Contributor Author

leelavg commented Aug 13, 2024

/cherry-pick release-4.17

@openshift-cherrypick-robot

@leelavg: new pull request could not be created: failed to create pull request against red-hat-storage/ocs-operator#release-4.17 from head openshift-cherrypick-robot:cherry-pick-2717-to-release-4.17: status code 422 not one of [201], body: {"message":"Validation Failed","errors":[{"resource":"PullRequest","code":"custom","message":"No commits between red-hat-storage:release-4.17 and openshift-cherrypick-robot:cherry-pick-2717-to-release-4.17"}],"documentation_url":"https://docs.github.com/rest/pulls/pulls#create-a-pull-request","status":"422"}

In response to this:

/cherry-pick release-4.17

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@leelavg
Copy link
Contributor Author

leelavg commented Aug 13, 2024

disregard.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants