[jbosstools-issues] [JBoss JIRA] (JBIDE-22810) OpenShift Explorer: empty at start

Rob Stryker (JIRA) issues at jboss.org
Thu Aug 3 15:29:00 EDT 2017


    [ https://issues.jboss.org/browse/JBIDE-22810?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13444153#comment-13444153 ] 

Rob Stryker commented on JBIDE-22810:
-------------------------------------

So on Windows, this occurred for me 100% of the time (once I followed the exact instructions). After a lot of inspection, I've discovered the following:

1) org.jboss.tools.openshift.core has activator OpenShiftCoreActivator
2) org.jboss.tools.openshift.express.core has activator ExpressCoreActivator
3) o.j.t.openshift.ui extends the common navigator via ext. pt via the OpenShiftExplorerContentProvider class. 
   a) OpenShiftExplorerContentProvider creates / uses the OpenShiftUIModel
       1) OpenShiftUIModel (in o.j.t.o.ui) calls registry.getAll(Connection.class), which loads the o.j.t.o.core activator and initializes it
4) o.j.t.openshift.express.ui extends the common navigator via ext. pt via the ExpressExplorerContentProvider class. 
   a) ExpressExplorerContentProvider calls registry.getAll(ExpressConnection.class) which loads the o.j.t.o.express.core activator and initializes it

Basically, the driver of the plugin loaders is the UI extensions to the navigator. The express ui will indirectly cause the express core to be loaded. The v3 ui will cause the v3 core to be loaded. There is no error with the plugins not being loaded, and no error with the content providers returning empty arrays due to some race condition. 

Even when the view is empty, the content providers **ARE** returning the proper results. So, why is the view empty?  I can't 100% figure it out, but I suspect it's something in how the content providers are returning their results. They're unable to discover the proper treepath to inject it into the tree, or something. Either way, I can't figure it out at the moment.   It could be something as simple as ConnectionWrapper  requiring a .equals() or .hashCode(). I remember such problems in CNF before. 

Despite all this, a 1 line fix to force a refresh while the view is being created fixes this situation 100% of the time in my environment. PR is attached. 

> OpenShift Explorer: empty at start
> ----------------------------------
>
>                 Key: JBIDE-22810
>                 URL: https://issues.jboss.org/browse/JBIDE-22810
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: openshift
>    Affects Versions: 4.4.1.AM1
>         Environment: windows
>            Reporter: Rob Stryker
>            Assignee: Viacheslav Kabanovich
>              Labels: explorer, openshift_v3, windows
>             Fix For: 4.5.1.AM1
>
>         Attachments: EmptyViewAtStart.png
>
>
> When I close Eclipse with OpenShift Explorer not visible (by selecting another view in the same area of the workbench, or by switching another perspective), after I reopen Eclipse, and select OpenShift Explorer. I push 'Connect' button and can select for authenticating any available connection, it happens successfully, but the view remains empty. After I close/reopen OpenShift Explorer, it is opened populated with connections.
> I have to add that it is not 100% reproducible. What is interesting, when starting it in the debugger, I reproduce it around 80%, while in normal run the probability is very low if do it leisurely, but can be increased to 50% if take the task with some dedication and find the right moment (very soon after the window opens) to select the explorer. 



--
This message was sent by Atlassian JIRA
(v7.2.3#72005)


More information about the jbosstools-issues mailing list