Bug 1765083

Summary: Websocket connection warnings appear in the browser console
Product: OpenShift Container Platform Reporter: Udi Kalifon <ukalifon>
Component: Management ConsoleAssignee: Rastislav Wagner <rawagner>
Status: CLOSED ERRATA QA Contact: Yadan Pei <yapei>
Severity: medium Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: aos-bugs, jokerman, spadgett, yapei
Target Milestone: ---   
Target Release: 4.3.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Cause: Dashboard's Details card was unnecessarily watching Infrastructure resource Consequence: Errors regarding early websocket connection termination could occur Fix: Details card does not watch Infrastructure resource anymore, it fetches the resource only once Result: No more websocket termination error in browser console
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-01-23 11:09:08 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Udi Kalifon 2019-10-24 10:15:17 UTC
Description of problem:
You can see a lot of websocket connection warnings in the browser console (F12):

WebSocket connection to 'wss://console-openshift-console.apps.rhhi-virt-cluster.qe.lab.redhat.com/api/kubernetes/apis/config.openshift.io/v1/infrastructures?watch=true&fieldSelector=metadata.name%3Dcluster' failed: WebSocket is closed before the connection is established.

Attempted to create multiple websockets for storage.k8s.io~v1~StorageClass.

Attempted to create multiple websockets for core~v1~Event.

and more ...


The errors seem harmless, and the number of errors you get is different every time.


Version-Release number of selected component (if applicable):
4.3.0-0.okd-2019-10-23-224431


How reproducible:
100%


Steps to Reproduce:
1. Open the browser console (F12)
2. Go to the dashboards page


Actual results:
errors and warnings

Comment 1 Samuel Padgett 2019-10-24 12:56:05 UTC
Rastislav, can you investigate since these are coming from the dashboard page?

I'm not sure we need to watch infrastructures at all. The platform shouldn't change. I'm not sure we need to watch the version URL also. In fact, that could cause weird behavior where the version in the UI flaps during an upgrade since different masters might be at different versions.

Comment 2 Samuel Padgett 2019-10-24 12:57:11 UTC
Note that "Attempted to create multiple websockets" means things are working correctly, and we're sharing websockets when multiple components watch the same resource. That is informational rather than an error.

Comment 4 Yadan Pei 2019-11-07 05:11:51 UTC
1. Admin user visit Home -> Dashboards
2. Check console(F12) output

console don't watch 'infrastructures' and no errors about fetching 'infratructure'

I didn't find a way to verify that we're not watching k8s version since it seems a native kubernetes cluster is needed.

Moving to VERIFIED and we can open new bug if the issues still exists on native kubernetes cluster

Verified on 4.3.0-0.nightly-2019-11-06-215135

Comment 6 errata-xmlrpc 2020-01-23 11:09:08 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:0062