Class ReplicationMarkerChore
java.lang.Object
org.apache.hadoop.hbase.ScheduledChore
org.apache.hadoop.hbase.replication.regionserver.ReplicationMarkerChore
- All Implemented Interfaces:
Runnable
This chore is responsible to create replication marker rows with special WALEdit with family as
WALEdit.METAFAMILY
and column qualifier as
WALEdit.REPLICATION_MARKER
and empty value. If config key
REPLICATION_MARKER_ENABLED_KEY
is set to true, then we will create 1 marker row every
REPLICATION_MARKER_CHORE_DURATION_KEY
ms
ReplicationSourceWALReader
will populate
the Replication Marker edit with region_server_name, wal_name and wal_offset encoded in
WALProtos.ReplicationMarkerDescriptor
object. Replication
will change the
REPLICATION_SCOPE for this edit to GLOBAL so that it can replicate. On the sink cluster,
ReplicationSink
will convert the
ReplicationMarkerDescriptor into a Put mutation to REPLICATION_SINK_TRACKER_TABLE_NAME_STR table.-
Field Summary
Modifier and TypeFieldDescriptionprivate static final String
private static final org.slf4j.Logger
private static final MultiVersionConcurrencyControl
static final RegionInfo
static final int
static final String
static final boolean
static final String
private final RegionServerServices
private WAL
-
Constructor Summary
ConstructorDescriptionReplicationMarkerChore
(Stoppable stopper, RegionServerServices rsServices, int period) -
Method Summary
Methods inherited from class org.apache.hadoop.hbase.ScheduledChore
cancel, cancel, choreForTesting, cleanup, getInitialDelay, getName, getPeriod, getStopper, getTimeUnit, initialChore, isInitialChoreComplete, isScheduled, run, shutdown, shutdown, toString, triggerNow
-
Field Details
-
LOG
-
MVCC
-
REGION_INFO
-
DELIMITER
- See Also:
-
rsServices
-
wal
-
REPLICATION_MARKER_ENABLED_KEY
- See Also:
-
REPLICATION_MARKER_ENABLED_DEFAULT
- See Also:
-
REPLICATION_MARKER_CHORE_DURATION_KEY
- See Also:
-
REPLICATION_MARKER_CHORE_DURATION_DEFAULT
- See Also:
-
-
Constructor Details
-
ReplicationMarkerChore
-
-
Method Details
-
chore
Description copied from class:ScheduledChore
The task to execute on each scheduled execution of the Chore- Specified by:
chore
in classScheduledChore
-
getRowKey
Creates a rowkey with region server name and timestamp.- Parameters:
serverName
- region server nametimestamp
- timestamp
-