More about 2.0 development and plans.

@euromark
Only view (and elements) cache are deleted (form disk) by cake:
- After Model::save() and Model::delete(), all view cache files
containing plural model name (articles, products, users) are deleted.
- For all existing model's associations (hasMany, belongsTo...) cache
files containing plural names of associated models are deleted too.

You can avoid this behavior by using Configure::write('Cache.check',
false) in core.php,
and clear cache in Model::afterSave() callback by yourself, or leave
them until expired.

How cake clear view cache may not be optimal in some cases,
eg.:
- if Model::save() is called to increase some "hits" or "number of
views" counter on every request,
- if custom cache keys is used (like "featured_on_frontpage") nothing
is cleared after save




On Apr 8, 3:22 am, euromark <[email protected]> wrote:
> +1 for caching - especially the "permanent cache" where the cache is
> valid indefinitely and gets automatically updated by the models - and
> only if needed. i think someone talked about "that it works" but not
> "how". Probably quite difficult regarding model relations and related
> data.
>
> On 8 Apr., 07:01, keymaster <[email protected]> wrote:
>
>
>
>
>
>
>
> > plans regarding evolution of cake's model and ORM, in light of all the new
> > stuff now available in open source (eg. Propel, Doctrine...).

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


To unsubscribe from this group, send email to
[email protected] For more options, visit this group at 
http://groups.google.com/group/cake-php

Reply via email to