Class BaseTableUpsertMetadataManager
- java.lang.Object
-
- org.apache.pinot.segment.local.upsert.BaseTableUpsertMetadataManager
-
- All Implemented Interfaces:
Closeable,AutoCloseable,TableUpsertMetadataManager
- Direct Known Subclasses:
ConcurrentMapTableUpsertMetadataManager
@ThreadSafe public abstract class BaseTableUpsertMetadataManager extends Object implements TableUpsertMetadataManager
-
-
Field Summary
Fields Modifier and Type Field Description protected UpsertContext_contextprotected org.apache.helix.HelixManager_helixManagerprotected ExecutorService_segmentPreloadExecutorprotected TableDataManager_tableDataManagerprotected String_tableNameWithType
-
Constructor Summary
Constructors Constructor Description BaseTableUpsertMetadataManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UpsertConfig.ModegetUpsertMode()voidinit(TableConfig tableConfig, Schema schema, TableDataManager tableDataManager, org.apache.helix.HelixManager helixManager, ExecutorService segmentPreloadExecutor)protected voidinitCustomVariables()Can be overridden to initialize custom variables after other variables are set but before preload starts.booleanisPreloading()protected voidonPreloadFinish()Can be overridden to perform operations after preload is done.protected booleanonPreloadStart()Can be overridden to perform operations before preload starts.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.pinot.segment.local.upsert.TableUpsertMetadataManager
getOrCreatePartitionManager, getPartitionToPrimaryKeyCount, stop
-
-
-
-
Field Detail
-
_tableNameWithType
protected String _tableNameWithType
-
_tableDataManager
protected TableDataManager _tableDataManager
-
_helixManager
protected org.apache.helix.HelixManager _helixManager
-
_segmentPreloadExecutor
protected ExecutorService _segmentPreloadExecutor
-
_context
protected UpsertContext _context
-
-
Method Detail
-
init
public void init(TableConfig tableConfig, Schema schema, TableDataManager tableDataManager, org.apache.helix.HelixManager helixManager, @Nullable ExecutorService segmentPreloadExecutor)
- Specified by:
initin interfaceTableUpsertMetadataManager
-
initCustomVariables
protected void initCustomVariables()
Can be overridden to initialize custom variables after other variables are set but before preload starts. This is needed because preload will load segments which might require these custom variables.
-
onPreloadStart
protected boolean onPreloadStart()
Can be overridden to perform operations before preload starts.- Returns:
- whether to continue the preloading logic.
-
onPreloadFinish
protected void onPreloadFinish()
Can be overridden to perform operations after preload is done.
-
isPreloading
public boolean isPreloading()
- Specified by:
isPreloadingin interfaceTableUpsertMetadataManager
-
getUpsertMode
public UpsertConfig.Mode getUpsertMode()
- Specified by:
getUpsertModein interfaceTableUpsertMetadataManager
-
-