shep

Multi-state key stores using bit masks for python3
git clone git://git.defalsify.org/shep.git
Log | Files | Refs | LICENSE

commit d133832e7370e144eeedcee7cff707dba13d1e99
parent 14f4cb23ae9e77b5de5743a0c787f4a378124d8b
Author: lash <dev@holbrook.no>
Date:   Wed, 20 Apr 2022 15:20:07 +0000

Add closers for persistent store backend

Diffstat:
Mshep/store/file.py | 4++++
Mshep/store/redis.py | 4++++
Mshep/store/rocksdb.py | 5+++++
3 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/shep/store/file.py b/shep/store/file.py @@ -154,3 +154,7 @@ class SimpleFileStoreFactory: if re.match(re_processedname, v): r.append(v) return r + + + def close(self): + pass diff --git a/shep/store/redis.py b/shep/store/redis.py @@ -96,3 +96,7 @@ class RedisStoreFactory: def add(self, k): k = str(k) return RedisStore(k, self.redis, binary=self.__binary) + + + def close(self): + self.redis.close() diff --git a/shep/store/rocksdb.py b/shep/store/rocksdb.py @@ -119,3 +119,8 @@ class RocksDbStoreFactory: def add(self, k): k = str(k) return RocksDbStore(k, self.db, binary=self.__binary) + + + def close(self): + self.db.close() +