A.A
A.A

Reputation: 4111

tombstone limit reaches 100K cells

Accoding to this link,

Cassandra stores tombstones in the index until the tombstone limit reaches 100K cells. After exceeding the tombstone limit, the query that uses the indexed value will fail.

  1. Is this rule is same for updating a column that is cluster column for a materialized view?

  2. Is is bad idea to set a frequency updated column as cluster column for a materialized view? If yes, what is the alternative solution? If no, why?

Upvotes: 1

Views: 397

Answers (1)

Ashraful Islam
Ashraful Islam

Reputation: 12840

Yes, it is same for materialized view and It is a very bad idea to make a frequently updated column as clustering column of Materialized View.

You can treat a Materialized View as normal table. What will you do when your table's clustering column needs to update ?? You have to deleted and reinsert. So tombstone will generate.

Read the blog to learn more : Everything you need to know about Cassandra Materialized Views

You can try one of the below solution:

  • If you are using the column in clustering key to sort, make the column as regular column and sort from the client side.

  • Or Instead of using Materialized View, create a normal table, use the column as clustering column. When the column needs to updated, don't delete, only insert with new value. you can remove the duplicate from client side.

Upvotes: 1

Related Questions