On 12/7/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> Good luck, here's one page's set:

IIRC, you're doing -lots- of hits on these pages.  Assuming you're
already caching results where you can (in memcache or http
downstream), you probably need to look at caching loaded templates.
I'm suggesting this because there are two phases to template usage:
loading and rendering.  Loading is pretty fast, but if you don't
change templates much, and you render lots, it may make sense to cache
the loaded node tree.

Something like this might help:

template_name = "detail.html"
t = cache.get(template_name)
if not t:
  t = loader.get_template(template_name)
  cache.set(template_name, t, 60*60)#1 hour
...

t.render(c)

--~--~---------~--~----~------------~-------~--~----~
 You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to