MCPcopy Create free account
hub / github.com/apache/cassandra-python-driver / replica_map_for_keyspace

Method replica_map_for_keyspace

cassandra/metadata.py:1757–1762  ·  view source on GitHub ↗
(self, ks_metadata)

Source from the content-addressed store, hash-verified

1755 log.exception("Failed creating a token map for keyspace '%s' with %s. PLEASE REPORT THIS: https://datastax-oss.atlassian.net/projects/PYTHON", keyspace, self.token_to_host_owner)
1756
1757 def replica_map_for_keyspace(self, ks_metadata):
1758 strategy = ks_metadata.replication_strategy
1759 if strategy:
1760 return strategy.make_token_replica_map(self.token_to_host_owner, self.ring)
1761 else:
1762 return None
1763
1764 def remove_keyspace(self, keyspace):
1765 self.tokens_to_hosts_by_ks.pop(keyspace, None)

Callers 1

rebuild_keyspaceMethod · 0.95

Calls 1

Tested by

no test coverage detected