Improving MySQL Performance
I've been poking around in the (admittedly outdated) 1.74 and the time to generate pages was very slow. A profile revealed that almost all the time was being spent in MySQL so I homed in on that.
I further discovered that the most easily optimized part of the MySQL equation was the connection, which has enormous overhead. By using DB::connect($dsn, array('persistent'=>true)) in all instances, I was able to reduce page generation times from 3.5 seconds to about .88 seconds.
Tests on other systems with ADODB reveal that caching the database object in a session variable (not DB-stored) can make single-server response increase another order of magnitude. That implies propagating the class definitions across all source files, so it might not be worth all the code you have to touch.
Can anyone comment on whether either of these approaches has yet been attempted and if so, with what results?
Thanks