Description of problem:
Currently the guest agent message handling contains inefficiencies which cause quite significant time spent during handling of messages sent by guest agents of VMs.
The 2 most significant portions of this have been identified as the filtering of bad characters and the dispatching of the message to the appropriate handler.
This bug shall address these issues.
might want to consider backporting based on profiling results with the patch/solution.
I have made some investigations:
I have produced a 25 MiB data capture of the messages sent by the guest agent including bigger application lists reported by windows guest agents.
I written a little script which read each message from the data capture and passed it as string to the line processing. Which decodes the utf-8 data, parses the json to an python object and then applies the filtering.
The current solution takes around 20-22 seconds on my machine.
Another solution suggested by Nir Sofer (can be seen in attached gerrit patch)
takes around 14-16 seconds on each run.
The pure python approach as suggested by Nir has a performance gain of 30%.
For the sake of completeness I have been attempting to try a non-optimized c++ version of parsing json, decoding the object etc, takes around 800ms on my computer for the same 25 MiB. Which just proves that there's plenty of room for improvement. We'll have to see however how we would do this, and this is not something what would go into a backport.
As the discussion came up we're now investigating to post-pone the filtering to a later point, and filter the data only for XMLRPC requests before it's passed along. And only parse certain fields.
This is a discussion which has to be continued on the mailing list, to see if this is relevant.
3.5.1 is already full with bugs (over 80), and since none of these bugs were added as urgent for 3.5.1 release in the tracker bug, moving to 3.5.2
postponing to 3.5.4
acks would be nice...
Removing from 3.5.z. No customer case. Impact insufficient for 3.5.z.
Moved pending patch out of scope of this BZ and created a new BZ#1265144 for it
This bug was fixed and is slated to be in the upcoming version. As we
are focusing our testing at this phase on severe bugs, this bug was
closed without going through its verification step. If you think this
bug should be verified by QE, please set its severity to high and move
it back to ON_QA