Uploaded image for project: 'Cassandra'
  1. Cassandra
  2. CASSANDRA-13075

Indexer is not correctly invoked when building indexes over sstables

Agile BoardAttach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskConvert to sub-taskMoveLinkCloneLabelsUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Urgent
    • Resolution: Fixed
    • Fix Version/s: 3.0.11, 3.10, 4.0, 4.0-alpha1
    • Component/s: None
    • Labels:
      None
    • Severity:
      Critical

      Description

      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).

        Attachments

          Activity

            People

            • Assignee:
              ifesdjeen Alex Petrov Assign to me
              Reporter:
              sbtourist Sergio Bossa
              Authors:
              Alex Petrov
              Reviewers:
              Sergio Bossa

              Dates

              • Created:
                Updated:
                Resolved:

                Issue deployment