Thank you both very much for the comments. I just setup ngnix in front of apache yesterday and it really helped getting out of this mess. I didn't know about its advanced features you mentioned and I will experiment with them soon.
I am caching the context of a page, but when new content arrives, it changes context of around 10 pages. I want to have control of the cache and expire pages programmatically when new content arrives, not after a pre-defined time period. For this, I can use Etag, modified-since, etc. to set a relatively short time for crawlers, such as 1 hour, but cache the actual content for much longer, e.g. 1 month. Then, if something related to its context is submitted, I remove those pages from the cache. Maybe I am thinking this in a wrong way from the start. Thanks, omat On Dec 22, 3:50 pm, Javier Guerra <jav...@guerrag.com> wrote: > On Tue, Dec 22, 2009 at 8:44 AM, Michael <newmani...@gmail.com> wrote: > > Nginx can also create static files from dynamically served pages, so you > > could serve pages directly from disk. > > this is one of the best ways to do it. you could setup a > mostly-complete static copy of your site, and make nginx call the > dynamic one in it's 404 handler to 'fill the voids'. some benchmarks > show nginx static file handling roughly as fast as going to memcached. > > another point, maybe your current solution isn't helping with the > appropriate Etag, if-modified-since, and similar headers. these are > very important to let other machines in the way cache your content, > and the spiders _should_ use them to know when not to re-read and > re-index it. > > of course, if you set the static copy as a 'front layer', you should > get those for free. > > -- > Javier -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.