Wednesday 14 March 2007 6:02:19 pm
Hi Seth
There are a number of things to watch with the static cache:
+ If a static copy of a pages doesn't exist on the file system then eZ is used to serve the page.
+ You manually generate the initial static cache then pages are regenerated after publishing. Beware running this script on a running sight as it removes the static cache before regenerating it. This means that the site relies on eZ while the static cache is generated.
+ You have to make sure that the setup regenerates all the effected pages otherwise you can end up with old/dirty content on the site.
+ Only works for parts of the site that do not require login. If any part of the pagelayout is changed when the user logs in (basket, login form, personalisation etc) then you might need to reconsider the page design.
+ Of course will not work with things like search. (I'm pretty sure it is limited to the content module) + On heavily loaded sites it is good to use view cache pre-generation along with static caching as this minimises the time it takes to create the static version of the page. The static cache is great in that you can run a site with much lower speced hardware than if you use just eZ to serve the pages. If you remove the cache for any reason you might find yourself in trouble :) I've used the static caching on a site that is pretty quite for all but 4 days of the year. During those 4 days it goes off - lots of accesses and lots of updates. We used the static cache to help handle the load. We did find that the updates meant that pages like the home page were being generated quite often and the system was falling back to eZ to server the page. I ended up writing an extension that allowed for the content updates to be done in batches and for the static pages to be generated manually. I'll see about packaging it putting it up as a contribution. In some cases we've also used wget to generate static versions of eZ sites. This may be a simpler solution.
Heres a couple of links
http://ez.no/doc/ez_publish/technical_manual/3_6/reference/configuration_files/staticcache_ini
http://ez.no/community/articles/ez_publish_performance_optimization_part_3_of_3_practical_cache_and_template_solutions/static_cache http://ez.no/community/forum/developer/static_cache_some_user_report_tips
Cheers Bruce
My Blog: http://www.stuffandcontent.com/
Follow me on twitter: http://twitter.com/brucemorrison
Consolidated eZ Publish Feed : http://friendfeed.com/rooms/ez-publish
|