Bug 872690 - InventoryContext.requestChildResourcesDiscovery blocks forever in ResourceComponent.start()
Summary: InventoryContext.requestChildResourcesDiscovery blocks forever in ResourceCom...
Keywords:
Status: NEW
Alias: None
Product: RHQ Project
Classification: Other
Component: Plugin Container
Version: unspecified
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Nobody
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-11-02 18:18 UTC by Elias Ross
Modified: 2022-03-31 04:28 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description Elias Ross 2012-11-02 18:18:29 UTC
The method InventoryContext.requestChildResourcesDiscovery() will hang a component's start method indefinitely, e..g

public class MonitorComponent
    implements ResourceComponent
{
    public void start(ResourceContext context) {
        // notice something during init
        context.getInventoryContext().requestChildResourcesDiscovery();
    }
}

This method should be changed to either throw an exception or not block. Or at least document its use.

Also, InventoryContext could use some class-level JavaDoc.

     *
     * @return discovered child resources
     */
    public void requestChildResourcesDiscovery();

^^ does not return anything (would be nice if it did)


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