cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sam Tunnicliffe (JIRA)" <>
Subject [jira] [Commented] (CASSANDRA-5397) Updates to PerRowSecondaryIndex don't use most current values
Date Thu, 04 Apr 2013 17:05:15 GMT


Sam Tunnicliffe commented on CASSANDRA-5397:

Yes, you're right about the {{if( column.isMarkedForDelete()) return }} being a regression.

Its down to the PRSI implementation to figure out whether an update is actually an update
or whether it actually calls for a delete. As the PRSI only has the key to work with &
is going to be inspecting the whole row anyway this shouldn't be difficult, but it does make
the whole SI/PCSI/PRCI hierarchy a bit ugly. 

Also, we do/should assume that PRSI always keeps the index exactly up to date, so I'm +1 with
making remove a no-op there.  

attached v4 for 1.2 (v3 + the no-op remove for PRSI)

> Updates to PerRowSecondaryIndex don't use most current values 
> --------------------------------------------------------------
>                 Key: CASSANDRA-5397
>                 URL:
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 1.2.3
>            Reporter: Sam Tunnicliffe
>            Assignee: Sam Tunnicliffe
>            Priority: Minor
>         Attachments: 5397_12.txt, 5397-1.2-v3.txt, 5397-1.2-v4.txt, 5397_trunk.txt, 5397.txt
> The way that updates to secondary indexes are performed using  SecondaryIndexManager.Updater
is flawed for PerRowSecondaryIndexes.  Unlike PerColumnSecondaryIndexes, which only require
the old & new values for a single column,  the expectation is that a PerRow indexer can
be given just a key which it will use to retrieve the entire row (or as many columns as it
requires) and perform its indexing on those columns.  As the indexes are updated before the
memtable atomic swap occurs, a per-row indexer may only read the previous values for the row,
not the new ones that are being written. In the case of an insert, there is no previous value
and so nothing is added to the index.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message