Skip to content
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

How masterSlaveUsage() works in BasicUsage example #6

Open
mkozioro opened this issue Mar 26, 2019 · 0 comments
Open

How masterSlaveUsage() works in BasicUsage example #6

mkozioro opened this issue Mar 26, 2019 · 0 comments

Comments

@mkozioro
Copy link

mkozioro commented Mar 26, 2019

Hi @warrenzhu25 .

I noticed Java/ClientSamples/src/main/java/lettuce/BasicUsage.java class contains masterSlaveUsage() method which could be used with Azure Redis Standard and Premium with cluster disabled.

In this method I see following code:

StatefulRedisMasterSlaveConnection<String, String> connection = MasterSlave.connect(client, new Utf8StringCodec(), redisUri);
connection.setReadFrom(ReadFrom.MASTER_PREFERRED);

How can this work? Running INFO Replication on Azure premium redis without cluster enabled returns only:

xxxxx.redis.cache.windows.net:6379> INFO REPLICATION
# Replication

How slaves can be discovered?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant