tags:

views:

34

answers:

1

What is a simple way of configuring a cassandra cluster so that if I try to store a key in it, it will be stored in the local node to which I issue the set/write command?

I am looking at the IPartitioner which allows me to specify how the key will be hashed but it seems a bit heavy weight for something like above.

Thanks!

A: 

If you were able to arbitrarily write keys to arbitrary nodes, then on lookup the system would not know where the data for that key lived. The system would have to do a full cluster lookup which would be super slow.

By design, Cassandra spreads the data around in a known way so that lookups are quick.

Check out this post by Jonathan Ellis the primary maintainer of Cassandra.

Stephen Holiday