-
Notifications
You must be signed in to change notification settings - Fork 710
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Cluster模式,在查询页面进行Scan时无法获取到数据。
List<RedisNode> redisMasterNodeList = getRedisMasterNodeList(cluster);
int masterSize = redisMasterNodeList.size();
int count = masterSize < 10 ? 100 / masterSize : 10;
autoCommandParam.setCount(count);
Set<String> result = new LinkedHashSet<>();
redisMasterNodeList.forEach(masterNode -> {
RedisClient redisClient = null;
try {
redisClient = RedisClientFactory.buildRedisClient(masterNode, cluster.getRedisPassword());
Set<String> scanResult = redisClient.scan(autoCommandParam);
result.addAll(scanResult);
} catch (Exception e) {
logger.error("Scan redis failed, node = " + masterNode.getHost() + ":" + masterNode.getPort(), e);
} finally {
close(redisClient);
}
});
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working