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

Avoid early opening of compaction results when doing anticompaction

    XMLWordPrintableJSON

    Details

    • Severity:
      Critical

      Description

      When doing anticompaction we have 2 sstable rewriters open and write the repaired range to one writer and the unrepaired to one. This can cause some keys to become unreadable during anticompaction, example:

      Say we are anticompacting one 150MB sstable into two new ones, 75MB each, first we start writing to the first one, after 50MB, we open the result early and move the start point up to the 50MB mark in the original file. Then, after 75MB written, we start writing to the next file and after writing 50MB to that file, we open that file early and move the start point up to 125MB in the original file. This makes 25MB unreadable that is only present in the first file written, but we have moved the start point beyond that part of the file in the original

      Simple solution is probably to avoid doing early opening during anticompaction, and since anticompaction is not as frequent as ordinary compactions, the performance implications would not be too big

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                marcuse Marcus Eriksson
                Reporter:
                marcuse Marcus Eriksson
                Authors:
                Marcus Eriksson
                Reviewers:
                Benedict Elliott Smith
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: