-
-
Notifications
You must be signed in to change notification settings - Fork 71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sentinel.get_master method #27
Comments
the same issue, I dont know how to use that method. @AlexProfi have you get the solution? |
You're generally better off using the If you do want to use them directly the first argument is an instance of local sentinel = require("resty.redis").new()
sentinel:connect("my_sentinel.host", 6380)
local master = require("resty.redis.sentinel").get_master(sentinel, "my_master_name") |
@AlexProfi can I use the method in stream that load balance the redis, when the redis master down and pick a new one immediately. |
I don't really understand. If you use the sentinel syntax (https://github.com/ledgetech/lua-resty-redis-connector#connections-via-redis-sentinel) then it will always ask sentinel for the current master and then make a connection to that host. |
Please describe how to use method sentinel.get_master method
after I get connected redis after connect_via_sentinel
The text was updated successfully, but these errors were encountered: