@InterfaceAudience.Private public class LogCleaner extends CleanerChore<BaseLogCleanerDelegate>
BaseLogCleanerDelegate
Modifier and Type | Field and Description |
---|---|
private static org.apache.commons.logging.Log |
LOG |
cleanersChain, params
Constructor and Description |
---|
LogCleaner(int p,
Stoppable s,
org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path oldLogDir) |
Modifier and Type | Method and Description |
---|---|
protected boolean |
validate(org.apache.hadoop.fs.Path file)
Validate the file to see if it even belongs in the directory.
|
checkAndDeleteDirectory, chore, cleanup
cancel, cancel, choreForTesting, getInitialDelay, getName, getPeriod, getStopper, getTimeUnit, initialChore, isInitialChoreComplete, isScheduled, run, toString, triggerNow
public LogCleaner(int p, Stoppable s, org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path oldLogDir)
p
- the period of time to sleep between each runs
- the stopperconf
- configuration to usefs
- handle to the FSoldLogDir
- the path to the archived logsprotected boolean validate(org.apache.hadoop.fs.Path file)
CleanerChore
validate
in class CleanerChore<BaseLogCleanerDelegate>
file
- full Path
of the file to be checkedCopyright © 2007–2019 The Apache Software Foundation. All rights reserved.