MGMT-13664: Don't crash if operator isn't monitored by service - ACM 2.7 - #635
Conversation
This is a backport of MGMT-12471 for ACM 2.7. It includes the changes in pull request openshift#589. The changes in pull request openshift#574 are alse necessary, but they are included in the ACM 2.7 branch already. Currently the operator handler checks if the operator is available in the service, but it doesn't take into account that the operator may have been removed from the list of managed operators. That results in a nil pointer exception and a crash of the controller. This patch fixes that adding a nil check to the relevant code. Related: https://issues.redhat.com/browse/MGMT-13664 Related: https://issues.redhat.com/browse/MGMT-12471 Related: openshift#589 Related: openshift#574 Signed-off-by: Juan Hernandez <juan.hernandez@redhat.com>
|
@jhernand: This pull request references MGMT-13664 which is a valid jira issue. DetailsIn 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. |
1 similar comment
|
@jhernand: This pull request references MGMT-13664 which is a valid jira issue. DetailsIn 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. |
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## release-ocm-2.7 #635 +/- ##
================================================
Coverage 52.18% 52.18%
================================================
Files 14 14
Lines 2727 2727
================================================
Hits 1423 1423
Misses 1174 1174
Partials 130 130
|
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: filanov, jhernand The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
@jhernand: all tests passed! Full PR test history. Your PR dashboard. DetailsInstructions 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. |
This is a backport of MGMT-12471 for ACM 2.7. It includes the changes in pull request #589. The changes in pull request #574 are alse necessary, but they are included in the ACM 2.7 branch already.
Currently the operator handler checks if the operator is available in the service, but it doesn't take into account that the operator may have been removed from the list of managed operators. That results in a nil pointer exception and a crash of the controller. This patch fixes that adding a nil check to the relevant code.
Related: https://issues.redhat.com/browse/MGMT-13664
Related: https://issues.redhat.com/browse/MGMT-12471
Related: #589
Related: #574