Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

cannot delete row key

I'm having an issue while deleting row key in Cassandra. Whenever I delete Row Key all the columns contained by that RowKey are deleted but RowKey itself is not deleted. Can anybody tell me how to remove a rowkey, once it is inserted in columnfamily.

I'm looking forward to do that via thrift client.

like image 585
dinesh028 Avatar asked Sep 12 '26 19:09

dinesh028


1 Answers

This is a side effect of how distributed deletes work in Cassandra. From the Cassandra wiki page on distributed deletes:

[A] delete operation can't just wipe out all traces of the data being removed immediately: if we did, and a replica did not receive the delete operation, when it becomes available again it will treat the replicas that did receive the delete as having missed a write update, and repair them! So, instead of wiping out data on delete, Cassandra replaces it with a special value called a tombstone. The tombstone can then be propagated to replicas that missed the initial remove request.

Also take a look at this question on the FAQ: Why do deleted keys show up during range scans?

like image 51
psanford Avatar answered Sep 16 '26 18:09

psanford



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!