cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ard Schrijvers" <>
Subject RE: becomes very large
Date Thu, 13 Jul 2006 14:17:29 GMT

> > ...Can we configure a maximum cache file size?...
> I don't have a precise reply to your questions, but here's the config
> that I use to limit the number of cached entries, it might help.
> <!-- xconf patch file for cache settings -->
> <xconf
>   xpath="/cocoon/store"
>   remove="/cocoon/store/*">
>   <parameter name="maxobjects" value="100"/>
>   <parameter name="overflow-to-disk" value="false"/>
>   <parameter name="use-cache-directory" value="true"/>
> </xconf>

I think you are missing to much caching possibilities with the configuration above: a maximum
of 100 with overflow-to-disk set to false is to low. Try using overflow-to-disk=true and maxobjects
at least 1000 (unless you have extreme large cache responses) and timeToIdleSeconds to 1 day
or something.

One thing I just forgot to mention how your cache also can become extremely large (and your
cocoon app vulnerable, and sorry taht I keep repeating it on this list, but it is important
to realize)

configure your xslt transformer with 

by default!! Using <use-request-parameters>true</use-request-parameters> and using
cocoon cache implies to things when a crawler comes by:

1) Crawlers tend to crawl with arbitrary request-parameters: when use-request-parameters=true,
this implies crawlers never get a cache hit, making your cocoon cache useless. Crawlers can
bring your app down in this way

2) Since you cache your results, all crawlers leave your site cached in your ehcache under
unreacheable cachekeys (because of use-request-parameters=true, all parameters are stored
in the cachekey), simply adding infinitely many cachekeys+responses to your cache. 

Once more: never use <use-request-parameters>true</use-request-parameters>

Sry for repeating myself,

Regards Ard

> -Bertrand
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message