I'm using Redisson with below configuration to connect to Sentinel servers:
Config config = new Config();
config.useSentinelServers().setMasterName("local")
.addSentinelAddress("redis://localhost:26379", "redis://localhost:26380", "redis://localhost:26381");
RedissonClient client = Redisson.create(config);
How ever when I run this code I get the below error creating the client:
Caused by: java.lang.IllegalArgumentException: port out of range:-1
at java.net.InetSocketAddress.checkPort(InetSocketAddress.java:143)
at java.net.InetSocketAddress.<init>(InetSocketAddress.java:224)
at org.redisson.client.RedisClient.<init>(RedisClient.java:105)
at org.redisson.connection.MasterSlaveConnectionManager.createClient(MasterSlaveConnectionManager.java:354)
at org.redisson.connection.SentinelConnectionManager.<init>(SentinelConnectionManager.java:74)
at org.redisson.config.ConfigSupport.createConnectionManager(ConfigSupport.java:258)
at org.redisson.Redisson.<init>(Redisson.java:115)
at org.redisson.Redisson.create(Redisson.java:154)
I wanted to know if I'm missing any thing in the redisson config or my sentinel servers are not configured well.