Examples of slaves()


Examples of org.springframework.data.redis.connection.RedisSentinelConnection.slaves()

    RedisSentinelConnection sentinelConnection = connectionFactory.getSentinelConnection();
   
    List<RedisServer> servers = (List<RedisServer>) sentinelConnection.masters();
    assertThat(servers.size(), is(1));
   
    Collection<RedisServer> slaves = sentinelConnection.slaves(servers.get(0));
    assertThat(slaves.size(), is(2));
    assertThat(slaves, hasItems(SLAVE_0, SLAVE_1));
  }

}
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.