Bug 1030399

Summary: Resource on agent has fields populated that are for server usage only
Product: [Other] RHQ Project Reporter: Heiko W. Rupp <hrupp>
Component: Plugin Container, PerformanceAssignee: Heiko W. Rupp <hrupp>
Status: CLOSED CURRENTRELEASE QA Contact: Mike Foley <mfoley>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 4.9CC: hrupp
Target Milestone: ---   
Target Release: RHQ 4.10   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-04-23 12:32:00 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On:    
Bug Blocks: 1069642    

Description Heiko W. Rupp 2013-11-14 11:19:37 UTC
Resource on agent holds full ancestry information, but ancestry is never used inside the agent. We should clean that out.

Example from a local agent:

280 times:

0_:_10791_:_rhq.ear/rhq-core-domain-ejb3.jar#rhqpu_::_0_:_10573_:_jpa_::_0_:_10527_:_rhq-core-domain-ejb3.jar_::_0_:_10477_:_rhq.ear_::_0_:_10461_:_EAP (127.0.0.1:6990) RHQ Server_::_0_:_10001_:_snert

using 116kB of memory


Even better: we should not even forward that ancestry from server to agent to also save on bandwidth.

Other items, the agent (currently) does not need are the location, description (?), alertConditions, modifiedBy (?)

If they are not needed, they also should be nulled out.

Comment 1 Heiko W. Rupp 2014-02-05 10:02:57 UTC
This is now done in org.rhq.core.pc.inventory.InventoryManager#compactResource and other places. The ancestry from above is removed by calling org.rhq.core.domain.resource.Resource#addChildResourceWithoutAncestry that does not populate the ancestry when building the resource hierarchy inside the agent.

master 031058c

Comment 2 Heiko W. Rupp 2014-04-23 12:32:00 UTC
Bulk closing of 4.10 issues.

If an issue is not solved for you, please open a new BZ (or clone the existing one) with a version designator of 4.10.