Bug 697590 - full page reload in IE when clicking on top menu items or on most hyperlinks
full page reload in IE when clicking on top menu items or on most hyperlinks
Product: RHQ Project
Classification: Other
Component: Core UI (Show other bugs)
Unspecified Unspecified
urgent Severity high (vote)
: ---
: ---
Assigned To: Ian Springer
Corey Welton
Depends On:
Blocks: rhq401
  Show dependency treegraph
Reported: 2011-04-18 13:07 EDT by Simeon Pinder
Modified: 2013-08-05 20:39 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed:
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Simeon Pinder 2011-04-18 13:07:26 EDT
Description of problem:
In IE8 and 7 there is pretty bad performance when clicking on top level menu items like Bundles, Administration,etc.  It looks like each top level menu selection causes a full F5 application refresh where the entire page (including shared menu) is rebuilt on each selection. 

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Using IE8 or IE 7, log into RHQ and wait for all page loading to complete. 
2. Click the 'Bundles' link and then the 'Administration' link and pay attention to the time that passes before load is complete. 
3. Make a note of whether the entire page is reloaded.
Actual results:
-IE8 can take 9s to load pages while Chrome and FF load the same pages in 1s. 
-IE7 can take 90s to load pages while Chrome and FF load the same pages in 1.5s.

Expected results:
Comparable load times on IE as with other browsers.

Additional info:
- We should check to make sure there isn't a different IE profile that needs to be loaded/added during smartgwt compilation that is dramatically affecting performance here. 
- We should add browser cache deletion to testing here to see if that affects performance here as well.
Comment 1 Simeon Pinder 2011-04-18 13:15:06 EDT
The above results were recorded using two different client boxes point as same external server:
Windows 7 IE8 (8.0.7600.16385)
Windows XP IE7 (7.0.5730.13)
Comment 2 Mike Foley 2011-04-18 14:04:52 EDT
removing FF perf comment, new issue is in https://bugzilla.redhat.com/show_bug.cgi?id=697699
Comment 3 Mike Foley 2011-04-18 19:29:00 EDT
documenting that i have been testing with IE 8.07600.16385 and have not seen the performance issue clicking on top level menu items.
Comment 4 Ian Springer 2011-04-21 17:10:23 EDT
I checked in a possible fix for this - [master a5c3401]. Simeon, can you give it another try w/ HEAD?
Comment 5 Simeon Pinder 2011-04-22 10:36:46 EDT
No difference.  Same performance on IE 7 and 8 as before. Clicking on top menu items and some links(Res/Group>Monitor>(host)) still result in full page refresh each time. I build for all platforms IE6,IE8. 

Anyone besides mike tried this?
Comment 6 Ian Springer 2011-04-22 11:51:56 EDT
This is due to a well-known IE bug. GWT works around the bug if you use its history API to change the fragment portion of the URL. However, if you use raw HTML, as we are doing in MenuBarView, you don't get the GWT workaround magic. The best way to resolve this, would be to convert the raw HTML in MenuBarView to GWT widgets. However, if we don't want to undertake that right now, the following provides a number of workarounds that can be used to make raw HTML links work in IE:

Comment 7 Ian Springer 2011-04-22 12:44:33 EDT
Note, this is going to be an issue on IE in a bunch of other places throughout the GUI, not just for the menu bar. There are many grid and form fields where we set the value to raw HTML in order to output links.

The raw HTML could be replaced with GWT widgets as follows:

- replace StaticTextItems that need to contain links with CanvasItems
- for grids that need to have one or more columns whose values are links, subclass ListGrid and override createRecordComponent() (see http://www.smartclient.com/smartgwt/showcase/#grid_cell_widgets for an example)
- for Labels, make sure the content does not contain raw links; if the whole Label is meant to be a link, use a click handler; if only part of the label should be a link, perhaps add another Label as a child of the outer Label, and add a click handler to the inner Label
- for other places which use GWT's HTML class or SmartGWT's HTMLFlow class to insert raw HTML as MenuBarView does, replace the HTML or HTMLFlow with GWT widgets
Comment 8 Charles Crouch 2011-04-25 10:41:22 EDT
With Ian to try out each type of GWT widget fix described in comment 7 on a branch of master
Comment 9 Ian Springer 2011-05-03 17:53:16 EDT
[master 4c0c992] adds a magic Event.NativePreviewHandler that makes anchor tags not reload the whole page in IE. This fixes all of the links in the app, but does not fix the top menu items, since they are not currently implemented as true links / anchor tags.

My next step is to merge in some of my widget work from the ie-fragment-fix branch to get rid of many of the raw HTML links, with the large exception of links within ListGrids/Tables, which will be kept as raw HTML because we encountered too many issues with using the ListGrid.createRecordComponent() API to define custom Canvases for table cells.
Comment 10 Ian Springer 2011-05-11 12:26:32 EDT
[master b4c21e] re-implements the top menu bar using SmartGWT widgets, rather than raw HTML.

The Event.NativePreviewHandler and the new widget-based top menu have also been cherry-picked into the release-4.0.0 branch for inclusion in RHQ 4.0.1.
Comment 11 Mike Foley 2011-05-11 13:21:35 EDT
verified RHQ 4.0.1 from IE8.
Comment 12 Corey Welton 2011-05-23 21:12:59 EDT
Bookkeeping - closing bug - fixed in recent release.
Comment 13 Corey Welton 2011-05-23 21:12:59 EDT
Bookkeeping - closing bug - fixed in recent release.
Comment 14 Corey Welton 2011-05-23 21:13:08 EDT
Bookkeeping - closing bug - fixed in recent release.

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