Database Reference
In-Depth Information
is optimized for running in different data centers, however, and taking advantage of its high avail-
ability may be an important consideration for you. If your Cassandra cluster does span multiple
data centers, consider using this strategy.
Figure6-2.The Old Network Topology Strategy places the second replica in a different data center
and others on different racks in the same data center
If you use the Rack-Aware Strategy, you must also use the Rack-Aware Snitch. Snitches are de-
scribed in Snitches .
Network Topology Strategy
This strategy, included with the 0.7 release of Cassandra, allows you to specify more evenly
than the RackAwareStrategy how replicas should be placed across data centers. To use it,
you supply parameters in which you indicate the desired replication strategy for each data
center. This file is read and executed by the org.apache.cassandra.locat-
or.DataCenterShardStrategy class, so the implementation is somewhat flexible. The data
center shard strategy is depicted in Figure 6-3 .
This strategy used to employ a file called datacenter.properties. But as of 0.7, this metadata is
attached directly to the keyspace and strategy as a map of configuration options.
Search WWH ::




Custom Search