Skip to content

Commit 87ee7c4

Browse files
author
opapy
committed
add close method
1 parent 13a6125 commit 87ee7c4

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

django_elastipymemcache/memcached.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,11 @@ def _cache(self):
9191

9292
return self._client
9393

94+
def close(self, **kwargs):
95+
# libmemcached manages its own connections. Don't call disconnect_all()
96+
# as it resets the failover state and creates unnecessary reconnects.
97+
pass
98+
9499
@invalidate_cache_after_error
95100
def get(self, *args, **kwargs):
96101
return super(ElastiPyMemCache, self).get(*args, **kwargs)

0 commit comments

Comments
 (0)