feat: add redis sentinel support
Flask-redis https://github.com/underyx/flask-redis doesnt support redis+sentinel://
, where redis-py
support it.
Flask-redis doesn't seems supported, or no recent activity, I'm not sure if this will be easily upstreamable.
Other redis protocol like the default, are still supported.
configuration.py
'REDIS_URL': 'redis://redis:6379/0',
This allows to use non-supported by redis lib scheme redis+sentinel
. Eg:
redis+sentinel://[:password@]host:port[,host2:port2,...][/service_name[/db]][?param1=value1[¶m2=value=2&...]]
rediss+sentinel://localhost:26379[,otherhost:26379,...]/mymaster/0
This prevents having several env vars but keep using just REDIS_URL
.
Resources:
Edited by cyrinux