Skip to content

Conversation

@stevekuznetsov
Copy link
Contributor

We were (again) accidentally watching all ConfigMaps in the cluster. This patch should fix the errant code by using the correct client as well as by removing the RBAC to do so in the first place.

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

@stevekuznetsov: This pull request references Jira Issue OCPBUGS-15365, 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.14.0) matches configured target version for branch (4.14.0)
  • bug is in the state ASSIGNED, which is one of the valid states (NEW, ASSIGNED, POST)

Requesting review from QA contact:
/cc @jianping-shu

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

Details

In response to this:

We were (again) accidentally watching all ConfigMaps in the cluster. This patch should fix the errant code by using the correct client as well as by removing the RBAC to do so in the first place.

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/test-infra repository.

}

err = secretutils.WatchCCOConfig(c, types.NamespacedName{
err = secretutils.WatchCCOConfig(mgr.GetCache(), c, types.NamespacedName{
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is a bit tricky - we're triggering reconciliation in the controller (based on the root cred manager) by using events for the CCO config that come from the other manager's cache. We did the same in the actuators but in the other direction, one cache with configmap events driving the other reconciler.

@codecov
Copy link

codecov bot commented Jul 12, 2023

Codecov Report

Merging #563 (5530e6e) into master (acfee1f) will not change coverage.
The diff coverage is 22.44%.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #563   +/-   ##
=======================================
  Coverage   48.00%   48.00%           
=======================================
  Files          93       93           
  Lines       11613    11613           
=======================================
  Hits         5575     5575           
  Misses       5411     5411           
  Partials      627      627           
Impacted Files Coverage Δ
pkg/operator/secretannotator/utils/utils.go 0.00% <0.00%> (ø)
pkg/operator/secretannotator/azure/reconciler.go 35.52% <20.00%> (ø)
pkg/operator/secretannotator/vsphere/reconciler.go 37.17% <20.00%> (-0.49%) ⬇️
pkg/operator/secretannotator/aws/reconciler.go 45.29% <25.00%> (ø)
pkg/operator/secretannotator/gcp/reconciler.go 45.28% <25.00%> (ø)
...g/operator/secretannotator/openstack/reconciler.go 55.11% <27.27%> (ø)

@stevekuznetsov stevekuznetsov force-pushed the skuznets/more-configmap-pruning branch from 0a6f280 to 25bccd3 Compare July 12, 2023 17:23
We were (again) accidentally watching all ConfigMaps in the cluster.
This patch should fix the errant code by using the correct client as
well as by removing the RBAC to do so in the first place.

Signed-off-by: Steve Kuznetsov <skuznets@redhat.com>
@stevekuznetsov stevekuznetsov force-pushed the skuznets/more-configmap-pruning branch from 25bccd3 to 5530e6e Compare July 12, 2023 18:39
@jstuever
Copy link
Contributor

/cc @abutcher

@openshift-ci openshift-ci bot requested a review from abutcher July 12, 2023 20:21
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jul 12, 2023

@stevekuznetsov: all tests passed!

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

@abutcher
Copy link
Member

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jul 12, 2023
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jul 12, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: abutcher, stevekuznetsov

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 Jul 12, 2023
@openshift-merge-robot openshift-merge-robot merged commit e620083 into openshift:master Jul 12, 2023
@openshift-ci-robot
Copy link
Contributor

@stevekuznetsov: Jira Issue OCPBUGS-15365: All pull requests linked via external trackers have merged:

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

Details

In response to this:

We were (again) accidentally watching all ConfigMaps in the cluster. This patch should fix the errant code by using the correct client as well as by removing the RBAC to do so in the first place.

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/test-infra repository.

ming1013 pushed a commit to ming1013/cloud-credential-operator that referenced this pull request Dec 15, 2025
…nfigmap-pruning

OCPBUGS-15365: *: use correct clients in the secretannotator
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-moderate Referenced Jira bug's severity is moderate 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.

5 participants