Uploaded image for project: 'OpenShift GitOps'
  1. OpenShift GitOps
  2. GITOPS-2018

Subscription health check marks it degraded for InstallPlanMissing condition being true even if the operator has no issues

    • False
    • None
    • False
    • Hide
      Before this fix, Subscription health check was marked degraded for missing InstallPlan when more than 5 operators are installed in a project. With this fix, Subscription health check will not be marked as degraded for missing InstallPlan if more than 5 operators are installed in a project.
      Show
      Before this fix, Subscription health check was marked degraded for missing InstallPlan when more than 5 operators are installed in a project. With this fix, Subscription health check will not be marked as degraded for missing InstallPlan if more than 5 operators are installed in a project.

      There is an issue with the health check for subscription object in ArgoCD.

      A project can have max 5 InstallPlan objects. Whenever more than 5 operators are installed in a project, the oldest InstallPlan gets deleted. This is the default behaviour.

      Now if the operators are managed in ArgoCD as apps, the operator whose subscription has 'InstallPlanMissing' condition true is marked degraded which shouldn't always be the case. The operator works fine and just the InstallPlan being missing doesn't affect it's functionality. Also it shows all good on the Installed Operators page. Hence it shouldn't be marked degraded in GitOps just because InstallPlan is missing.

      The health check conditions need changes.

      https://github.com/argoproj/argo-cd/blob/master/resource_customizations/operators.coreos.com/Subscription/health.lua#L11

            [GITOPS-2018] Subscription health check marks it degraded for InstallPlanMissing condition being true even if the operator has no issues

            William Tam made changes -
            Workflow Original: OJA-WF-AM [ 18455090 ] New: OJA-WF-E [ 23322236 ]
            William Tam made changes -
            Sprint
            William Tam made changes -
            Rank New: Ranked higher
            William Tam made changes -
            Sprint New: GITOPS Sprint 235 [ 50314 ]
            William Tam made changes -
            Sprint
            Shipra Singh made changes -
            Labels Original: release-note-item New: release-note-item rn-done-resolved
            DPTP Bot made changes -
            Remote Link New: This issue links to "openshift/openshift-docs#52437: RHDEVDOCS-4661 - Added 1.6.2, 1.4.13 1nd 1.5.7 release notes (Web Link)" [ 1055843 ]
            Ishita Sequeira made changes -
            Release Note Text New: Before this fix, Subscription health check was marked degraded for missing InstallPlan when more than 5 operators are installed in a project. With this fix, Subscription health check will not be marked as degraded for missing InstallPlan if more than 5 operators are installed in a project.
            William Tam made changes -
            Labels New: release-note-item
            William Tam made changes -
            Affects Version/s New: 1.6.0 [ 12358778 ]

            rhn-support-alosingh this would be a part of 1.6.2

            Ishita Sequeira added a comment - rhn-support-alosingh this would be a part of 1.6.2
            Ishita Sequeira made changes -
            Fix Version/s New: 1.6.2 [ 12393407 ]
            Ishita Sequeira made changes -
            Resolution New: Done [ 1 ]
            Status Original: To Do [ 10020 ] New: Closed [ 6 ]

            Hi rhn-support-alosingh , We'll cherry-pick the fix into upstream with Argo CD 2.4.12 (next patch release)
             
             

            Ishita Sequeira added a comment - Hi rhn-support-alosingh , We'll cherry-pick the fix into upstream with Argo CD 2.4.12 (next patch release)    

            Alok Singh added a comment -

            Hi isequeir@redhat.com, Please provide an update on this. The mentioned PR seems to be merged.

            Alok Singh added a comment - Hi isequeir@redhat.com , Please provide an update on this. The mentioned PR seems to be merged.

            PR has been raised with this fix in ArgoCD
            https://github.com/argoproj/argo-cd/pull/10450

            Ishita Sequeira added a comment - PR has been raised with this fix in ArgoCD https://github.com/argoproj/argo-cd/pull/10450
            Ishita Sequeira made changes -
            Assignee New: Ishita Sequeira [ isequeir@redhat.com ]

            gnunn@redhat.com Thanks for sharing the solution. The solution makes sense.

            I will create a  PR for this with the fix.

            Ishita Sequeira added a comment - gnunn@redhat.com Thanks for sharing the solution. The solution makes sense. I will create a  PR for this with the fix.
            John Pitman made changes -
            Rank New: Ranked lower
            John Pitman made changes -
            Sprint Original: GITOPS Sprint 222 [ 45500 ] New: Backlog - Argo CD [ 38826 ]

            Gerald Nunn added a comment -

            I think the solution to this is to modify the health to dig a little deeper, I'm using the following in my health check:

            elseif (condition.type == "InstallPlanMissing" and condition.reason ~= "ReferencedInstallPlanNotFound") then

            See here for full health check I'm using:

            https://github.com/gnunn-gitops/gitops-operator-install/blob/main/openshift-gitops/base/openshift-gitops-cr.yaml#L66

            Gerald Nunn added a comment - I think the solution to this is to modify the health to dig a little deeper, I'm using the following in my health check: elseif (condition.type == "InstallPlanMissing" and condition.reason ~= "ReferencedInstallPlanNotFound") then See here for full health check I'm using: https://github.com/gnunn-gitops/gitops-operator-install/blob/main/openshift-gitops/base/openshift-gitops-cr.yaml#L66
            Jann Fischer made changes -
            Status Original: New [ 10016 ] New: To Do [ 10020 ]
            Jann Fischer made changes -
            Sprint Original: Backlog - Argo CD [ 38826 ] New: GITOPS Sprint 222 [ 45500 ]
            Jann Fischer made changes -
            Priority Original: Critical [ 2 ] New: Major [ 3 ]

            Alok Singh added a comment -

            Hi Team, Is there any update on this?

            Alok Singh added a comment - Hi Team, Is there any update on this?
            John Pitman made changes -
            Sprint New: Backlog - Argo CD [ 38826 ]

            Alok Singh added a comment -

            Hi aveerama@redhat.com,

            It's not an issue with the OLM. It's an expected beahviour to have 5 InstallPlans per namespace. This is to avoid unnecessary high number of InstallPlans in the cluster. It was discussed here - https://coreos.slack.com/archives/C3VS0LV41/p1648839289175399.

            I opened this bug as per the conversation here - https://coreos.slack.com/archives/CMP95ST2N/p1652123107943939.

            Alok Singh added a comment - Hi aveerama@redhat.com , It's not an issue with the OLM. It's an expected beahviour to have 5 InstallPlans per namespace. This is to avoid unnecessary high number of InstallPlans in the cluster. It was discussed here - https://coreos.slack.com/archives/C3VS0LV41/p1648839289175399 . I opened this bug as per the conversation here - https://coreos.slack.com/archives/CMP95ST2N/p1652123107943939 .

            This seems to be an issue with the OLM and not with Argo CD.

            Abhishek Veeramalla added a comment - This seems to be an issue with the OLM and not with Argo CD.
            Alok Singh made changes -
            Component/s New: ArgoCD [ 12335853 ]
            Alok Singh made changes -
            Summary Original: Subscription heath check marks it degraded for InstallPlanMissing condition being true even if the operator has no issues New: Subscription health check marks it degraded for InstallPlanMissing condition being true even if the operator has no issues
            Alok Singh created issue -

              isequeir@redhat.com Ishita Sequeira
              rhn-support-alosingh Alok Singh
              Votes:
              1 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: