Partitioning is only done for row keys, the part
in your message about keys and partitioning is correct.
There is no partitioning for columns, all columns for a
particular key are stored on the same node (plus
replicas, of course, which are stored on different
nodes). The CompareWith option for column families
only affects the ordering of columns/supercolumns, not
I am trying to make my
ideas clear about how the partioning works in
Here is what I
understood, pease correct me if I am wrong.
- Row key are
partitionned based on the partitionning strategy you choose (randon, order
preserving, custom if you implemented the IPartioner interface). One
partionning strategy is defined per cluster (in fact for each node of the
cluster but the confifguration should be the sames so...)
Partionning is better for range queries because the key are stored in a
sequential way so when selecting a range of keys, you hit less nodes than with
- Once this first partitioning is done, a second
one is done based on the Column (or SuperColumn) name and the CompareWith you
defined for the ColumnFamily.
wrong if I say that potentially the different columns of the same ColumnFamily
are stored on different nodes? So if I wanna read a complete row, I hit
a way of controlling the way Column are stored?
for your help.