Bug 1002238 - Availability check errors in UI after undeploying a storage node
Summary: Availability check errors in UI after undeploying a storage node
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: RHQ Project
Classification: Other
Component: Core UI
Version: 4.9
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: RHQ 4.9
Assignee: Jirka Kremser
QA Contact: Mike Foley
URL:
Whiteboard:
Depends On:
Blocks: 951619
TreeView+ depends on / blocked
 
Reported: 2013-08-28 17:14 UTC by John Sanda
Modified: 2023-09-14 01:49 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-09-09 13:06:39 UTC
Embargoed:


Attachments (Terms of Use)

Description John Sanda 2013-08-28 17:14:04 UTC
Description of problem:
When a storage node is undeployed, the corresponding resource gets un-inventoried in the background (i.e., in a thread other than the one servicing the UI request). After the storage node is removed from inventory, you will start seeing errors during the live availability check. The exception reported in the server log is,

08:36:29,250 WARN  [org.rhq.enterprise.gui.coregui.server.gwt.ResourceGWTServiceImpl] (http-/0.0.0.0:7080-101) Sending exception to client: [1377693389250] : org.rhq.enterprise.server.resource.ResourceNotFoundException: A Resource with id 10591 does not exist in inventory.
        at org.rhq.enterprise.server.resource.ResourceManagerBean.getResourceById(ResourceManagerBean.java:754) [rhq-server.jar:4.9.0-SNAPSHOT]
        at org.rhq.enterprise.server.resource.ResourceManagerBean.getLiveResourceAvailability(ResourceManagerBean.java:2445) [rhq-server.jar:4.9.0-SNAPSHOT]

I believe this is happening because the UI is not aware of the resource being removed from inventory. Doing a page refresh resolves the issue. We need to add logic in the storage node admin UI to prevent this errors in a way that does not force the user to do a page refresh.


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


How reproducible:



Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Jirka Kremser 2013-09-09 13:06:39 UTC
ResourceManagerBean.getLiveResourceAvailability() is a method that is called by the resource page (/#Resource/${resId}).

This should happen only if the user is steering to the page with the resource (that was removed from the inventory meanwhile in the background). Once the resource is removed it shouldn't be showed in the resource tree anymore => no way to navigate to the page with it.

There was an issue with the live availability feature causing the polling job to query the server even if the user left (closed) the page with the resource (the job wasn't cancelled). This should be now fixed and the error should not occur on the storage node UI. 

To me, it does make sense to see ResourceNotFoundException if the resource wasn't found and having the page with the resource opened. It is same as if:
1) user A will open the browser with RHQ on some resource, 
2) user B from other browser with RHQ would uninventory the resource,
3) user A would get the same type of error

btw. 2) can be also done via CLI

Comment 2 Red Hat Bugzilla 2023-09-14 01:49:49 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 1000 days


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