GrabPERF: New Agent Code in Testing
July 21st, 2006 by smp | Comments | Filed in GrabPERF, Web PerformanceAfter a few month hiatus, I am starting to code for GrabPERF again. I need to exercise my brain; as I am a hobbyist code mangler, I have to take on a project every now and then to keep my not-so-l33t skillz honed.
The change to the agent is one of efficiency. The current production agent opens two database connections to run tests: one to retrieve the test configuration data; the other to insert the results of the tests. This means I loop through one set of database query results while doing inserts inside the loop on a second database connection.
This is stupid.
The new code opens a single connection to the database, retrieves the test configuration, dumps the results to an array of arrays, then inserts the data on the same connection. This is more efficient, as I use persistent connections and compression to MySQL to improve performance.
I have this running as TEST AGENT 1 from the Technorati #2 site.
Let me know if you see any madness…outside of Washington DC, and specifically with GrabPERF.
Technorati Tags: GrabPERF, PERL, MySQL
Tags: compress, compression, current, data, database, GrabPERF, GrabPERF.org, HTTP, IE, IM, it, mysql, Om, One, performance, Perl, persistent, persistent connections, pr, run, Technorati, testing, the other, Washington DC

