@InterfaceAudience.Private public class RegionReplicaReplicationEndpoint extends HBaseReplicationEndpoint
ReplicationEndpoint
endpoint
which receives the WAL edits from the WAL, and sends the edits to replicas
of regions.HBaseReplicationEndpoint.PeerRegionServerListener
ReplicationEndpoint.Context, ReplicationEndpoint.ReplicateContext
ctx, REPLICATION_WALENTRYFILTER_CONFIG_KEY
Constructor and Description |
---|
RegionReplicaReplicationEndpoint() |
Modifier and Type | Method and Description |
---|---|
boolean |
canReplicateToSameCluster()
Whether or not, the replication endpoint can replicate to it's source cluster with the same
UUID
|
protected void |
doStart() |
protected void |
doStop() |
protected WALEntryFilter |
getScopeWALEntryFilter()
Returns a WALEntryFilter for checking the scope.
|
void |
init(ReplicationEndpoint.Context context)
Initialize the replication endpoint with the given context.
|
boolean |
replicate(ReplicationEndpoint.ReplicateContext replicateContext)
Replicate the given set of entries (in the context) to the other cluster.
|
abort, disconnect, fetchSlavesAddresses, getLastRegionServerUpdate, getPeerUUID, getRegionServers, getZkw, isAborted, reconnect, setRegionServers, start, stop
getNamespaceTableCfWALEntryFilter, getWALEntryfilter, isStarting, peerConfigUpdated
addListener, awaitRunning, awaitRunning, awaitTerminated, awaitTerminated, doCancelStart, failureCause, isRunning, notifyFailed, notifyStarted, notifyStopped, startAsync, state, stopAsync, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
awaitRunning, awaitRunning, awaitTerminated, awaitTerminated, failureCause, isRunning
public void init(ReplicationEndpoint.Context context) throws IOException
ReplicationEndpoint
init
in interface ReplicationEndpoint
init
in class BaseReplicationEndpoint
context
- replication contextIOException
- error occur when initialize the endpoint.protected void doStart()
doStart
in class HBaseReplicationEndpoint
protected void doStop()
doStop
in class HBaseReplicationEndpoint
public boolean replicate(ReplicationEndpoint.ReplicateContext replicateContext)
ReplicationEndpoint
replicateContext
- a context where WAL entries and other
parameters can be obtained.public boolean canReplicateToSameCluster()
ReplicationEndpoint
canReplicateToSameCluster
in interface ReplicationEndpoint
canReplicateToSameCluster
in class BaseReplicationEndpoint
protected WALEntryFilter getScopeWALEntryFilter()
BaseReplicationEndpoint
getScopeWALEntryFilter
in class BaseReplicationEndpoint
Copyright © 2007–2019 Cloudera. All rights reserved.