如果我在一个集群中有一个包含 100'000 个已删除行的单个分区,然后在同一分区中有一个没有删除行的第二个集群,那么执行操作的性能SELECT * FROM example_table WHERE partition=that_partition AND cluster=the_second_cluster
会受到 the_first_cluster 中存在的墓碑的影响吗?
我期望如果使用 where 子句检索行集是恒定的,那么 Cassandra 将跳过所有墓碑到第二个集群,但我不明白 where 子句如何找到正确的行,所以我不'不知道是否是这种情况,我没有设法在网上找到任何可以启发我的东西。
// Example table
CREATE TABLE example_table (
partition TEXT,
cluster TEXT,
value BLOB,
PRIMARY KEY (partition, cluster);
// Example layout of rows in a table
partition |cluster |value
that_partition |the_first_cluster |some_value1 // Deleted, a tombstone
that_partition |the_first_cluster |some_value2 // Deleted, a tombstone
... 99'997 more similar tombstone rows
that_partition |the_first_cluster |some_value // Deleted, a tombstone
that_partition |the_second_cluster |some_valueA // Not a tombstone
that_partition |the_second_cluster |some_valueB // Not a tombstone
... no tombstones in the_second_cluster