You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Alex Petrov (Jira)" <ji...@apache.org> on 2020/09/22 14:53:00 UTC

[jira] [Assigned] (CASSANDRA-14944) Tombstones are not removed if bloom filter is turned off

     [ https://issues.apache.org/jira/browse/CASSANDRA-14944?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alex Petrov reassigned CASSANDRA-14944:
---------------------------------------

    Assignee:     (was: Alex Petrov)

> Tombstones are not removed if bloom filter is turned off
> --------------------------------------------------------
>
>                 Key: CASSANDRA-14944
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-14944
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Local/Compaction
>            Reporter: Vitalii Ishchenko
>            Priority: Normal
>
> Well actually they are deleted, but not always even though they should, because check is done using Index of overlapped tables
> When purge evaluator is constructed we are checking overlapping tables using bloom filter, but when it is disabled we are checking against index, but if condition is not properly constructed and we still check bloom filter which is AlwaysPresentFilter and every overlapping sstable is used to get minTimestamp and tombstones, that have their timestamp >= minTimestamp won't be deleted
> {code:java}
> if (sstable.getBloomFilter() instanceof AlwaysPresentFilter && sstable.getPosition(key, SSTableReader.Operator.EQ, false) != null
>     || sstable.getBloomFilter().isPresent(key))
> {
> {code}
> Should be something like this
> {code:java}
> boolean mightBePresentInTable = sstable.getBloomFilter() instanceof AlwaysPresentFilter ? sstable.getPosition(key, SSTableReader.Operator.EQ, false) != null : sstable.getBloomFilter().isPresent(key)
> {code}
> Code pointers in 3.11 [https://github.com/apache/cassandra/blob/08363afa5354c00a7ecd62fe273c392a678db28a/src/java/org/apache/cassandra/db/compaction/CompactionController.java#L274] and 4.0 [https://github.com/apache/cassandra/blob/11384c3279a66e6c0fb7861e2b188b25e963580f/src/java/org/apache/cassandra/db/compaction/CompactionController.java#L281]



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org
For additional commands, e-mail: commits-help@cassandra.apache.org