I'm looking for an example of ConnectionUtils being used with sentinels, connecting to a password protected instance of redis. I have the code working fine with just the sentinels, but I cannot find a syntax for providing a password. Does anyone have an example they could share?
Asked
Active
Viewed 155 times
0
-
Ooh, that's fun. I'll be honest - it isn't a scenario I've looked at much - I'll need to set up some test servers to check how that is meant to work! – Marc Gravell Oct 30 '13 at 21:54
-
Marc, I think I may have a workaround for my case. I added code to ConnectionUtils to parse a password options (like serviceName, etc). And instead of connecting to the sentinels, I just passed in a comma separated list of redis instances. Now I can connect to the instances using the password and I still have failover. The sentinel instances handle failing over the master/slave setup and BookSleeve just connects to whichever instance gets promoted to master. My limited testing suggests this works for my case. – CuriousLayman Oct 30 '13 at 23:53