Skip to content

Comments

OCPBUGS-55317: Check capabilities before watching OLM resource#1232

Merged
openshift-merge-bot[bot] merged 1 commit intoopenshift:masterfrom
Miciah:OCPBUGS-55317-status-check-capabilities-for-subscriptions-watch
May 14, 2025
Merged

OCPBUGS-55317: Check capabilities before watching OLM resource#1232
openshift-merge-bot[bot] merged 1 commit intoopenshift:masterfrom
Miciah:OCPBUGS-55317-status-check-capabilities-for-subscriptions-watch

Conversation

@Miciah
Copy link
Contributor

@Miciah Miciah commented May 12, 2025

Only try to watch subscriptions and installplans if the "marketplace" and "OperatorLifecycleManager" capabilities are enabled.

If these capabilities are not enabled, the installplans and subscriptions resources do not exist. Before this change, the operator would fail to initialize when these capabilities were not enabled as the status and gatewayclass controllers would try and fail to watch the non-existent resources.

@openshift-ci-robot openshift-ci-robot added jira/severity-critical Referenced Jira bug's severity is critical for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels May 12, 2025
@openshift-ci-robot
Copy link
Contributor

@Miciah: This pull request references Jira Issue OCPBUGS-55317, which is invalid:

  • expected the bug to target the "4.20.0" version, but no target version was set

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

The bug has been updated to refer to the pull request using the external bug tracker.

Details

In response to this:

Only try to watch subscriptions if the "marketplace" and "OperatorLifecycleManager" capabilities are enabled.

If these capabilities are not enabled, the subscriptions resource does not exist. Before this change, the operator would fail to initialize when these capabilities were not enabled as the status controller would try and fail to watch the non-existent subscriptions resource.

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 openshift-eng/jira-lifecycle-plugin repository.

@Miciah
Copy link
Contributor Author

Miciah commented May 12, 2025

/jira refresh

@openshift-ci-robot
Copy link
Contributor

@Miciah: This pull request references Jira Issue OCPBUGS-55317, which is invalid:

  • expected the bug to target either version "4.20." or "openshift-4.20.", but it targets "4.19.0" instead

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

Details

In response to this:

/jira refresh

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 openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci openshift-ci bot requested review from Thealisyed and miheer May 12, 2025 15:55
@Miciah
Copy link
Contributor Author

Miciah commented May 12, 2025

/jira refresh

@openshift-ci-robot openshift-ci-robot added jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. and removed jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels May 12, 2025
@openshift-ci-robot
Copy link
Contributor

@Miciah: This pull request references Jira Issue OCPBUGS-55317, which is valid. The bug has been moved to the POST state.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.20.0) matches configured target version for branch (4.20.0)
  • bug is in the state ASSIGNED, which is one of the valid states (NEW, ASSIGNED, POST)

No GitHub users were found matching the public email listed for the QA contact in Jira (iamin@redhat.com), skipping review request.

Details

In response to this:

/jira refresh

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 openshift-eng/jira-lifecycle-plugin repository.

@rhamini3
Copy link
Contributor

/test ci-4.19-e2e-aws-ovn-no-capabilities

@openshift-ci
Copy link
Contributor

openshift-ci bot commented May 12, 2025

@rhamini3: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

/test e2e-aws-operator
/test e2e-aws-ovn
/test e2e-aws-ovn-serial
/test e2e-aws-ovn-upgrade
/test e2e-azure-operator
/test e2e-gcp-operator
/test e2e-hypershift
/test hypershift-e2e-aks
/test images
/test unit
/test verify
/test verify-deps

The following commands are available to trigger optional jobs:

/test e2e-aws-gatewayapi
/test e2e-aws-gatewayapi-conformance
/test e2e-aws-operator-techpreview
/test e2e-aws-ovn-single-node
/test e2e-aws-ovn-techpreview
/test e2e-azure-manual-oidc
/test e2e-azure-ovn
/test e2e-gcp-ovn
/test e2e-ibmcloud-operator
/test e2e-openstack-operator
/test okd-scos-e2e-aws-ovn
/test okd-scos-images

Use /test all to run the following jobs that were automatically triggered:

pull-ci-openshift-cluster-ingress-operator-master-e2e-aws-gatewayapi
pull-ci-openshift-cluster-ingress-operator-master-e2e-aws-operator
pull-ci-openshift-cluster-ingress-operator-master-e2e-aws-operator-techpreview
pull-ci-openshift-cluster-ingress-operator-master-e2e-aws-ovn
pull-ci-openshift-cluster-ingress-operator-master-e2e-aws-ovn-serial
pull-ci-openshift-cluster-ingress-operator-master-e2e-aws-ovn-single-node
pull-ci-openshift-cluster-ingress-operator-master-e2e-aws-ovn-techpreview
pull-ci-openshift-cluster-ingress-operator-master-e2e-aws-ovn-upgrade
pull-ci-openshift-cluster-ingress-operator-master-e2e-azure-operator
pull-ci-openshift-cluster-ingress-operator-master-e2e-azure-ovn
pull-ci-openshift-cluster-ingress-operator-master-e2e-gcp-operator
pull-ci-openshift-cluster-ingress-operator-master-e2e-gcp-ovn
pull-ci-openshift-cluster-ingress-operator-master-e2e-hypershift
pull-ci-openshift-cluster-ingress-operator-master-hypershift-e2e-aks
pull-ci-openshift-cluster-ingress-operator-master-images
pull-ci-openshift-cluster-ingress-operator-master-okd-scos-e2e-aws-ovn
pull-ci-openshift-cluster-ingress-operator-master-unit
pull-ci-openshift-cluster-ingress-operator-master-verify
pull-ci-openshift-cluster-ingress-operator-master-verify-deps
Details

In response to this:

/test ci-4.19-e2e-aws-ovn-no-capabilities

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.

@Miciah Miciah force-pushed the OCPBUGS-55317-status-check-capabilities-for-subscriptions-watch branch from c018b1e to 195381f Compare May 12, 2025 19:23
@openshift-ci-robot
Copy link
Contributor

@Miciah: This pull request references Jira Issue OCPBUGS-55317, which is valid.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.20.0) matches configured target version for branch (4.20.0)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, POST)

No GitHub users were found matching the public email listed for the QA contact in Jira (iamin@redhat.com), skipping review request.

Details

In response to this:

Only try to watch subscriptions and installplans if the "marketplace" and "OperatorLifecycleManager" capabilities are enabled.

If these capabilities are not enabled, the installplans and subscriptions resources do not exist. Before this change, the operator would fail to initialize when these capabilities were not enabled as the status and gatewayclass controllers would try and fail to watch the non-existent resources.

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 openshift-eng/jira-lifecycle-plugin repository.

@Miciah Miciah changed the title OCPBUGS-55317: status: Check capabilities for subscriptions watch OCPBUGS-55317: Check capabilities before watching OLM resource May 12, 2025
@Miciah
Copy link
Contributor Author

Miciah commented May 12, 2025

https://github.com/openshift/cluster-ingress-operator/compare/c018b1e2288c5a4127e8842662d4691bee15be6d..195381f489dfe6525117a05c8855e2deee29b560 changes the gatewayapi controller not to start the gatewayclass, gateway-service-dns, or gateway-labeler controllers if the marketplace and OLM capabilities are not enabled. As @alebedev87 pointed out to me, the gatewayclass controller watches subscriptions and installplans, both of which are OLM resources.

Comment on lines 157 to 158
// The subscriptions resource only exists if the "marketplace" and
// "OperatorLifecycleManager" capabilities are enabled. We cannot
Copy link
Contributor

@alebedev87 alebedev87 May 12, 2025

Choose a reason for hiding this comment

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

Only OperatorLifecycleManager capability owns Subscription CRD. marketplace capability helps with the management of the "out of the box catalog sources".

Copy link
Contributor Author

Choose a reason for hiding this comment

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

So it seems the operator could check just the "OperatorLifecycleManager" capability. The operator would then watch the subscription if that capability were enabled but the "marketplace" weren't, and that would let the cluster-admin manage the catalog sources manually. Is that something we should support?

Copy link
Contributor

Choose a reason for hiding this comment

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

Is that something we should support?

I don't know. In the context of this bug, I tend to stay on the safer side which is having both enabled. The requirement to support custom catalog sources may be expressed as a separate requirement.

My initial remark was about the phrasing of the comment.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Copy link
Contributor

Choose a reason for hiding this comment

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

Should we protect the retrieval of the subscription object if OLM capability is disabled in getOperatorState() too?

Copy link
Contributor

Choose a reason for hiding this comment

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

Right, we should. The periodic job run by Hongan failed at the installation due to this error (log file):

2025-05-13T07:29:00.307Z	ERROR	operator.init	controller/controller.go:288	Reconciler error	{"controller": "status_controller", "object": {"name":"default","namespace":"openshift-ingress-operator"}, "namespace": "openshift-ingress-operator", "name": "default", "reconcileID": "f0b5ca1b-4b3b-4273-8624-8725c5422b09", "error": "failed to get operator state: failed to get subscription \"openshift-operators/servicemeshoperator3\": failed to get restmapping: no matches for kind \"Subscription\" in version \"operators.coreos.com/v1alpha1\""}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@alebedev87
Copy link
Contributor

@rhamini3: /payload-job periodic-ci-openshift-release-master-ci-4.19-e2e-aws-ovn-no-capabilities seems to be the name to use for a no-caps aws job.

@lihongan
Copy link
Contributor

/payload-job periodic-ci-openshift-release-master-ci-4.20-e2e-aws-ovn-no-capabilities

@openshift-ci
Copy link
Contributor

openshift-ci bot commented May 13, 2025

@lihongan: trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-release-master-ci-4.20-e2e-aws-ovn-no-capabilities

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/4c9a0040-2fc1-11f0-9ec8-e921e9a09dce-0

@openshift-ci
Copy link
Contributor

openshift-ci bot commented May 13, 2025

@lihongan: This PR was included in a payload test run from openshift/origin#29784
trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-release-master-ci-4.20-e2e-aws-ovn-no-capabilities

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/20550170-2fc5-11f0-9635-4ac681776cf3-0

@Miciah Miciah force-pushed the OCPBUGS-55317-status-check-capabilities-for-subscriptions-watch branch from 195381f to d3f3c90 Compare May 13, 2025 11:53
@Miciah
Copy link
Contributor Author

Miciah commented May 13, 2025

/payload-job periodic-ci-openshift-release-master-ci-4.20-e2e-aws-ovn-no-capabilities

@openshift-ci
Copy link
Contributor

openshift-ci bot commented May 13, 2025

@Miciah: trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-release-master-ci-4.20-e2e-aws-ovn-no-capabilities

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/699e67c0-2ff4-11f0-894c-248eefb7cf18-0

@alebedev87
Copy link
Contributor

/assign

@Miciah
Copy link
Contributor Author

Miciah commented May 13, 2025

@Miciah: trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

* periodic-ci-openshift-release-master-ci-4.20-e2e-aws-ovn-no-capabilities

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/699e67c0-2ff4-11f0-894c-248eefb7cf18-0

The results have 77 failures, but it's a known issue that many things break with no-capabilities. Of interest to us, all the "[OCPFeatureGate:GatewayAPI]" tests passed, and all the "[OCPFeatureGate:GatewayAPIController]] tests failed, as expected. (openshift/origin#29784 should change the failures to skips.)

@Miciah
Copy link
Contributor Author

Miciah commented May 13, 2025

/payload-job periodic-ci-openshift-release-master-ci-4.20-e2e-aws-ovn-no-capabilities

@openshift-ci
Copy link
Contributor

openshift-ci bot commented May 13, 2025

@Miciah: trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-release-master-ci-4.20-e2e-aws-ovn-no-capabilities

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/6189b7e0-3014-11f0-9474-41ad5f91c087-0

@candita
Copy link
Contributor

candita commented May 13, 2025

/assign

@Miciah
Copy link
Contributor Author

Miciah commented May 13, 2025

@Miciah: trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

* periodic-ci-openshift-release-master-ci-4.20-e2e-aws-ovn-no-capabilities

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/6189b7e0-3014-11f0-9474-41ad5f91c087-0

Again, the results have 77 failures, all the "[OCPFeatureGate:GatewayAPI]" tests passed, and all the "[OCPFeatureGate:GatewayAPIController]" tests failed, as expected.

@lihongan
Copy link
Contributor

/payload-job periodic-ci-openshift-openshift-tests-private-release-4.20-multi-nightly-aws-upi-basecap-none-arm-f7

try to trigger one QE job

@openshift-ci
Copy link
Contributor

openshift-ci bot commented May 14, 2025

@lihongan: trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-openshift-tests-private-release-4.20-multi-nightly-aws-upi-basecap-none-arm-f7

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/808ee6b0-306e-11f0-956d-80de5ebb75ad-0

@lihongan
Copy link
Contributor

/payload-job periodic-ci-openshift-openshift-tests-private-release-4.20-multi-nightly-aws-upi-basecap-none-arm-f7

Hit error: Failed to acquire resource, try again

@openshift-ci
Copy link
Contributor

openshift-ci bot commented May 14, 2025

