@InterfaceAudience.Private public final class SnapshotReferenceUtil extends Object
| Modifier and Type | Class and Description |
|---|---|
static interface |
SnapshotReferenceUtil.SnapshotVisitor |
static interface |
SnapshotReferenceUtil.StoreFileVisitor |
| Modifier and Type | Method and Description |
|---|---|
static void |
concurrentVisitReferencedFiles(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
SnapshotManifest manifest,
ExecutorService exec,
SnapshotReferenceUtil.StoreFileVisitor visitor) |
static void |
concurrentVisitReferencedFiles(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
SnapshotManifest manifest,
String desc,
SnapshotReferenceUtil.StoreFileVisitor visitor) |
static Set<String> |
getHFileNames(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path snapshotDir)
Returns the store file names in the snapshot.
|
static void |
verifySnapshot(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path snapshotDir,
org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.SnapshotDescription snapshotDesc)
Verify the validity of the snapshot
|
static void |
verifySnapshot(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
SnapshotManifest manifest)
Verify the validity of the snapshot
|
static void |
visitReferencedFiles(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path snapshotDir,
org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.SnapshotDescription desc,
SnapshotReferenceUtil.SnapshotVisitor visitor)
Iterate over the snapshot store files, restored.edits and logs
|
static void |
visitReferencedFiles(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path snapshotDir,
SnapshotReferenceUtil.SnapshotVisitor visitor)
Iterate over the snapshot store files
|
public static void visitReferencedFiles(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path snapshotDir,
SnapshotReferenceUtil.SnapshotVisitor visitor)
throws IOException
conf - The current Configuration instance.fs - FileSystemsnapshotDir - Path to the Snapshot directoryvisitor - callback object to get the referenced filesIOException - if an error occurred while scanning the directorypublic static void visitReferencedFiles(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path snapshotDir,
org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.SnapshotDescription desc,
SnapshotReferenceUtil.SnapshotVisitor visitor)
throws IOException
conf - The current Configuration instance.fs - FileSystemsnapshotDir - Path to the Snapshot directorydesc - the HBaseProtos.SnapshotDescription of the snapshot to verifyvisitor - callback object to get the referenced filesIOException - if an error occurred while scanning the directorypublic static void verifySnapshot(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path snapshotDir,
org.apache.hadoop.hbase.protobuf.generated.HBaseProtos.SnapshotDescription snapshotDesc)
throws IOException
conf - The current Configuration instance.fs - FileSystemsnapshotDir - Path to the Snapshot directory of the snapshot to verifysnapshotDesc - the HBaseProtos.SnapshotDescription of the snapshot to verifyCorruptedSnapshotException - if the snapshot is corruptedIOException - if an error occurred while scanning the directorypublic static void verifySnapshot(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
SnapshotManifest manifest)
throws IOException
conf - The current Configuration instance.fs - FileSystemmanifest - snapshot manifest to inspectCorruptedSnapshotException - if the snapshot is corruptedIOException - if an error occurred while scanning the directorypublic static void concurrentVisitReferencedFiles(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
SnapshotManifest manifest,
String desc,
SnapshotReferenceUtil.StoreFileVisitor visitor)
throws IOException
IOExceptionpublic static void concurrentVisitReferencedFiles(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
SnapshotManifest manifest,
ExecutorService exec,
SnapshotReferenceUtil.StoreFileVisitor visitor)
throws IOException
IOExceptionpublic static Set<String> getHFileNames(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path snapshotDir) throws IOException
conf - The current Configuration instance.fs - FileSystemsnapshotDir - Path to the Snapshot directoryIOException - if an error occurred while scanning the directoryCopyright © 2007–2019 The Apache Software Foundation. All rights reserved.