It seems that I was a bit to quick in posting here. I just came across
Matt Curry's LazyLoader plugin., whicht might very well be the thing
I'm looking for :)

- Nejra

On Jul 20, 5:13 pm, Nejra <mega...@gmail.com> wrote:
> Hi,
>
> I'm doing some profiling on a prototype that uses some extensive
> associations (the largest has 11 first level associations of different
> kinds, which could become more).
>
> When loading a model, Cake also loads all the associated models.
> Normally this doesn't take too much time, but now it's the slowest
> part of the process. The final result is intended for a heaviliy
> visited site, so all optimizations are welcome.
>
> Is there a way to stop Cake from loading all the associations until
> needed by, for example, Containable, without hacking the core library?
>
> If not, I've come up with three methods of avoiding the association
> loading process. Anyone know of a better way?
>
> 1. Cache resultsets and only load models (via loadModel()) when
> needed. But caching all user-specific, filtered or differently loaded
> resultsets could be even less ideal.
> 2. View caching where possible.
> 3. Making lite models with less associations for some pages. But that
> would lead to redundant code,.
>
> Thanks, any suggestion is appreciated.
>
> - Nejra
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to