@InterfaceAudience.Private public class WALSplitter extends Object
| 限定符和类型 | 类和说明 |
|---|---|
static class |
WALSplitter.PipelineController
Contains some methods to control WAL-entries producer / consumer interactions
|
static class |
WALSplitter.RegionEntryBuffer
A buffer of some number of edits for a given region.
|
static class |
WALSplitter.SinkWriter
Class wraps the actual writer which writes data out and related statistics
|
| 限定符和类型 | 字段和说明 |
|---|---|
protected org.apache.hadoop.conf.Configuration |
conf |
protected Map<String,Long> |
lastFlushedSequenceIds |
protected Map<String,Map<byte[],Long>> |
regionMaxSeqIdInStores |
protected LastSequenceId |
sequenceIdChecker |
static boolean |
SPLIT_SKIP_ERRORS_DEFAULT
By default we retry errors in splitting, rather than skipping.
|
static String |
SPLIT_WRITER_CREATION_BOUNDED |
protected org.apache.hadoop.fs.Path |
walDir |
protected org.apache.hadoop.fs.FileSystem |
walFS |
| 限定符和类型 | 方法和说明 |
|---|---|
protected WALProvider.Writer |
createWriter(org.apache.hadoop.fs.Path logfile)
Create a new
WALProvider.Writer for writing log splits. |
protected WAL.Reader |
getReader(org.apache.hadoop.fs.FileStatus file,
boolean skipErrors,
CancelableProgressable reporter)
Create a new
WAL.Reader for reading logs to split. |
protected WAL.Reader |
getReader(org.apache.hadoop.fs.Path curLogFile,
CancelableProgressable reporter)
Create a new
WAL.Reader for reading logs to split. |
static List<org.apache.hadoop.fs.Path> |
split(org.apache.hadoop.fs.Path rootDir,
org.apache.hadoop.fs.Path logDir,
org.apache.hadoop.fs.Path oldLogDir,
org.apache.hadoop.fs.FileSystem walFS,
org.apache.hadoop.conf.Configuration conf,
WALFactory factory) |
static boolean |
splitLogFile(org.apache.hadoop.fs.Path walDir,
org.apache.hadoop.fs.FileStatus logfile,
org.apache.hadoop.fs.FileSystem walFS,
org.apache.hadoop.conf.Configuration conf,
CancelableProgressable reporter,
LastSequenceId idChecker,
SplitLogWorkerCoordination splitLogWorkerCoordination,
WALFactory factory)
Splits a WAL file into region's recovered-edits directory.
|
public static final boolean SPLIT_SKIP_ERRORS_DEFAULT
protected final org.apache.hadoop.fs.Path walDir
protected final org.apache.hadoop.fs.FileSystem walFS
protected final org.apache.hadoop.conf.Configuration conf
protected final LastSequenceId sequenceIdChecker
public static boolean splitLogFile(org.apache.hadoop.fs.Path walDir,
org.apache.hadoop.fs.FileStatus logfile,
org.apache.hadoop.fs.FileSystem walFS,
org.apache.hadoop.conf.Configuration conf,
CancelableProgressable reporter,
LastSequenceId idChecker,
SplitLogWorkerCoordination splitLogWorkerCoordination,
WALFactory factory)
throws IOException
If the log file has N regions then N recovered.edits files will be produced.
IOExceptionpublic static List<org.apache.hadoop.fs.Path> split(org.apache.hadoop.fs.Path rootDir, org.apache.hadoop.fs.Path logDir, org.apache.hadoop.fs.Path oldLogDir, org.apache.hadoop.fs.FileSystem walFS, org.apache.hadoop.conf.Configuration conf, WALFactory factory) throws IOException
IOExceptionprotected WAL.Reader getReader(org.apache.hadoop.fs.FileStatus file, boolean skipErrors, CancelableProgressable reporter) throws IOException, org.apache.hadoop.hbase.wal.WALSplitter.CorruptedLogFileException
WAL.Reader for reading logs to split.protected WALProvider.Writer createWriter(org.apache.hadoop.fs.Path logfile) throws IOException
WALProvider.Writer for writing log splits.IOExceptionprotected WAL.Reader getReader(org.apache.hadoop.fs.Path curLogFile, CancelableProgressable reporter) throws IOException
WAL.Reader for reading logs to split.IOExceptionCopyright © 2007–2020 The Apache Software Foundation. All rights reserved.