[
https://issues.apache.org/jira/browse/CASSANDRA-2621?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13030614#comment-13030614
]
Aaron Morton commented on CASSANDRA-2621:
-----------------------------------------
Worked on some tests that used mutations and made queries through
ColumnFamilyStore and found it's a bit more complicated...
CFS.getColumnFamily() calls removeDeleted() (as do a lot of functions) which
filters out sub columns using the column families markedForDeletionAt and the
current gcBefore.
The confusing part is QueryFilter.collectCollatedColumns() is doing things to
remove sub columns that are no longer relevant and calls
IFilter.filterSuperColumns(). NamesQueryFilter and SliceQueryFilter both filter
sub columns if QF has changed the markedForDeletionAt value on the super
column. IdentityQueryFilter does not.
Looks like the extra code in CFS has to do with filtering after a cache lookup.
Happy to close, or add some comments to collectCollatedColumns() to say the
retured CF may have deleted columns, or make a change so the result from
QF.collectCollatedColumns always contains only relevant columns.
I'll try using CFS.removeDeleted() in the RowResolver in CASSANDRA-2590 after
filtering the results with QF and IdentityQueryFilter.
> sub columns under deleted CF returned
> --------------------------------------
>
> Key: CASSANDRA-2621
> URL: https://issues.apache.org/jira/browse/CASSANDRA-2621
> Project: Cassandra
> Issue Type: Bug
> Components: Core
> Affects Versions: 0.7.5, 0.8.0 beta 2
> Reporter: Aaron Morton
> Assignee: Aaron Morton
> Priority: Minor
>
> found when working on CASSANDRA-2590
> In some cases sub columns are not filtered to check if they have a higher
> timestamp than and container super column or CF. For example a super col with
> two two columns, one with timestamp 0 and the other 5, will be returned with
> all columns even if there is a row delete at timestamp 2.
> If the QueryFilter is created with a null superColumnName in the QueryPath it
> will not filter the sub columns.
> IdentityQueryFilter.filterSuperColumn() lets all sub columns through.
> NamesQueryFilter.filterSubColumn() and SliceQueryFilter() check that each sub
> column is relavent.
> I have a fix and am working on some test cases.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira