public class ChangelogDeletion extends FileDeletionBase<Changelog>
changelogDecoupled, deletionBuckets, fileIO, indexFileHandler, manifestFile, manifestList, pathFactory, statsFileHandler
Constructor and Description |
---|
ChangelogDeletion(FileIO fileIO,
FileStorePathFactory pathFactory,
ManifestFile manifestFile,
ManifestList manifestList,
IndexFileHandler indexFileHandler,
StatsFileHandler statsFileHandler,
boolean cleanEmptyDirectories,
int deleteFileThreadNum) |
Modifier and Type | Method and Description |
---|---|
void |
cleanUnusedDataFiles(Changelog changelog,
java.util.function.Predicate<ManifestEntry> skipper)
Clean data files that will not be used anymore in the snapshot.
|
void |
cleanUnusedManifests(Changelog changelog,
Set<String> skippingSet)
Clean metadata files that will not be used anymore of a snapshot, including data manifests,
index manifests and manifest lists.
|
Set<String> |
manifestSkippingSet(List<Snapshot> skippingSnapshots) |
addMergedDataFiles, cleanEmptyDirectories, cleanUnusedDataFiles, cleanUnusedIndexManifests, cleanUnusedManifestList, cleanUnusedManifests, cleanUnusedStatisticsManifests, containsDataFile, createDataFileSkipperForTags, deleteAddedDataFiles, deleteFiles, doCleanUnusedDataFile, getDataFileToDelete, manifestSkippingSet, readManifestFileNames, readMergedDataFiles, recordDeletionBuckets, setChangelogDecoupled, tryReadDataManifests, tryReadManifestList
public ChangelogDeletion(FileIO fileIO, FileStorePathFactory pathFactory, ManifestFile manifestFile, ManifestList manifestList, IndexFileHandler indexFileHandler, StatsFileHandler statsFileHandler, boolean cleanEmptyDirectories, int deleteFileThreadNum)
public void cleanUnusedDataFiles(Changelog changelog, java.util.function.Predicate<ManifestEntry> skipper)
FileDeletionBase
cleanUnusedDataFiles
in class FileDeletionBase<Changelog>
changelog
- Snapshot
that will be cleanedskipper
- if the test result of a data file is true, it will be skipped when deleting;
else it will be deletedpublic void cleanUnusedManifests(Changelog changelog, Set<String> skippingSet)
FileDeletionBase
cleanUnusedManifests
in class FileDeletionBase<Changelog>
changelog
- Snapshot
that will be cleanedskippingSet
- manifests that should not be deletedpublic Set<String> manifestSkippingSet(List<Snapshot> skippingSnapshots)
manifestSkippingSet
in class FileDeletionBase<Changelog>
Copyright © 2023–2024 The Apache Software Foundation. All rights reserved.