Class SegmentDirectory.Writer
- java.lang.Object
-
- org.apache.pinot.segment.spi.store.SegmentDirectory.Reader
-
- org.apache.pinot.segment.spi.store.SegmentDirectory.Writer
-
- All Implemented Interfaces:
Closeable,AutoCloseable
- Enclosing class:
- SegmentDirectory
public abstract class SegmentDirectory.Writer extends SegmentDirectory.Reader
Writer to update columnar index. Read about the semantics at the top
-
-
Constructor Summary
Constructors Constructor Description Writer()
-
Method Summary
Modifier and Type Method Description abstract PinotDataBuffernewIndexFor(String columnName, ColumnIndexType indexType, long sizeBytes)create a new buffer for writers to store index.abstract voidremoveIndex(String columnName, ColumnIndexType indexType)Removes an existing column index from directoryabstract voidsave()abstract StringtoString()-
Methods inherited from class org.apache.pinot.segment.spi.store.SegmentDirectory.Reader
getIndexFor, getStarTreeIndex, getStarTreeIndexMap, hasIndexFor, toSegmentDirectory
-
-
-
-
Method Detail
-
newIndexFor
public abstract PinotDataBuffer newIndexFor(String columnName, ColumnIndexType indexType, long sizeBytes) throws IOException
create a new buffer for writers to store index. This buffer will be visible after this point. Failures in the middle can cause corruption.- Parameters:
columnName- column nameindexType- column index typesizeBytes- sizeBytes of index data- Returns:
- PinotDataBufferOld that writers can update
- Throws:
IOException
-
removeIndex
public abstract void removeIndex(String columnName, ColumnIndexType indexType)
Removes an existing column index from directory- Parameters:
columnName- column nameindexType- column index type
-
save
public abstract void save() throws IOException- Throws:
IOException
-
toString
public abstract String toString()
- Specified by:
toStringin classSegmentDirectory.Reader
-
-