#2561: memcached backend ignores default timeout?
----------------------------------------------+-----------------------------
Reporter: Christopher Lenz <[EMAIL PROTECTED]> | Owner: jacob
Type: defect | Status: new
Priority: normal | Milestone:
Component: Cache system | Version: SVN
Severity: major | Keywords:
----------------------------------------------+-----------------------------
Okay, I might be missing something obvious here⦠but does the memcached
backend even use the default timeout specified in the query string of the
`CACHE_BACKEND` setting? The code doesn't suggest so. Doesn't that mean
that cache entries only time out when the memory limit configured for
memcached is reached?
The following patch should remedy that AFAICT:
{{{
Index: django/core/cache/backends/memcached.py
===================================================================
--- django/core/cache/backends/memcached.py (revision 852)
+++ django/core/cache/backends/memcached.py (working copy)
@@ -20,7 +20,7 @@
return val
def set(self, key, value, timeout=0):
- self._cache.set(key, value, timeout)
+ self._cache.set(key, value, timeout or self.default_timeout)
def delete(self, key):
self._cache.delete(key)
}}}
BTW, there's no ''0.95'' version to select here.
--
Ticket URL: <http://code.djangoproject.com/ticket/2561>
Django <http://code.djangoproject.org/>
The web framework for perfectionists with deadlines.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" 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-updates
-~----------~----~----~----~------~----~------~--~---