-
Notifications
You must be signed in to change notification settings - Fork 72
OCPBUGS-5523: Catalog, fatal error: concurrent map read and map write #429
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
OCPBUGS-5523: Catalog, fatal error: concurrent map read and map write #429
Conversation
@dtfranz: This pull request references Jira Issue OCPBUGS-5523, which is invalid:
Comment The bug has been updated to refer to the pull request using the external bug tracker. In response to this:
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. |
/cherry-pick 4.10 |
@dtfranz: once the present PR merges, I will cherry-pick it on top of 4.10 in a new PR and assign it to you. In response to this:
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. |
… (#2913) * protected subscriptionSyncCounters access to prevent concurrent map writes Signed-off-by: Daniel Franz <[email protected]> * organize map and mutex into single struct Signed-off-by: Daniel Franz <[email protected]> * initialize struct Signed-off-by: Daniel Franz <[email protected]> * use RWMutex to allow concurrent reads Signed-off-by: Daniel Franz <[email protected]> Upstream-repository: operator-lifecycle-manager Upstream-commit: 2a49a4dddeb3e0fc38b44925bf9bd0d3931d4ff4
Signed-off-by: dtfranz <[email protected]>
042e869
to
b2c4c2d
Compare
/approve |
/test e2e-gcp-ovn |
/retest |
@dtfranz seems like a gcp failure:
|
/retest |
@dtfranz: all tests passed! Full PR test history. Your PR dashboard. 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. |
/jira refresh |
@dtfranz: This pull request references Jira Issue OCPBUGS-5523, which is invalid:
Comment In response to this:
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. |
/jira refresh |
@dtfranz: This pull request references Jira Issue OCPBUGS-5523, which is invalid:
Comment In response to this:
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. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: awgreene, dtfranz, tmshort 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 |
/jira refresh |
@dtfranz: This pull request references Jira Issue OCPBUGS-5523, which is valid. 3 validation(s) were run on this bug
No GitHub users were found matching the public email listed for the QA contact in Jira ([email protected]), skipping review request. In response to this:
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. |
@dtfranz: All pull requests linked via external trackers have merged: Jira Issue OCPBUGS-5523 has been moved to the MODIFIED state. In response to this:
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. |
@dtfranz: cannot checkout In response to this:
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. |
/cherry-pick release-4.10 |
@dtfranz: #429 failed to apply on top of branch "release-4.10":
In response to this:
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. |
OCPBUGS-5523: Catalog, fatal error: concurrent map read and map write Signed-off-by: dtfranz <[email protected]>
OCPBUGS-5523: Catalog, fatal error: concurrent map read and map write Signed-off-by: dtfranz <[email protected]> Upstream-repository: operator-lifecycle-manager Upstream-commit: 2a49a4dddeb3e0fc38b44925bf9bd0d3931d4ff4
/cherry-pick release-4.12 |
@awgreene: new pull request created: #436 In response to this:
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. |
Problem:
The metrics pkg uses a shared map var to keep a record of Prometheus counters from Subscription objects, which is not protected from concurrent read/write access. This can result in container restarts.
Solution:
This PR adds a mutex to lock and unlock before and after each map access instance. Any number of requests to read from the map may happen concurrently, but when a write operation occurs nothing else can access the map until the write is finished.
Motivation for the change:
OCPBUGS-5523