cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alex Petrov (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CASSANDRA-13075) Indexer is not correctly invoked when building indexes over sstables
Date Tue, 17 Jan 2017 09:29:26 GMT

    [ https://issues.apache.org/jira/browse/CASSANDRA-13075?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15825704#comment-15825704
] 

Alex Petrov commented on CASSANDRA-13075:
-----------------------------------------

I've prepared a patch which would address both issues you have described: 

  * we use unfiltered pager now in order to allow seeing partition deletions and therefore
notifying the client about the fact that partition was deleted
  * problem with empty extra page is addressed. It was surfacing itself only when the page
size was exactly size of partition. In this case, it tried to fetch another page, was receiving
an empty partition in return. We skip this corner case here. In other places it's used it
doesn't seem to be a problem

Also, it will help to handle range tombstones correctly for indexes as well.

|[3.X|https://github.com/ifesdjeen/cassandra/tree/13075-3.X]|[utest|https://cassci.datastax.com/view/Dev/view/ifesdjeen/job/ifesdjeen-13075-3.X-testall/]|[dtest|https://cassci.datastax.com/view/Dev/view/ifesdjeen/job/ifesdjeen-13075-3.X-dtest/]|
|[3.0|https://github.com/ifesdjeen/cassandra/tree/13075-3.0]|[utest|https://cassci.datastax.com/view/Dev/view/ifesdjeen/job/ifesdjeen-13075-3.0-testall/]|[dtest|https://cassci.datastax.com/view/Dev/view/ifesdjeen/job/ifesdjeen-13075-3.0-dtest/]|
|[trunk|https://github.com/ifesdjeen/cassandra/tree/13075-trunk]|[utest|https://cassci.datastax.com/view/Dev/view/ifesdjeen/job/ifesdjeen-13075-trunk-testall/]|[dtest|https://cassci.datastax.com/view/Dev/view/ifesdjeen/job/ifesdjeen-13075-trunk-dtest/]|


> Indexer is not correctly invoked when building indexes over sstables
> --------------------------------------------------------------------
>
>                 Key: CASSANDRA-13075
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-13075
>             Project: Cassandra
>          Issue Type: Bug
>            Reporter: Sergio Bossa
>            Assignee: Alex Petrov
>            Priority: Critical
>         Attachments: CustomIndexTest.java
>
>
> Following CASSANDRA-12796, {{SecondaryIndexManager#indexPartition()}} calls each {{Indexer}}
{{begin}} and {{finish}} methods multiple times per partition (depending on the page size),
as {{PartitionIterators#getOnlyElement()}} returns an empty partition even when the iterator
is exhausted.
> This leads to bugs for {{Indexer}} implementations doing actual work in those  methods,
but even worse, it provides the {{Indexer}} the same input of an empty partition containing
only a non-live partition deletion, as the {{Indexer#partitionDelete()}} method is *not* actually
called.
> My proposed solution:
> 1) Stop the iteration before the empty partition is returned and ingested into the {{Indexer}}.
> 2) Actually call the {{Indexer#partitionDelete()}} method inside {{SecondaryIndexManager#indexPartition()}}
(which requires to use a filtered iterator so it actually contains the deletion info).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message