On Tue, Jun 12, 2007 at 06:39:57PM +0200, Thierry Florac wrote: > I'm looking for a simple solution to profile a Zope3 application, some > kind of 'ZopeProfiler' product which was available for Zope2.
That would be a nice thing to have. > Any link or advise would be welcome... So far the easiest way I've found is to use my @profile adapter on the view's __call__: from profilehooks import profile class MyViewClass(BrowserView): template = ViewPageTemplateFile('templates/mytemplate.pt') @profile(immediate=True) # if you specify immediate, each request will print the profile to stdout # if you don't, you'll get an aggregate profile when you stop the server def __call__(self): return self.template() You can find profilehooks.py (MIT licence) with some usage examples at http://mg.pov.lt/blog/profiling.html You might also be interested in http://mg.pov.lt/blog/benchmarking-zope3-apps.html Marius Gedminas -- Beware of bugs in the above code; I have only proved it correct, not tried it. -- Donald Knuth
Description: Digital signature
_______________________________________________ Zope3-users mailing list Zope3email@example.com http://mail.zope.org/mailman/listinfo/zope3-users