Created attachment 1871227 [details] cpu usage charts not loaded Description of problem: when viewing monitoring Dashboards, we can observe many consoleFetch failed errors, in the error messages we can see that sometimes workload/workload_type/namespace value in the fetch request are not set correctly. it seems dropdown default values are not passed properly in consoleFetch, which cause some charts can not be loaded successfully Version-Release number of selected component (if applicable): 4.11.0-0.nightly-2022-04-01-172551 How reproducible: very often Steps to Reproduce: 1. cluster admin user navigate to Observe -> Dashboards page, by default it will load grafana-dashboard-api-performance?apiserver=kube-apiserver&period=5m 2. Choose Kubernetes/Compute Resources/Workload dashboard, by default, it will load workloads from namespace/default, ignore the default behavior and go next 3. In Namespace dropdown, choose 'openshift-console', Type and Workload dropdown will have default values selected, check if 'CPU Usage' data can be loaded successfully, at the same time we monitor `console` and `network` tab output in browser developer tools Actual results: 3. CPU Usage data is empty, it doesn't show a loader neither show errors. If we keep the browser window untouched(didn't scroll or click anything), it will always be empty and we can see some errors in `console` tab, such as consoleFetch failed for url /api/prometheus/api/v1/query_range?start=1649314944.003&end=1649316744.003&step=60&query=sum%28%0A++++node_namespace_pod_container%3Acontainer_cpu_usage_seconds_total%3Asum_irate%7Bcluster%3D%22%22%2C+namespace%3D%22openshift-dns-operator%22%7D%0A++*+on%28namespace%2Cpod%29%0A++++group_left%28workload%2C+workload_type%29+namespace_workload_pod%3Akube_pod_owner%3Arelabel%7Bcluster%3D%22%22%2C+namespace%3D%22openshift-dns-operator%22%2C+workload%3D%22%22%2C+workload_type%3D%22%22%7D%0A%29+by+%28pod%29%0A&timeout=30s DOMException: The user aborted a request. consoleFetch failed for url /api/prometheus/api/v1/query_range?start=1649313972.901&end=1649315772.901&step=60&query=sum%28%0A++++node_namespace_pod_container%3Acontainer_cpu_usage_seconds_total%3Asum_irate%7Bcluster%3D%22%22%2C+namespace%3D DOMException: The operation was aborted. penshift-console%22%7D%0A++*+on%28namespace%2Cpod%29%0A++++group_left%28workload%2C+workload_type%29+namespace_workload_pod%3Akube_pod_owner%3Arelabel%7Bcluster%3D%22%22%2C+namespace%3D undefined penshift-console%22%2C+workload%3D%22%22%2C+workload_type%3D%22%22%7D%0A%29+by+%28pod%29%0A&timeout=30s main-chunk-a0290c8f3c7a0ae9b12b.min.js:1 consoleFetch failed for url /api/prometheus/api/v1/query_range?start=1649314944.003&end=1649316744.003&step=60&query=sum%28%0A++++node_namespace_pod_container%3Acontainer_cpu_usage_seconds_total%3Asum_irate%7Bcluster%3D%22%22%2C+namespace%3D%22openshift-dns-operator%22%7D%0A++*+on%28namespace%2Cpod%29%0A++++group_left%28workload%2C+workload_type%29+namespace_workload_pod%3Akube_pod_owner%3Arelabel%7Bcluster%3D%22%22%2C+namespace%3D%22openshift-dns-operator%22%2C+workload%3D%22%22%2C+workload_type%3D%22%22%7D%0A%29+by+%28pod%29%0A&timeout=30s DOMException: The user aborted a request. Expected results: charts should be loaded successfully every time we visit the page Additional info:
about how it is reproducible, maybe it is sometimes
same issue with 4.10.0-0.nightly-2022-04-23-095048
see the attached gif, tested with 4.11.0-0.nightly-2022-06-23-092832, Choose Kubernetes/Compute Resources/Workload dashboard, default namespace is default, choose other project, such as openshift-authentication, "CPU Usage" graph would show "No datapoints found." at the first, then can show the graph for "CPU Usage", please confirm if is expected
Thanks Junqi. There's an additional issue where in some cases the "No datapoints found" message is briefly shown before the graph is rendered.
based on comment 7 and comment 11, the main problem is fixed, set the bug to VERIFIED and split the additional issue to bug 2101274
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 (Important: OpenShift Container Platform 4.11.0 bug fix and security update), 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/RHSA-2022:5069