How can I write a cql 3 delete
line specification ( WHERE
section) will only select those rows that are stored on a node? If this is not possible, then what is a SELECT
relationship ( WHERE
section) which will indicate which rows on a particular node Is stored?
I want to do this so that there is a homekeeping daemon (in Java) running on every data store node, which removes the old record from that node, so it can ensure that its node Do not get out of the disk space As I am writing a daemon instead of one stop cleaning, it is not appropriate to use the nodetool
program to query for stored token categories on the node.
This is a method that can work (but see below for a better idea). If you do not have vnodes enabled, you can identify the token range (since then, nodetool ring
command), then use them as a part of your deleted order, for example:
from MyTable where token (MyPK)> = Token 1 and Token (MyPK) & lt; Token 2 and (your deleted logic);
However, a very simple and secure way will be to find out where the data is, and just do it with any node:
Remove from MyTable where (delete your logic here);
Comments
Post a Comment