Author: DrMeers
Date: 2011-09-20 18:37:17 -0700 (Tue, 20 Sep 2011)
New Revision: 16859

Modified:
   django/branches/releases/1.3.X/docs/topics/cache.txt
Log:
[1.3.X] Fixed #16886 -- Memcached socket file documentation. Thanks ddbeck for 
the report and patch.

Backport of [16858] from trunk.

Modified: django/branches/releases/1.3.X/docs/topics/cache.txt
===================================================================
--- django/branches/releases/1.3.X/docs/topics/cache.txt        2011-09-21 
01:33:14 UTC (rev 16858)
+++ django/branches/releases/1.3.X/docs/topics/cache.txt        2011-09-21 
01:37:17 UTC (rev 16859)
@@ -99,8 +99,9 @@
       on your chosen memcached binding)
 
     * Set :setting:`LOCATION <CACHES-LOCATION>` to ``ip:port`` values,
-      where ``ip`` is the IP address of the Memcached daemon and
-      ``port`` is the port on which Memcached is running.
+      where ``ip`` is the IP address of the Memcached daemon and ``port`` is 
the
+      port on which Memcached is running, or to a ``unix:path`` value, where
+      ``path`` is the path to a Memcached Unix socket file.
 
 In this example, Memcached is running on localhost (127.0.0.1) port 11211, 
using
 the ``python-memcached`` binding::
@@ -112,6 +113,16 @@
         }
     }
 
+In this example, Memcached is available through a local Unix socket file
+:file:`/tmp/memcached.sock` using the ``python-memcached`` binding::
+
+    CACHES = {
+        'default': {
+            'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
+            'LOCATION': 'unix:/tmp/memcached.sock',
+        }
+    }
+
 One excellent feature of Memcached is its ability to share cache over multiple
 servers. This means you can run Memcached daemons on multiple machines, and the
 program will treat the group of machines as a *single* cache, without the need

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-updates@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.

Reply via email to