Fixed #16358 - Made memcache backend delete old value on a failure to set.

Default Memcached configuration allows for a maximum object of 1MB and
will fail to set the key if it is too large. The key will be deleted from
memcached if it fails to be set. This is needed to avoid an issue with
cache_db session backend using the old value stored in memcached, instead
of the newer value stored in the database.
This commit is contained in:
Michael Manfre 2014-11-06 23:47:04 -05:00
parent bfb11b9562
commit bc8abe36ba
3 changed files with 25 additions and 1 deletions

View file

@ -729,6 +729,10 @@ Miscellaneous
.. _universal newlines: http://www.python.org/dev/peps/pep-0278
* The Memcached cache backends ``MemcachedCache`` and ``PyLibMCCache`` will
delete a key if ``set()`` fails. This is necessary to ensure the ``cache_db``
session store always fetches the most current session data.
.. _deprecated-features-1.8:
Features deprecated in 1.8