@InterfaceAudience.Private class ReplicationSourceWALActionListener extends Object implements WALActionsListener
WALActionsListener.RollRequestReason| Modifier and Type | Field and Description |
|---|---|
private org.apache.hadoop.conf.Configuration |
conf |
private ReplicationSourceManager |
manager |
| Constructor and Description |
|---|
ReplicationSourceWALActionListener(org.apache.hadoop.conf.Configuration conf,
ReplicationSourceManager manager) |
| Modifier and Type | Method and Description |
|---|---|
void |
postLogRoll(org.apache.hadoop.fs.Path oldPath,
org.apache.hadoop.fs.Path newPath)
The WAL has been rolled.
|
void |
preLogRoll(org.apache.hadoop.fs.Path oldPath,
org.apache.hadoop.fs.Path newPath)
The WAL is going to be rolled.
|
(package private) static void |
scopeWALEdits(WALKey logKey,
WALEdit logEdit,
org.apache.hadoop.conf.Configuration conf)
Utility method used to set the correct scopes on each log key.
|
void |
visitLogEntryBeforeWrite(WALKey logKey,
WALEdit logEdit) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitlogCloseRequested, logRollRequested, postAppend, postLogArchive, postSync, preLogArchive, visitLogEntryBeforeWriteprivate final org.apache.hadoop.conf.Configuration conf
private final ReplicationSourceManager manager
public ReplicationSourceWALActionListener(org.apache.hadoop.conf.Configuration conf, ReplicationSourceManager manager)
public void preLogRoll(org.apache.hadoop.fs.Path oldPath, org.apache.hadoop.fs.Path newPath) throws IOException
WALActionsListenerpreLogRoll in interface WALActionsListeneroldPath - the path to the old walnewPath - the path to the new walIOExceptionpublic void postLogRoll(org.apache.hadoop.fs.Path oldPath, org.apache.hadoop.fs.Path newPath) throws IOException
WALActionsListenerpostLogRoll in interface WALActionsListeneroldPath - the path to the old walnewPath - the path to the new walIOExceptionpublic void visitLogEntryBeforeWrite(WALKey logKey, WALEdit logEdit) throws IOException
visitLogEntryBeforeWrite in interface WALActionsListenerlogEdit - TODO: Retire this in favor of
WALActionsListener.visitLogEntryBeforeWrite(RegionInfo, WALKey, WALEdit) It only exists to get
scope when replicating. Scope should be in the WALKey and not need us passing in a
htd.IOException - If failed to parse the WALEditstatic void scopeWALEdits(WALKey logKey, WALEdit logEdit, org.apache.hadoop.conf.Configuration conf)
logKey - Key that may get scoped according to its editslogEdit - Edits used to lookup the scopesCopyright © 2007–2021 The Apache Software Foundation. All rights reserved.