Question 17: You are designing Cassandra cluster, and you have been asked to span cluster in Geneva, Nevada and Hyderabad. Which of the following replication strategies you will use for this.

  1. SimpleStrategy
  2. NetworkTopologyStrategy
  3. Murmur3Strategy
  4. RandomStrategy

Correct Answer : 2

Exp : SimpleStrategy : Use only for a single data center and one rack. SimpleStrategy places the first replica on a node determined by the partitioner.

Additional replicas are placed on the next nodes clockwise in the ring without considering topology (rack or data center location).

Use NetworkTopologyStrategy when you have (or plan to have) your cluster deployed across multiple data centers. This strategy specify how many replicas you want in each data center.

NetworkTopologyStrategy places replicas in the same data center by walking the ring clockwise until reaching the first node in another rack.

NetworkTopologyStrategy attempts to place replicas on distinct racks because nodes in the same rack (or similar physical grouping) often fail at the same time due to power, cooling, or network issues.