Bug 1996159 - Dynamic Plugins: Visiting a plugin route directly causes a 404 page to flash briefly
Summary: Dynamic Plugins: Visiting a plugin route directly causes a 404 page to flash ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Management Console
Version: 4.9
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: 4.9.0
Assignee: Vojtech Szocs
QA Contact: Yadan Pei
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-08-20 17:40 UTC by Samuel Padgett
Modified: 2021-10-18 17:48 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-10-18 17:47:54 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github openshift console pull 9559 0 None None None 2021-08-30 17:54:32 UTC
Github openshift console pull 9926 0 None None None 2021-08-30 17:54:42 UTC
Red Hat Product Errata RHSA-2021:3759 0 None None None 2021-10-18 17:48:03 UTC

Description Samuel Padgett 2021-08-20 17:40:46 UTC
We load dynamic plugins asynchronously. This means there is a race if you directly enter a plugin route in the browser URL bar. The page briefly shows a 404 error until the plugin is fully loaded, after which the page appears as expected. We should wait until all plugins load before showing a 404 error.

Comment 1 Samuel Padgett 2021-08-24 18:39:12 UTC
https://github.com/openshift/console/pull/9559 adds a `useDynamicPluginInfo` hook which returns `allPluginsProcessed`. We should be able to update the 404 page to check if `allPluginsProcessed` after that PR merges.

Comment 4 Yadan Pei 2021-09-02 06:26:40 UTC
1. build a dynamic plugin image quay.io/yapei/console-demo-plugin:statusandicon and deploy to the cluster 
$ oc apply -f oc-manifest.yaml 
namespace/console-demo-plugin created
deployment.apps/console-demo-plugin created
service/console-demo-plugin created
consoleplugin.console.openshift.io/console-demo-plugin created

2. Enable the dynamic plugin
3. visit ${CONSOLE}/test-consumer and ${CONSOLE}/example/nav/ page, the page is showing a loading icon until the pages are successfully completely loaded, no 404 page now

Verified on 4.9.0-0.nightly-2021-08-31-123131

Comment 7 errata-xmlrpc 2021-10-18 17:47:54 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 (Moderate: OpenShift Container Platform 4.9.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-2021:3759


Note You need to log in before you can comment on or make changes to this bug.