@InterfaceAudience.Private public class RecoveredReplicationSource extends ReplicationSource
ReplicationSource.LogsComparator
Modifier and Type | Field and Description |
---|---|
private String |
actualPeerId |
private static org.slf4j.Logger |
LOG |
conf, DEFAULT_WAIT_ON_ENDPOINT_SECONDS, fs, manager, queueId, queueSizePerGroup, queueStorage, replicationPeer, replicationQueueInfo, server, WAIT_ON_ENDPOINT_SECONDS, walEntryFilter, workerThreads
Constructor and Description |
---|
RecoveredReplicationSource() |
Modifier and Type | Method and Description |
---|---|
protected RecoveredReplicationSourceShipper |
createNewShipper(String walGroupId,
PriorityBlockingQueue<org.apache.hadoop.fs.Path> queue) |
String |
getPeerId()
Get the id that the source is replicating to.
|
private org.apache.hadoop.fs.Path |
getReplSyncUpPath(org.apache.hadoop.fs.Path path) |
ServerName |
getServerWALsBelongTo()
The queue of WALs only belong to one region server.
|
void |
init(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
ReplicationSourceManager manager,
ReplicationQueueStorage queueStorage,
ReplicationPeer replicationPeer,
Server server,
String peerClusterZnode,
UUID clusterId,
WALFileLengthProvider walFileLengthProvider,
MetricsSource metrics)
Instantiation method used by region servers
|
boolean |
isRecovered() |
void |
locateRecoveredPaths(PriorityBlockingQueue<org.apache.hadoop.fs.Path> queue) |
(package private) void |
tryFinish() |
addHFileRefs, enqueueLog, getCurrentPath, getQueueId, getQueueStorage, getReplicationEndpoint, getServer, getSourceManager, getSourceMetrics, getStats, getWALFileLengthProvider, getWalGroupStatus, isPeerEnabled, isSourceActive, postShipEdits, sleepForRetries, startup, terminate, terminate, terminate, terminate, tryThrottle, uncaughtException
private static final org.slf4j.Logger LOG
private String actualPeerId
public RecoveredReplicationSource()
public void init(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.FileSystem fs, ReplicationSourceManager manager, ReplicationQueueStorage queueStorage, ReplicationPeer replicationPeer, Server server, String peerClusterZnode, UUID clusterId, WALFileLengthProvider walFileLengthProvider, MetricsSource metrics) throws IOException
ReplicationSource
init
in interface ReplicationSourceInterface
init
in class ReplicationSource
conf
- configuration to usefs
- file system to usemanager
- replication manager to ping toserver
- the server for this region serverpeerClusterZnode
- the id of our replication queueclusterId
- unique UUID for the clustermetrics
- metrics for replication sourceIOException
protected RecoveredReplicationSourceShipper createNewShipper(String walGroupId, PriorityBlockingQueue<org.apache.hadoop.fs.Path> queue)
createNewShipper
in class ReplicationSource
public void locateRecoveredPaths(PriorityBlockingQueue<org.apache.hadoop.fs.Path> queue) throws IOException
IOException
private org.apache.hadoop.fs.Path getReplSyncUpPath(org.apache.hadoop.fs.Path path) throws IOException
IOException
void tryFinish()
public String getPeerId()
ReplicationSourceInterface
getPeerId
in interface ReplicationSourceInterface
getPeerId
in class ReplicationSource
public ServerName getServerWALsBelongTo()
ReplicationSourceInterface
getServerWALsBelongTo
in interface ReplicationSourceInterface
getServerWALsBelongTo
in class ReplicationSource
public boolean isRecovered()
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.