roadrunner
roadrunner copied to clipboard
[💡 FEATURE REQUEST]: Redis powered lock's
I failed to find the lock plugin in the Plugin dropdown for this Feature Request so i wrote it manually :smiley:
Plugin
Lock
I have an idea!
It would be awesome if the Lock Plugin supported other drivers like the KV Plugin does.
The configuration could look something like this:
lock:
driver: redis
config: # The config would be up to the implementing plugin to parse
retry_interval: 100
client:
addrs:
- "${REDIS_HOST:-127.0.0.1}:${REDIS_PORT:-6379}"
username: "${REDIS_USERNAME}"
password: "${REDIS_PASSWORD}"
db: "${REDIS_DB:-0}"
That being said i already have a proof of concept redis locking plugin that could easily be plundered for any useful code for an implementation.
The configuration is like that because i fail to see a scenario where multiple lock drivers would be needed, but i could be wrong. Also supporting multiple lock drivers at a time would also require a change in the PHP interface and implementation.