public class CloneFilesUtil extends Object
Constructor and Description |
---|
CloneFilesUtil() |
Modifier and Type | Method and Description |
---|---|
static List<Pair<Path,Path>> |
getDataUsedFilesForSnapshot(FileStoreTable table,
long snapshotId)
Retrieves a map of data file types to their corresponding list of file paths for a given
snapshot.
|
static FileIO |
getFileIO(Map<String,FileIO> fileIOs,
String identifier,
Catalog catalog) |
static List<Path> |
getManifestUsedFilesForSnapshot(FileStoreTable table,
long snapshotId)
Retrieves a map of manifest file types to their corresponding list of file paths for a given
snapshot.
|
static Path |
getPath(Map<String,Path> locations,
String identifier,
Catalog catalog) |
static Path |
getPathExcludeTableRoot(Path absolutePath,
Path sourceTableRoot) |
static List<Path> |
getSchemaUsedFilesForSnapshot(FileStoreTable table,
long snapshotId)
Retrieves a map of schema file types to their corresponding list of file paths for a given
snapshot。 The schema file types include: Snapshot, Schema, ManifestList, StatisticFile and
IndexFile .
|
static Path |
pathOfTable(Table table) |
static <T> T |
retryReadingFiles(SupplierWithIOException<T> reader) |
static List<CloneFileInfo> |
toCloneFileInfos(List<Pair<Path,Path>> fileList,
String sourceIdentifier,
String targetIdentifier) |
static List<CloneFileInfo> |
toCloneFileInfos(List<Path> fileList,
Path sourceTableRoot,
String sourceIdentifier,
String targetIdentifier) |
public static List<Path> getSchemaUsedFilesForSnapshot(FileStoreTable table, long snapshotId) throws IOException
table
- The FileStoreTable object representing the table.snapshotId
- The ID of the snapshot to retrieve files for.FileNotFoundException
- If the snapshot file is not found.IOException
public static List<Pair<Path,Path>> getDataUsedFilesForSnapshot(FileStoreTable table, long snapshotId) throws FileNotFoundException
table
- The FileStoreTable object representing the table.snapshotId
- The ID of the snapshot to retrieve files for.FileNotFoundException
- If the snapshot file is not found.public static List<Path> getManifestUsedFilesForSnapshot(FileStoreTable table, long snapshotId) throws IOException
table
- The FileStoreTable object representing the table.snapshotId
- The ID of the snapshot to retrieve files for.FileNotFoundException
- If the snapshot file is not found.IOException
@Nullable public static <T> T retryReadingFiles(SupplierWithIOException<T> reader) throws IOException
IOException
public static List<CloneFileInfo> toCloneFileInfos(List<Path> fileList, Path sourceTableRoot, String sourceIdentifier, String targetIdentifier)
public static List<CloneFileInfo> toCloneFileInfos(List<Pair<Path,Path>> fileList, String sourceIdentifier, String targetIdentifier)
public static Path getPathExcludeTableRoot(Path absolutePath, Path sourceTableRoot)
public static FileIO getFileIO(Map<String,FileIO> fileIOs, String identifier, Catalog catalog)
Copyright © 2023–2025 The Apache Software Foundation. All rights reserved.