[Erp5-dev] programmable acquisition and performance

Pelletier Vincent vincent at nexedi.com
Thu Feb 7 09:05:23 CET 2008


Le Mercredi 6 Février 2008 17:12, bartek a écrit :
> Hello

Hi Bartek

> I noticed a considerable
> decrease in performance, but I'm not sure whether this is the reason -
> is programmable acquisition so heavy? And if so, then why, and can it be
> optimized somehow?

As noted in the [1] wiki page ("Is there any side effect by the patch?" 
section), _aq_dynamic is called every time __getattr__ returns None.
So every time a skin lookup is done (form, page template, script, etc) the 
custom acquisition method will be fired, for example.
I think the first optimisation to do is to have a quick check at _aq_dynamic 
begining to detect cases where it will return None, and do so immediately.

[1] http://www.erp5.org/WhyAqDynamicIsRequired

-- 
Vincent Pelletier



More information about the Erp5-dev mailing list