I am experimenting with various caching approaches of Django 1.3 for use on our landing page. This page contains the results of several database queries, as well as user authentication. To date, the most effective solution has been to use @cache_page decorator to cache the entire response of a function function. The problem is that custom auth is also cached.
I can create a cache key for each user, but that seems wasteful; caching the same landing page again and again, with the only difference being that it is user authentication. I also used template fragment caching and low-level caching for everything except authentication, but performance was nowhere better than the @cache_page decoder approach.
Is there a way to get @cache_page performance without a lot of redundant user caching?
source share