Bug 772681 - Exception thrown in UI when clicking child resource node in discovery queue
Summary: Exception thrown in UI when clicking child resource node in discovery queue
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: RHQ Project
Classification: Other
Component: Core UI
Version: 4.2
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: John Sanda
QA Contact: Mike Foley
URL:
Whiteboard:
Depends On:
Blocks: 694221
TreeView+ depends on / blocked
 
Reported: 2012-01-09 16:28 UTC by John Sanda
Modified: 2013-09-02 07:20 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-09-02 07:20:58 UTC
Embargoed:


Attachments (Terms of Use)

Description John Sanda 2012-01-09 16:28:12 UTC
Description of problem:
In the feature/gwt-upgrade branch, when I go to the discovery queue and click on the check box of child resource (i.e., leaf node), I get a globally uncaught exception in the UI. This happens when only when I expand the platform node without selecting it and then selecting one of the child nodes. This does not happen in the master branch.

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


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 John Sanda 2012-01-09 16:36:04 UTC
The exception I see when running in GWT dev mode is,

Caused by: java.lang.ClassCastException: com.smartgwt.client.widgets.grid.ListGridRecord cannot be cast to com.smartgwt.client.widgets.tree.TreeNode 	at org.rhq.enterprise.gui.coregui.client.inventory.resource.discovery.ResourceAutodiscoveryView.updateButtonEnablement(ResourceAutodiscoveryView.java:412) 	at org.rhq.enterprise.gui.coregui.client.inventory.resource.discovery.ResourceAutodiscoveryView.access$3(ResourceAutodiscoveryView.java:391) 	at org.rhq.enterprise.gui.coregui.client.inventory.resource.discovery.ResourceAutodiscoveryView$3.onSelectionChanged(ResourceAutodiscoveryView.java:264)


It appears that this might be due to usage of what is now a deprecated API in ResourceAutoDiscoveryView.

Comment 2 John Sanda 2012-01-09 19:36:40 UTC
I have come across a couple SmartGWT forum posts that lead me to believe that this issue could be a regresssion in SmartGWT itself that was introduced in version 2.5. The aforementioned posts are,

http://forums.smartclient.com/showthread.php?t=18457&highlight=TreeNode+ClassCastException

http://forums.smartclient.com/showthread.php?t=19912

Comment 3 John Sanda 2012-01-10 19:26:59 UTC
Made change to avoid casting ListGridRecord to TreeNode in feature/gwt-upgrade branch.

commit hash: 1163194d1955b334dfe783876b7f052b306bc737

Comment 4 John Sanda 2012-02-17 16:46:43 UTC
This commit has been merged into master.

Comment 5 Sunil Kondkar 2012-04-16 12:55:27 UTC
Verified on build#1334 (Version: 4.4.0-SNAPSHOT Build Number: ca5eecb)

No exception is thrown on clicking child resource node in discovery queue.

Comment 6 Heiko W. Rupp 2013-09-02 07:20:58 UTC
Bulk closing of issues that were VERIFIED, had no target release and where the status changed more than a year ago.


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