public class ClusterTopologyRefresh extends Object
Partitions.| Constructor and Description |
|---|
ClusterTopologyRefresh(NodeConnectionFactory nodeConnectionFactory,
ClientResources clientResources) |
| Modifier and Type | Method and Description |
|---|---|
RedisURI |
getViewedBy(Map<RedisURI,Partitions> map,
Partitions partitions)
Resolve a
RedisURI from a map of cluster views by Partitions as key |
Map<RedisURI,Partitions> |
loadViews(Iterable<RedisURI> seed,
Duration connectTimeout,
boolean discovery)
|
public ClusterTopologyRefresh(NodeConnectionFactory nodeConnectionFactory, ClientResources clientResources)
public Map<RedisURI,Partitions> loadViews(Iterable<RedisURI> seed, Duration connectTimeout, boolean discovery)
RedisURIs and return the view per RedisURI. Partitions contain
an ordered list of RedisClusterNodes. The sort key is latency. Nodes with lower latency come first.seed - collection of RedisURIsconnectTimeout - connect timeoutdiscovery - true to discover additional nodesRedisURI and Partitionspublic RedisURI getViewedBy(Map<RedisURI,Partitions> map, Partitions partitions)
RedisURI from a map of cluster views by Partitions as keymap - the mappartitions - the keyRedisURI or nullCopyright © 2019 lettuce.io. All rights reserved.