openshift-assisted / assisted-installer-ui

The Assisted Installer User Interface
https://console.redhat.com/openshift/create/datacenter
Apache License 2.0
9 stars 36 forks source link

MGMT-14678: Day2 - host not showing up in the UI session that generated it, but is shown in another session #2292

Closed jgyselov closed 1 year ago

jgyselov commented 1 year ago

https://issues.redhat.com/browse/MGMT-14678

If /openshift-versions took too long to load, the UI would create multiple Day2 clusters - each one replacing the previous one.

I believe that in the KNI tests, without the delay before clicking the "Add hosts" button on the Add hosts tab, the UI opens the ISO modal with the first created cluster. However, in the background, it replaces this day2 cluster with the ones created later. This session cannot show the discovered host because it's polling for a different cluster - the last one that was created.

In another tab/session, the UI takes the first day2 cluster from the list. Coincidentally, it's the same one the ISO was generated for - so the discovered host is shown.

This PR should ensure that only one Day2 cluster is created when the Add hosts tab is accessed for the first time.

openshift-ci-robot commented 1 year ago

@jgyselov: This pull request references MGMT-14678 which is a valid jira issue.

In response to [this](https://github.com/openshift-assisted/assisted-installer-ui/pull/2292): >https://issues.redhat.com/browse/MGMT-14678 > >If `/openshift-versions` took too long to load, the UI would create multiple Day2 clusters - each one replacing the previous one. > >I believe that in the [KNI tests, without the delay](https://gitlab.cee.redhat.com/ocp-edge-qe/kni-assisted-installer-auto/-/merge_requests/1150/diffs) before clicking the "Add hosts" button on the Add hosts tab, the UI opens the ISO modal with the first created cluster. However, in the background, it replaces this day2 cluster with the ones created later. This session cannot show the discovered host because it's polling for a different cluster - the last one that was created. > >In another tab/session, the UI takes the first day2 cluster from the list. Coincidentally, it's the same one the ISO was generated for - so the discovered host is shown. > >This PR should ensure that only one Day2 cluster is created when the Add hosts tab is accessed for the first time. Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.
openshift-ci[bot] commented 1 year ago

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: ammont82, jgyselov, jkilzi

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files: - **[OWNERS](https://github.com/openshift-assisted/assisted-installer-ui/blob/master/OWNERS)** Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
openshift-ci[bot] commented 1 year ago

New changes are detected. LGTM label has been removed.