Uploaded image for project: 'OCMUI - OpenShift Cluster Manager UI'
  1. OCMUI - OpenShift Cluster Manager UI
  2. OCMUI-2950

[Cluster details] "Rerunning Network Validator by an Unauthorized User" Shows Empty Error Message Even Though the Correct Error Message is Received From Backend

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Critical Critical
    • None
    • None
    • A-Team, Center-UI-Team
    • ACM Console Sprint 265

      I have created this as a bug, but further investigation might be needed to determine if this really is a bug

      This is a followup ticket to track OCMUI-2848's solution which could reveal a backend issue. 

       

      Details

      The broken overview with a type error issue (described on OCMUI-2848) have been solved, but further investigation may be needed to make sure no other issue is present, since it returns 400 with the following reason: "The subnet ID 'subnet-0503cae64b3e201da' does not exist", but as a user which only has the Cluster viewer permission, we should get 403 "Forbidden access to update resource" from the backend as jmekkatt@redhat.com  mentioned on the expected result of OCMUI-2848.
      It has been decided that the linked PR should be merged and promoted to address the urgent undefined error.

      We should see if we have an additional problem, not necessarily due to a bug that we had (OCMUI-2848), it could be a backend issue.

      Let me share with you some details:

      One thing we have to clarify first is that the Network Validation error that the cluster that jmekkatt@redhat.com created to reproduce OCMUI-2848 bug is exactly the same as the Network Validation error that the cluster that dtaylor@redhat.com created. We may not get the same expected result due to a different error the cluster had encountered...

      The error the cluster I was using (the one dtaylor@redhat.com created for me) has, when trying to re-run the Network Validation, is this:
      Instead of 403: Forbidden access to update resource like jmekkatt@redhat.com expects on OCMUI-2848, I get a 400 with reason: "The subnet ID 'subnet-0503cae64b3e201da' does not exist"

      The request which is being sent when pressing the "Rerun network validation" link is: [ POST ] https://api.stage.openshift.com/api/clusters_mgmt/v1/network_verifications

      This could be cause by a backend issue, but I am not entirely certain since I don't know if both clusters have the same Network Validation Error and should get the same outcome.

      This ticket's purpose is to track the ongoing investigation revolving this possible issue.

      Attaching a screenshot with the current status (at least on Dave's cluster which I was using to reproduce OCMUI-2848).

       

      How to Test

      1. Open OCM UI staging and login with an org member user
      2. Open a read only cluster that reported the network validation errors -> Explanation on how to create one, thank you  dtaylor@redhat.com [ for writing this|https://github.com/RedHatInsights/uhc-portal/wiki/Trigger-a-Network-Validation-error-during-cluster-creation]
        (To enable read only access for a cluster, Login as cluster owner in staging and on selected cluster, Grant OCM role access as "Cluster viewer" for the selected user. Both users have to be from the same org, and not the same user)
      3. dtaylor@redhat.com already created this type of cluster on staging and granted me (lkeren-ocm) with the Cluster viewer role - https://prod.foo.redhat.com:1337/openshift/details/s/2rd0TXfjP7XtaYNHp6krpwBvnZJ
        Not sure the cluster will stay active and not forcibly deleted, but thought I can add a link to it anyway 😇
      4. Click the link "Rerun network validation" from User action required banner in Overview page
      5. Inspect the current behavior. Is this a backend issue? We should make sure we send the necessary information correctly to the backend, the error which is received from the backend etc.

       

      Expected results (from OCMUI-2848):

      Not sure it should be the case here, but adding this for reference.

      "Rerun network validation" action should bring inline notification from overview that indicates the permission error (as seen in production). There shouldn't be any type error in the overview page

      See screenshot attached entitled: "Expected result from ocmui-2848"

       

      More Details

      More details can be found the addressing PR of OCMUI-2848 - https://github.com/RedHatInsights/uhc-portal/pull/98 

              kdoberst Kim Doberstein
              lkeren-ocm Lior Keren
              Jayakrishnan Mekkattillam Jayakrishnan Mekkattillam
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: