In the documentation, CACHE_MIDDLEWARE_ANONYMOUS_ONLY is promoted as "a simple and effective way of disabling caching for any user-specific pages." This may have been the case if user-specific requests didn't use to have the Vary: Cookie header added on automatically or the cache middleware didn't use to respect that header, but it's no longer true. The cache middleware will cache a separate copy for each cookie value in the requests it receives, so a viewer will never receive another user's responses. (If we want to allow developers to avoid wasting memory on caching pages that vary by cookie, I have a patch for that.)
If we want to keep that setting for some reason, the patch[1] that fixes bug #13283[2] needs to be applied. Turning on CACHE_MIDDLEWARE_ANONYMOUS_ONLY makes *every* page vary by cookie, so anyone with that setting enabled is getting a per-cookie cache instead of using the same cached page for everyone. (I serendipitously had that setting enabled for a news site on election night. Fun times.) - Niran [1] https://github.com/django/django/pull/4 [2] http://code.djangoproject.com/ticket/13283 -- You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/django-developers?hl=en.
