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 RedisURIs.connectTimeout - connect timeout.discovery - true to discover additional nodes.RedisURI and Partitions.public RedisURI getViewedBy(Map<RedisURI,Partitions> map, Partitions partitions)
RedisURI from a map of cluster views by Partitions as key.map - the map.partitions - the key.RedisURI or null.Copyright © 2020 lettuce.io. All rights reserved.