diff options
author | AbdealiJK <abdealikothari@gmail.com> | 2021-10-26 00:45:25 +0530 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-25 22:15:25 +0300 |
commit | 8924504f9875d3c80733504d6f6923f5611ebf17 (patch) | |
tree | 06f7ba7165cbbaff16525c2ddcebef82705391dd | |
parent | ddd1496782cc8eb15fca6c9059b2b08a03efe366 (diff) | |
download | redis-py-8924504f9875d3c80733504d6f6923f5611ebf17.tar.gz |
sentinel: Add SentinelManagedSSLConnection (#1419)
Create a simple class which takes in both:
- SentinelManaged
- SSLConnection
in cases where the sentinel is being used with a TLS enabled redis
setup.
-rw-r--r-- | redis/sentinel.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/redis/sentinel.py b/redis/sentinel.py index 6456b8e..740d92f 100644 --- a/redis/sentinel.py +++ b/redis/sentinel.py @@ -3,7 +3,7 @@ import weakref from redis.client import Redis from redis.commands import SentinelCommands -from redis.connection import ConnectionPool, Connection +from redis.connection import ConnectionPool, Connection, SSLConnection from redis.exceptions import (ConnectionError, ResponseError, ReadOnlyError, TimeoutError) from redis.utils import str_if_bytes @@ -66,6 +66,10 @@ class SentinelManagedConnection(Connection): raise +class SentinelManagedSSLConnection(SentinelManagedConnection, SSLConnection): + pass + + class SentinelConnectionPool(ConnectionPool): """ Sentinel backed connection pool. |