@lihongan: trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-openshift-tests-private-release-4.20-multi-nightly-aws-upi-basecap-none-arm-f7

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/0f155170-308e-11f0-8ef2-78e7e4411319-0

@alebedev87
Copy link
Contributor

/lgtm
/approve
/hold

Holding for @candita to take a look.

@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 May 14, 2025
@alebedev87
Copy link
Contributor

/retest-required

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label May 14, 2025
@openshift-ci
Copy link
Contributor

openshift-ci bot commented May 14, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: alebedev87

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

The pull request process is described here

Details 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 May 14, 2025
@lihongan
Copy link
Contributor

/payload-job periodic-ci-openshift-openshift-tests-private-release-4.20-arm64-nightly-aws-ipi-disc-priv-sts-basecap-none-mini-perm-f14

@openshift-ci
Copy link
Contributor

openshift-ci bot commented May 14, 2025

@lihongan: trigger 1 job(s) for the /payload-(with-prs|job|aggregate|job-with-prs|aggregate-with-prs) command

  • periodic-ci-openshift-openshift-tests-private-release-4.20-arm64-nightly-aws-ipi-disc-priv-sts-basecap-none-mini-perm-f14

See details on https://pr-payload-tests.ci.openshift.org/runs/ci/5a2f0260-30a6-11f0-83ee-b1fa8d4a286c-0

@openshift-ci
Copy link
Contributor

openshift-ci bot commented May 14, 2025

@Miciah: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-aws-operator-techpreview 30dda05 link false /test e2e-aws-operator-techpreview
ci/prow/e2e-aws-ovn-single-node 30dda05 link false /test e2e-aws-ovn-single-node

Full PR test history. Your PR dashboard.

Details

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. I understand the commands that are listed here.

@alebedev87
Copy link
Contributor

/test e2e-aws-ovn-serial

The job timed out, openshift/release#64896 should help with the timeout issues.

@alebedev87
Copy link
Contributor

/unhold

Taking into account the urgency on this fix, a single LGTM can be enough. We can follow up later.

@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 May 14, 2025
@Miciah
Copy link
Contributor Author

Miciah commented May 14, 2025

e2e-aws-operator-techpreview failed because TestIngressControllerCustomEndpoints failed. The failure appears to be an instance of the error that OCPBUGS-53432 is tracking (test timed out while the LB was pending).

@Miciah
Copy link
Contributor Author

Miciah commented May 14, 2025

e2e-aws-ovn-single-node failed because [sig-devex] check registry.redhat.io is available and samples operator can import sample imagestreams run sample related validations failed:

{  fail [github.com/openshift/origin/test/extended/tbr_health/check.go:18]: Expected
    <string>: failed to get imagestream: imagestreams.image.openshift.io "nodejs" not found
to be empty
Ginkgo exit error 1: exit with code 1}

I filed OCPBUGS-56196 for this issue.

@openshift-merge-bot openshift-merge-bot bot merged commit f0e62c3 into openshift:master May 14, 2025
18 of 20 checks passed
@openshift-ci-robot
Copy link
Contributor

@Miciah: Jira Issue OCPBUGS-55317: Some pull requests linked via external trackers have merged:

The following pull requests linked via external trackers have not merged:

These pull request must merge or be unlinked from the Jira bug in order for it to move to the next state. Once unlinked, request a bug refresh with /jira refresh.

Jira Issue OCPBUGS-55317 has not been moved to the MODIFIED state.

Details

In response to this:

Only try to watch subscriptions and installplans if the "marketplace" and "OperatorLifecycleManager" capabilities are enabled.

If these capabilities are not enabled, the installplans and subscriptions resources do not exist. Before this change, the operator would fail to initialize when these capabilities were not enabled as the status and gatewayclass controllers would try and fail to watch the non-existent resources.

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 openshift-eng/jira-lifecycle-plugin repository.

@Miciah
Copy link
Contributor Author

Miciah commented May 14, 2025

/cherry-pick release-4.19

@openshift-cherrypick-robot

@Miciah: new pull request created: #1233

Details

In response to this:

/cherry-pick release-4.19

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.

@openshift-bot
Copy link
Contributor

[ART PR BUILD NOTIFIER]

Distgit: ose-cluster-ingress-operator
This PR has been included in build ose-cluster-ingress-operator-container-v4.20.0-202505151012.p0.gf0e62c3.assembly.stream.el9.
All builds following this will include this PR.

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. jira/severity-critical Referenced Jira bug's severity is critical for the branch this PR is targeting. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants