PHP, Zend Framework and Other Crazy Stuff
ADOdb-Lite PerfMon: Basics Completed
Back on the quest to add the ADOdb Performance Management features to ADOdb-Lite…
Spent some more time on the job this evening. I added a few adjustments and the Log fetching now works for both MySQL4 and MySQL5. I also removed a few optional (IMO) methods from the methods in tohtml.inc.php – namely some date-time functions which were of limited use in any case. The impact to the usual stats is negligible.
The features now work as in ADOdb for MySQL4, MySQL5 and PostgreSQL. However I still have a bit of tidying up to do. Primarily I need to vut all the duplicate code from the individual driver modules and push them up into a common parent. I’ve started on this and it looks workable – if with a little acrobatics. I have also pushed the perfmon specific $_logsql property and LogSQL() method into the common module parent – and out of adodb.inc.php. Finally the NewPerfMonitor() function in adodb.inc.php is now a simple three liner to return a reference to the connection object it is passed – this is purely for backwards compatibility. The function is not required to use perfmon anymore but ADOdb users will still have it in their code.
Its coming together quite nicely at this point. There is still a lot of non-standard HTML hanging around, including naughty font tag usage. Not sure whether to just update to some XHTML 1.0 standard and leave it, or set up a small collection of template files (in native PHP) to allow those template be editable in the future. It just makes things look messy within the module classes. I have also excised all the gymnastics surrounding $_logsql and LogSQL() calls (they are used basically as alternatives and are just plain confusing) and made LogSQL() the standard method of switching sql logging on and off to avoid logging queries sourced in the perfmon modules.
Once I get this all sorted out I’ll add further driver modules for those DBMS’s supported at present in ADOdb-Lite already available in ADOdb. It’s a small extra that I may as well do rather than take half measures. In all there’s maybe another few hours work tops. Hopefully I can make a release at the weekend for anyone interested in testing and offering some feedback for improvements.
My two current tasks:
- Moving everything to using a common module parent
- Doing something about the messy page creation via tohtml.inc.php and the PHP/HTML mixing
Related posts:
| Print article | This entry was posted by Pádraic Brady on March 23, 2006 at 4:03 am, and is filed under PHP General. Follow any responses to this post through RSS 2.0. You can leave a response or trackback from your own site. |
-
http://www.visionsofdarkness.net Moocat
-
http://blog.quantum-star.com Maugrim
-
http://www.visionsofdarkness.net Moocat
-
http://blog.quantum-star.com Maugrim
-
http://www.aatraders.com Panama Jack
-
http://blog.quantum-star.com Maugrim
