Row key sorting by partitioner

Certify and Increase Opportunity.
Be
Govt. Certified Apache Cassandra Professional

Row key sorting by partitioner

partitioner

Data partitioning determines how data is distributed across the nodes in the cluster. Three factors are involved with data distribution:

  • A partitioner that determines which node to store the data on.
  • The number of copies of data, which is determined by the replica placement strategy.
  • The topology of the cluster, which is the number of nodes, the distribution of the nodes on racks, and the number of data centers.

Column family data is partitioned across the nodes based on the row key. To determine the node where the first replica of a row will live, the ring is walked clockwise until it locates the node with a token value greater than that of the row key. Each node is responsible for the region of the ring between itself (inclusive) and its predecessor (exclusive). With the nodes sorted in token order, the last node is considered the predecessor of the first node; hence the ring representation.

The partitioner cannot be changed without reloading all of your data. Cassandra offers the following partitioners:

  • RandomPartitioner
  • ByteOrderedPartitioner
Share this post
[social_warfare]
Replica and their placement
Replication with Gossip protocol

Get industry recognized certification – Contact us

keyboard_arrow_up