public interface HoodieTableMetadataWriter extends Serializable, AutoCloseable
| Modifier and Type | Method and Description |
|---|---|
void |
buildMetadataPartitions(HoodieEngineContext engineContext,
List<HoodieIndexPartitionInfo> indexPartitionInfos)
Builds the given metadata partitions to create index.
|
void |
deletePartitions(String instantTime,
List<MetadataPartitionType> partitions)
Deletes the given metadata partitions.
|
void |
dropMetadataPartitions(List<MetadataPartitionType> metadataPartitions)
Drop the given metadata partitions.
|
boolean |
isInitialized()
Returns true if the metadata table is initialized.
|
void |
performTableServices(Option<String> inFlightInstantTimestamp)
Perform various table services like compaction, cleaning, archiving on the MDT if required.
|
void |
update(HoodieCleanMetadata cleanMetadata,
String instantTime)
Update the metadata table due to a CLEAN operation.
|
void |
update(HoodieCommitMetadata commitMetadata,
HoodieData<WriteStatus> writeStatuses,
String instantTime)
Update the metadata table due to a COMMIT operation.
|
void |
update(HoodieRestoreMetadata restoreMetadata,
String instantTime)
Update the metadata table due to a RESTORE operation.
|
void |
update(HoodieRollbackMetadata rollbackMetadata,
String instantTime)
Update the metadata table due to a ROLLBACK operation.
|
closevoid buildMetadataPartitions(HoodieEngineContext engineContext, List<HoodieIndexPartitionInfo> indexPartitionInfos) throws IOException
engineContext - indexPartitionInfos - - information about partitions to build such as partition type and base instant timeIOExceptionvoid dropMetadataPartitions(List<MetadataPartitionType> metadataPartitions) throws IOException
metadataPartitions - List of MDT partitions to dropIOException - on failuresvoid update(HoodieCommitMetadata commitMetadata, HoodieData<WriteStatus> writeStatuses, String instantTime)
commitMetadata - commit metadata of the operation of interest.instantTime - instant time of the commit.void update(HoodieCleanMetadata cleanMetadata, String instantTime)
cleanMetadata - clean metadata of the operation of interest.instantTime - instant time of the commit.void update(HoodieRestoreMetadata restoreMetadata, String instantTime)
restoreMetadata - restore metadata of the operation of interest.instantTime - instant time of the commit.void update(HoodieRollbackMetadata rollbackMetadata, String instantTime)
rollbackMetadata - rollback metadata of the operation of interest.instantTime - instant time of the commit.void deletePartitions(String instantTime, List<MetadataPartitionType> partitions)
instantTime - - instant time when replacecommit corresponding to the drop will be recorded in the metadata timelinepartitions - - list of MetadataPartitionType to dropboolean isInitialized()
void performTableServices(Option<String> inFlightInstantTimestamp)
inFlightInstantTimestamp - Timestamp of an instant which is in-progress. This instant is ignored while
deciding if optimizations can be performed.Copyright © 2023 The Apache Software Foundation. All rights reserved.