Cassandra ttl on a row -


i know there ttls on columns in cassandra. possible set ttl on row? setting ttl on each column doesn't solve problem can seen in following usecase:

at point process wants delete complete row ttl (let's row "a" ttl 1 week). replacing existing columns same content ttl of 1 week.

but there may process running concurrently on row "a" inserts new columns or replaces existing ones without ttl because process can't know row deleted (it runs concurrently!). after 1 week columns of row "a" deleted because of ttl except these newly inserted ones. , want them deleted.

so there or there cassandra support use case or have implement on own?

kind regards
stefan

there no way of setting ttl on row in cassandra currently. ttls designed deleting individual columns when lifetime known when written.

you achieve want delaying process - instead of wanting insert ttl of 1 week, run week later , delete row. row deletes have following semantics: column inserted before deleted columns inserted after won't be.

if columns inserted in future still need deleted insert row delete timestamp in future ensure careful: if later wanted insert row couldn't, columns disappear when written row (until tombstone garbage collected).


Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -