Bug 785847 - Agent performs excessive IO when sending drift content to server
Agent performs excessive IO when sending drift content to server
Status: CLOSED CURRENTRELEASE
Product: RHQ Project
Classification: Other
Component: Agent (Show other bugs)
4.2
Unspecified Unspecified
urgent Severity unspecified (vote)
: ---
: JON 3.0.1
Assigned To: John Sanda
Mike Foley
:
Depends On: jon30-sprint10/rhq43-sprint10 767205
Blocks: 707225 jon310-sprint11/rhq44-sprint11
  Show dependency treegraph
 
Reported: 2012-01-30 13:52 EST by Charles Crouch
Modified: 2015-02-01 18:27 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 767205
Environment:
Last Closed: 2013-09-03 11:13:56 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Charles Crouch 2012-01-30 13:52:15 EST
+++ This bug was initially created as a clone of Bug #767205 +++

Description of problem:
When the server requests content for files previously reported, the agent receives a list of SHAs. The agent then performs a reverse look up, finding the corresponding file system path for each SHA. This involves reading the current snapshot file. The problem is that the snapshot file is read over and over again for each SHA. When the server sends a lot of SHAs, like with the initial snapshot, this results in excessive and unnecessary IO. The agent only needs to read the snapshot file once. Doing so will increase the memory usage for the duration of that method call; however, the overall execution time for the method will substantially be reduced as the number of SHAs passed to it increases in size. The increased memory footprint is likely on the order of bytes or 10s of kilobytes whereas the decrease in execution time could be on the order of milliseconds or seconds.

For testing, this should result in no change in functionality other than increased logging.

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


How reproducible:


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


Expected results:


Additional info:

--- Additional comment from jsanda@redhat.com on 2011-12-14 21:01:47 EST ---

DriftFilesSender has been refactored so that it only reads the snapshot file on disk once when looking up files by SHA.

master commit hash: 9f18aee38ed44f992ce26e7f8141a057af716533

--- Additional comment from mfoley@redhat.com on 2011-12-15 14:11:48 EST ---

verified thru ad hoc testing on drift feature
Comment 2 John Sanda 2012-02-06 10:34:09 EST
Fix has been pushed to release/jon3.0.x branch.

commit hash: 4886f73e5afb984f4039318da21cc5fbd37482bc
Comment 3 Charles Crouch 2012-02-06 18:42:29 EST
Setting to MODIFIED while waiting for this to appear in a build
Comment 4 Simeon Pinder 2012-02-09 14:36:41 EST
Moving this to ON_QA as new RC3 binary available here:
https://brewweb.devel.redhat.com//buildinfo?buildID=198086
Comment 5 Mike Foley 2012-02-09 16:13:04 EST
smoke tested Drift
Comment 6 Heiko W. Rupp 2013-09-03 11:13:56 EDT
Bulk closing of old issues in VERIFIED state.

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