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

Deadcode in AtomicSortedColumns

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Low
    • Resolution: Fixed
    • 2.0.5
    • None
    • None

    Description

      In AtomicSortedColumns we have this:

                        
      // for memtable updates we only care about oldcolumn, reconciledcolumn, but when compacting
      // we need to make sure we update indexes no matter the order we merge
      if (reconciledColumn == column)
          indexer.update(oldColumn, reconciledColumn);
      else
          indexer.update(column, reconciledColumn);
      

      This makes no sense anymore however since AtomicSortedColumns is not used anymore during compaction (and index removal is dealt with by the CompactedRow implementations).

      Attaching trivial patch against 2.0. This affects 1.2 too and maybe before (haven't check) but it's harmless anyway and we probably won't have much release of pre-2.0 versions anymore. Still, the code is a tad confusing so it's maybe worth cleaning it up in 2.0.

      Attachments

        1. 6580.txt
          2 kB
          Sylvain Lebresne

        Activity

          People

            slebresne Sylvain Lebresne
            slebresne Sylvain Lebresne
            Sylvain Lebresne
            Jonathan Ellis
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: