mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-24 11:21:25 -07:00
Better fix for serializing/deserializing cache plugins (v2)
This commit is contained in:
parent
cd6d1f9221
commit
0f1eb3cfc2
4 changed files with 17 additions and 9 deletions
7
lib/ansible/plugins/cache/redis.py
vendored
7
lib/ansible/plugins/cache/redis.py
vendored
|
@ -51,8 +51,6 @@ class CacheModule(BaseCacheModule):
|
|||
self._cache = StrictRedis(*connection)
|
||||
self._keys_set = 'ansible_cache_keys'
|
||||
|
||||
super(CacheModule, self).__init__()
|
||||
|
||||
def _make_key(self, key):
|
||||
return self._prefix + key
|
||||
|
||||
|
@ -103,3 +101,8 @@ class CacheModule(BaseCacheModule):
|
|||
ret[key] = self.get(key)
|
||||
return ret
|
||||
|
||||
def __getstate__(self):
|
||||
return dict()
|
||||
|
||||
def __setstate__(self, data):
|
||||
self.__init__()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue