[
https://issues.apache.org/jira/browse/CASSANDRA-21515?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Caleb Rackliffe updated CASSANDRA-21515:
----------------------------------------
Labels: SAI (was: )
> Avoid Rebuilding Per-SSTable SAI Components Unless All Column Indexes are
> Being Rebuilt
> ---------------------------------------------------------------------------------------
>
> Key: CASSANDRA-21515
> URL: https://issues.apache.org/jira/browse/CASSANDRA-21515
> Project: Apache Cassandra
> Issue Type: Bug
> Components: Feature/2i Index
> Reporter: Caleb Rackliffe
> Assignee: Caleb Rackliffe
> Priority: Normal
> Labels: SAI
>
> When a table has multiple SAI indexes, they share per-SSTable index
> components (the primary key map, token/partition-key blocks, group metadata).
> Running nodetool rebuild_index naming only one of those indexes triggers a
> "full rebuild" path that unlinks and rewrites those shared components on
> every SSTable, but only the rebuilt index is notified: its view is refreshed
> against the newly-written state, while the bystander indexes are never told.
> Those bystanders keep serving queries through their existing {{SSTableIndex}}
> objects, which hold ref-counted shared copies of the old {{SSTableContext}},
> so they silently continue resolving row IDs through the now-unlinked (but
> still mmap'd) old primary key map, and only release that stale reference when
> the sstable is compacted, the bystander is itself dropped or rebuilt, or the
> node restarts. Nothing in the code path fails, marks the bystanders
> non-queryable, or checks that the rewritten mapping matches the old one;
> correctness holds only because row-ID ordering happens to be deterministic
> given the same input sstable, and the cost is a hidden disk/FD leak plus
> under-reported per-SSTable metrics until the stale references are finally
> released.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]