Red Hat Bugzilla – Bug 1011503
Create group resource type control temporarily displays "No items to display" if resource type query takes too long to execute
Last modified: 2014-08-27 17:39:41 EDT
+++ This bug was initially created as a clone of Bug #817825 +++
Description of problem: UI hangs during Create Group dialog ...3rd-level of nested menus (see screenshot)
Version-Release number of selected component (if applicable): RHQ4.4
Steps to Reproduce:
1. Create a group
2. in the Search criteria for "Type" ... get to the third-level of menu (see screenshot)
3. screen says "loading" ... but it never loads
Actual results: screen says "loading" ... but it never loads
Expected results: 3rd level of nested menu loads and is selectable as a search criteria
Additional info: screenshot
--- Additional comment from Mike Foley on 2012-05-01 09:35:58 EDT ---
--- Additional comment from Mike Foley on 2012-05-01 14:31:12 EDT ---
maybe "hangs" isn't the right word ... it says "loading" and never displays the 3rd level of menu
--- Additional comment from Mike Foley on 2012-05-08 15:33:39 EDT ---
per BZ triage ... crouch, loleary, foley
--- Additional comment from mark yarborough on 2012-11-06 15:05:25 EST ---
Per 3.1.2 triage with loleary, mfoley, ccrouch, asantos: Okay to move to JON 3.2.
--- Additional comment from John Mazzitelli on 2013-05-02 14:16:22 EDT ---
the GUI component that this menu is is a SmartGGWT IPickTreeItem:
and apparently, this is how it works. Its not hanging, there just isn't any real child menu items. We override the the setEmptyMenuMessage to "Loading..." for some unknown reason though... the default, as per the SmartGWT docs:
is "No items to display" - maybe that would be better to show. Or maybe we think of something else to say other than "Loading..."
--- Additional comment from John Mazzitelli on 2013-05-02 14:53:35 EDT ---
Looking at the items in here, I've come to the conclusion I don't like this menu :) Need to figure out a better way. The platforms are confusing in here - and why does Windows have children but the other platforms don't?
--- Additional comment from John Mazzitelli on 2013-05-06 19:10:08 EDT ---
commit to master : e589245
this is a pita. I checked in something - it doesn't show "Loading..." anymore (the label is now "No items to display"). It also shows leaf nodes now for all types.
HOWEVER, the platform plugin's platform types should have all the same children (the platform services). Instead, due to the way the type hierarchy works and the way we are loading the data, there is only one platform service type menu item (they aren't duplicated across all platform types in the menus). This means you'll see, say, the CPU item under Windows but not under anywhere else. You might see "File System" under, say, Linux but not under Windows or anything else. Its random and based on which type is loaded first.
This is not trivial to fix. I spent alot of time trying to play around with things and couldn't get it to work (I even tried using GWT Menu objects rather than IPickTreeItem objects but ran into other problems that were worse.
So, I will leave this open on the off-chance someone else wants to give this a try. At least I got it where now most types no longer show "Loading..." as a leaf node, so I got that going for me (that and total-consciousness, which is nice).
--- Additional comment from Heiko W. Rupp on 2013-08-12 04:34:17 EDT ---
This was done in master some time ago, so moving to modified, as it will be in ER1
Now the problem is, if the server is located on remote(say in US) and the client is somewhere (say in India) with slower bandwidth network connectivity, initially the menu list as "No Items to Display" after few seconds it's listing all the available sub menus.
I feel we might display "Loading..." on root menu and on sub menu trees "No items to display" if we really don't have any items to display on sub tree.
Build Number: 54dd29c:464a643
GWT Version: 2.5.0
SmartGWT Version: 3.0
Created attachment 802211 [details]
no items to display
screen shot is attached
Seems like we should be able to set the value to "No items to display" once the query is done executing? Can't that be handled by an exception being thrown by the data handler and caught by the control. In other words, use "Loading..." by default and if the query returns 0 results, throw an exception indicating no data and then have the control catch that exception and change the value from "Loading..." to "No items to display"?
Just a thought.
I am also updating the BZ summary to properly reflect this new issue. The incorrect title and comment 0 was inherited from a clone of a related issue.