/// <summary> /// Get the replicas for a given partition key and keyspace /// </summary> public ICollection <Host> GetReplicas(string keyspaceName, byte[] partitionKey) { if (_tokenMap == null) { return(new Host[0]); } return(_tokenMap.GetReplicas(keyspaceName, _tokenMap.Factory.Hash(partitionKey))); }
public ICollection <IPAddress> GetReplicas(byte[] partitionKey) { if (_tokenMap == null) { return(new List <IPAddress>()); } return(_tokenMap.GetReplicas(_tokenMap.Factory.Hash(partitionKey))); }
/// <summary> /// Get the replicas for a given partition key and keyspace /// </summary> public ICollection <Host> GetReplicas(string keyspaceName, byte[] partitionKey) { if (_tokenMap == null) { Metadata.Logger.Warning("Metadata.GetReplicas was called but there was no token map."); return(new Host[0]); } return(_tokenMap.GetReplicas(keyspaceName, _tokenMap.Factory.Hash(partitionKey))); }