Class SecureBulkLoadManager.SecureBulkLoadListener
java.lang.Object
org.apache.hadoop.hbase.regionserver.SecureBulkLoadManager.SecureBulkLoadListener
- All Implemented Interfaces:
HRegion.BulkLoadListener
- Enclosing class:
- SecureBulkLoadManager
static class SecureBulkLoadManager.SecureBulkLoadListener
extends Object
implements HRegion.BulkLoadListener
-
Field Summary
Modifier and TypeFieldDescriptionprivate final org.apache.hadoop.conf.Configuration
private final org.apache.hadoop.fs.FileSystem
private org.apache.hadoop.fs.FileSystem
private final String
-
Constructor Summary
ConstructorDescriptionSecureBulkLoadListener
(org.apache.hadoop.fs.FileSystem fs, String stagingDir, org.apache.hadoop.conf.Configuration conf) -
Method Summary
Modifier and TypeMethodDescriptionprivate void
void
doneBulkLoad
(byte[] family, String srcPath) Called after a successful HFile loadvoid
failedBulkLoad
(byte[] family, String stagedPath) Called after a failed HFile loadprivate boolean
isFile
(org.apache.hadoop.fs.Path p) Check if the path is referencing a file.prepareBulkLoad
(byte[] family, String srcPath, boolean copyFile, String customStaging) Called before an HFile is actually loaded
-
Field Details
-
fs
-
stagingDir
-
conf
-
srcFs
-
origPermissions
-
origSources
-
-
Constructor Details
-
SecureBulkLoadListener
public SecureBulkLoadListener(org.apache.hadoop.fs.FileSystem fs, String stagingDir, org.apache.hadoop.conf.Configuration conf)
-
-
Method Details
-
prepareBulkLoad
public String prepareBulkLoad(byte[] family, String srcPath, boolean copyFile, String customStaging) throws IOException Description copied from interface:HRegion.BulkLoadListener
Called before an HFile is actually loaded- Specified by:
prepareBulkLoad
in interfaceHRegion.BulkLoadListener
- Parameters:
family
- family being loaded tosrcPath
- path of HFile- Returns:
- final path to be used for actual loading
- Throws:
IOException
-
doneBulkLoad
Description copied from interface:HRegion.BulkLoadListener
Called after a successful HFile load- Specified by:
doneBulkLoad
in interfaceHRegion.BulkLoadListener
- Parameters:
family
- family being loaded tosrcPath
- path of HFile- Throws:
IOException
-
closeSrcFs
- Throws:
IOException
-
failedBulkLoad
Description copied from interface:HRegion.BulkLoadListener
Called after a failed HFile load- Specified by:
failedBulkLoad
in interfaceHRegion.BulkLoadListener
- Parameters:
family
- family being loaded tostagedPath
- path of HFile- Throws:
IOException
-
isFile
Check if the path is referencing a file. This is mainly needed to avoid symlinks.- Returns:
- true if the p is a file
- Throws:
IOException
-