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

Overwrites of rows in memtable produce incorrect deltas for indexing

    XMLWordPrintableJSON

    Details

      Description

      When a row in the memtable is updated, the delta is supplied to any registered indexer. This consists of two Row objects, representing the old and new data in the memtable. As per its javadoc, the contract of Index.Indexer::updateRow is that these old & new rows contain only the changed columns, so any column which was not affected by the update will appear in neither the new nor old row. The RowDiffListener::onCell method in SecondaryIndexManager.WriteTimeTransaction::onUpdated which produces these deltas uses a reference equality check, where it should be checking object equality. This results in unchanged, prexisting cells appearing in the toInsert row.

        Attachments

          Activity

            People

            • Assignee:
              samt Sam Tunnicliffe
              Reporter:
              samt Sam Tunnicliffe
              Authors:
              Sam Tunnicliffe
              Reviewers:
              Ariel Weisberg
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: