Doesnt seem to like being refreshed and some event items arent in the time dict, I noticed these were items that I had got in a ram cache. So i just stuck an if at line 496. Other than that its a great product. Most important tool since refresh if you ask me... ----- Original Message ----- From: "Richard Jones" <rjones@ekit-inc.com> To: "zope-dev" <zope-dev@zope.org> Sent: Thursday, January 31, 2002 5:13 PM Subject: [Zope-dev] Call Profiler
I've just announced our Call Profiler product on zope.org and the zope announce list (waiting for people in different timezones to authorise them :) ( http://www.zope.org/Members/richard/CallProfiler/ for the impatient)
In a nutshell, it patches the rendering guts of DTMLMethod, ZSQL, etc. and the ZPublisher so that we can get timing marks for requests as the calls are made. The patching is quite simple (once I got the hang of it ;) and reversible, and means that there's no changes required to the Zope core to enable the testing (which our initial versions did).
It does pose a question though: would it be better to have support for this stuff in the core, or is it OK for a product like this to dynamically patch the call methods when it needs to?
On one hand, the performance hit when dynamically patching the methods is zero when the product is not "active", but it does mean diddling with methods that really probably should be left alone. On the other hand, having changes to the core code to test for profiling being enabled introduces a small performance hit even when profiling is not activated.
Any comments?
Richard
_______________________________________________ Zope-Dev maillist - Zope-Dev@zope.org http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )