summaryrefslogtreecommitdiff
path: root/django/middleware/cache.py
Commit message (Collapse)AuthorAgeFilesLines
* Fixed #9221 -- Small optimisation to caching middleware handling.Malcolm Tredinnick2008-09-301-2/+3
| | | | | | | | In the slightly unusual case that CACHE_MIDDLEWARE_SECONDS is set to 0, don't bother storing a copy in the local cache. git-svn-id: http://code.djangoproject.com/svn/django/trunk@9098 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed a typo and added a bit more ReST markup to cache middleware docstring.Gary Wilson Jr2008-08-151-10/+10
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@8387 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Split CacheMiddleware up into two parts -- an update-cache and a ↵Jacob Kaplan-Moss2008-08-091-57/+115
| | | | | | | | | | | fetch-from-cache middleware. This lets you run each half of the cache middleware at the correct time to avoid bad interactions between the cache middleware and other middleware that must modify the cache key (like the locale middleware). CacheMiddleware itself is still around for backwards-compatibility and as a hook point for the cache decorator, but the documentation has been updated to point people towards the two-part caching middleware. Refs #730. git-svn-id: http://code.djangoproject.com/svn/django/trunk@8260 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #5813 -- Taught the CacheMiddleware to respect any max-age HTTP headerMalcolm Tredinnick2007-11-291-5/+18
| | | | | | | when setting the expiry time. Thanks, SmileyChris. git-svn-id: http://code.djangoproject.com/svn/django/trunk@6736 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #3808 -- Fixed some typos in comments. Thanks, Collin GradyAdrian Holovaty2007-03-251-1/+1
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@4816 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #2541 -- Added helpful error message for CacheMiddleware in the case ↵Adrian Holovaty2006-08-181-0/+3
| | | | | | of CACHE_ANONYMOUS_ONLY=True and uninstalled/unordered AuthenticationMiddleware. Thanks, dummy@habmalnefrage.de git-svn-id: http://code.djangoproject.com/svn/django/trunk@3603 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Second half of little cleanup tweaks suggested by pyflakes.Jacob Kaplan-Moss2006-07-211-1/+0
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@3414 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #2392 -- Fixed CACHE_MIDDLEWARE_ANONYMOUS_ONLY to use attribute access ↵Adrian Holovaty2006-07-211-1/+1
| | | | | | to django.conf.settings git-svn-id: http://code.djangoproject.com/svn/django/trunk@3406 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Small style fixes to docs from [3395]Adrian Holovaty2006-07-201-1/+1
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@3397 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Oops, fixed small typo in [3395]Jacob Kaplan-Moss2006-07-201-1/+1
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@3396 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Added a CACHE_MIDDLEWARE_ANONYMOUS_ONLY setting which makes the cache ignore ↵Jacob Kaplan-Moss2006-07-201-1/+14
| | | | | | | | | pages served to authenticated users. Fixes #1509 (thanks, Matt). Also added a FAQ entry about using this setting to avoid caching of the admin interface. git-svn-id: http://code.djangoproject.com/svn/django/trunk@3395 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Converted request.META['REQUEST_METHOD'] calls to request.method, throughout ↵Adrian Holovaty2006-06-201-2/+2
| | | | | | the Django codebase git-svn-id: http://code.djangoproject.com/svn/django/trunk@3171 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #2109 -- Convert old-style classes to new-style classes throughout ↵Adrian Holovaty2006-06-081-1/+1
| | | | | | Django. Thanks, Nicola Larosa git-svn-id: http://code.djangoproject.com/svn/django/trunk@3113 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* MERGED MAGIC-REMOVAL BRANCH TO TRUNK. This change is highly ↵Adrian Holovaty2006-05-021-1/+1
| | | | | | backwards-incompatible. Please read http://code.djangoproject.com/wiki/RemovingTheMagic for upgrade instructions. git-svn-id: http://code.djangoproject.com/svn/django/trunk@2809 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #647 -- Fixed cache middleware not to expect _cache_update_cache, in ↵Adrian Holovaty2005-10-191-1/+1
| | | | | | case of 404s and 500s. Thanks, Eugene git-svn-id: http://code.djangoproject.com/svn/django/trunk@954 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #599 -- locmem cache now uses deepcopy() to prevent aliasing. Thanks, HugoAdrian Holovaty2005-10-101-2/+1
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@821 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #580 -- Added mega support for generating Vary headers, including some ↵Adrian Holovaty2005-10-091-67/+49
| | | | | | view decorators, and changed the CacheMiddleware to account for the Vary header. Also added GZipMiddleware and ConditionalGetMiddleware, which are no longer handled by CacheMiddleware itself. Also updated the cache.txt and middleware.txt docs. Thanks to Hugo and Sune for the excellent patches git-svn-id: http://code.djangoproject.com/svn/django/trunk@810 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #333 and #440 -- Split DEFAULT_MIME_TYPE setting into ↵Adrian Holovaty2005-10-061-1/+1
| | | | | | DEFAULT_CONTENT_TYPE and DEFAULT_CHARSET. Thanks, Maniac. git-svn-id: http://code.djangoproject.com/svn/django/trunk@786 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Added django.middleware.cache, which lets you cache an entire Django-powered ↵Adrian Holovaty2005-07-181-0/+88
site by adding a line to your settings git-svn-id: http://code.djangoproject.com/svn/django/trunk@178 bcc190cf-cafb-0310-a4f2-bffc1f526a37