Set<String> sentinels = new HashSet<String>();
sentinels.add("10.27.18.225:26379"); sentinels.add("10.27.18.227:26379");
sentinels.add("10.27.18.228:26379");
new JedisSentinelPool(master【主redis名称】, sentinels【哨兵】, poolConfig【配置】,timeout【读取超时】);
Jedis jedis = sentinel.getResource();
logger.info("start");
jedis.connect();
String key = "gy:hset";
hset(jedis, key, 10);
System.out.println(jedis.type(key));
logger.info("done");
jedis.ping();
jedis.quit();