Skip to content

Commit 4fed455

Browse files
committed
Expose redis client for sharq-server
Signed-off-by: Prashanth Pai <prashanth.pai@plivo.com>
1 parent 2333b84 commit 4fed455

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
argparse==1.2.1
22
msgpack==0.5.6
33
wsgiref==0.1.2
4-
redis-py-cluster==2.0.0
4+
redis-py-cluster==2.1.0

sharq/queue.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,9 @@ def _load_config(self):
7575
self._config = configparser.SafeConfigParser()
7676
self._config.read(self.config_path)
7777

78+
def redis_client(self):
79+
return self._r
80+
7881
def reload_config(self, config_path=None):
7982
"""Reload the configuration from the new config file if provided
8083
else reload the current config file.

0 commit comments

Comments
 (0)