Class IndexViewManager
java.lang.Object
org.apache.cassandra.index.sai.view.IndexViewManager
Maintain an atomic view for read requests, so that requests can read all data during concurrent compactions.
All per-column SSTableIndex updates should be proxied by StorageAttachedIndexGroup to make
sure per-sstable SSTableContext are in-sync.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddrop(Collection<SSTableReader> sstablesToRebuild) voidCalled when index is dropped.update(Collection<SSTableReader> oldSSTables, Collection<SSTableContext> newSSTableContexts, IndexValidation validation) Replaces old SSTables with new by creating new immutable view.view()
-
Constructor Details
-
IndexViewManager
-
-
Method Details
-
view
-
update
public Collection<SSTableContext> update(Collection<SSTableReader> oldSSTables, Collection<SSTableContext> newSSTableContexts, IndexValidation validation) Replaces old SSTables with new by creating new immutable view.- Parameters:
oldSSTables- A set of SSTables to remove.newSSTableContexts- A set of SSTableContexts to add to tracker.validation- Controls how indexes should be validated- Returns:
- A set of SSTables which have attached to them invalid index components.
-
drop
-
invalidate
public void invalidate()Called when index is dropped. Mark allSSTableIndexas released and per-column index files will be removed when in-flight queries are completed.
-