@InterfaceAudience.LimitedPrivate(value="Configuration") public class BackupHFileCleaner extends BaseHFileCleanerDelegate implements Abortable
Modifier and Type | Field and Description |
---|---|
private boolean |
aborted |
private boolean |
checkForFullyBackedUpTables |
private org.apache.hadoop.conf.Configuration |
conf |
private Connection |
connection |
private List<TableName> |
fullyBackedUpTables |
private static org.slf4j.Logger |
LOG |
private long |
prevReadFromBackupTbl |
private long |
secondPrevReadFromBackupTbl |
private boolean |
stopped |
Constructor and Description |
---|
BackupHFileCleaner() |
Modifier and Type | Method and Description |
---|---|
void |
abort(String why,
Throwable e)
Abort the server or client.
|
Iterable<org.apache.hadoop.fs.FileStatus> |
getDeletableFiles(Iterable<org.apache.hadoop.fs.FileStatus> files)
Determines which of the given files are safe to delete
|
private Set<String> |
getFilenameFromBulkLoad(Map<byte[],List<org.apache.hadoop.fs.Path>>[] maps) |
boolean |
isAborted()
Check if the server or client was aborted.
|
boolean |
isFileDeletable(org.apache.hadoop.fs.FileStatus fStat)
Should the master delete the file or keep it?
|
boolean |
isStopped()
Returns True if
Stoppable.stop(String) has been closed. |
private Set<String> |
loadHFileRefs(List<TableName> tableList) |
(package private) void |
setCheckForFullyBackedUpTables(boolean b) |
void |
setConf(org.apache.hadoop.conf.Configuration config) |
void |
stop(String why)
Stop this service.
|
init
getConf
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
isEmptyDirDeletable, postClean, preClean
private static final org.slf4j.Logger LOG
private boolean stopped
private boolean aborted
private org.apache.hadoop.conf.Configuration conf
private Connection connection
private long prevReadFromBackupTbl
private long secondPrevReadFromBackupTbl
private boolean checkForFullyBackedUpTables
private List<TableName> fullyBackedUpTables
public BackupHFileCleaner()
private Set<String> getFilenameFromBulkLoad(Map<byte[],List<org.apache.hadoop.fs.Path>>[] maps)
private Set<String> loadHFileRefs(List<TableName> tableList) throws IOException
IOException
@InterfaceAudience.Private void setCheckForFullyBackedUpTables(boolean b)
public Iterable<org.apache.hadoop.fs.FileStatus> getDeletableFiles(Iterable<org.apache.hadoop.fs.FileStatus> files)
FileCleanerDelegate
getDeletableFiles
in interface FileCleanerDelegate
getDeletableFiles
in class BaseFileCleanerDelegate
files
- files to check for deletionpublic boolean isFileDeletable(org.apache.hadoop.fs.FileStatus fStat)
BaseFileCleanerDelegate
isFileDeletable
in class BaseFileCleanerDelegate
fStat
- file status of the file to checkpublic void setConf(org.apache.hadoop.conf.Configuration config)
setConf
in interface org.apache.hadoop.conf.Configurable
setConf
in class BaseConfigurable
public void stop(String why)
Stoppable
stop
in interface Stoppable
stop
in class BaseHFileCleanerDelegate
why
- Why we're stopping.public boolean isStopped()
Stoppable
Stoppable.stop(String)
has been closed.isStopped
in interface Stoppable
isStopped
in class BaseHFileCleanerDelegate
public void abort(String why, Throwable e)
Abortable
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.