@InterfaceAudience.LimitedPrivate(value="Replication") public abstract class BaseReplicationEndpoint extends com.google.common.util.concurrent.AbstractService implements ReplicationEndpoint
ReplicationEndpoint
s. Users should consider extending this
class rather than implementing ReplicationEndpoint
directly for better backwards
compatibility.ReplicationEndpoint.Context, ReplicationEndpoint.ReplicateContext
Modifier and Type | Field and Description |
---|---|
protected ReplicationEndpoint.Context |
ctx |
Constructor and Description |
---|
BaseReplicationEndpoint() |
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
|
void |
close() |
protected WALEntryFilter |
getScopeWALEntryFilter()
Returns a WALEntryFilter for checking the scope.
|
protected WALEntryFilter |
getTableCfWALEntryFilter()
Returns a WALEntryFilter for checking replication per table and CF.
|
WALEntryFilter |
getWALEntryfilter()
Returns a default set of filters
|
void |
init(ReplicationEndpoint.Context context)
Initialize the replication endpoint with the given context.
|
void |
peerConfigUpdated(ReplicationPeerConfig rpc)
Callback method for when users update the ReplicationPeerConfig for this peer
|
doStart, doStop, isRunning, notifyFailed, notifyStarted, notifyStopped, start, startAndWait, state, stop, stopAndWait, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getPeerUUID, replicate
protected ReplicationEndpoint.Context ctx
public void init(ReplicationEndpoint.Context context) throws IOException
ReplicationEndpoint
init
in interface ReplicationEndpoint
context
- replication contextIOException
public void peerConfigUpdated(ReplicationPeerConfig rpc)
ReplicationPeerConfigListener
peerConfigUpdated
in interface ReplicationPeerConfigListener
rpc
- The updated ReplicationPeerConfigpublic WALEntryFilter getWALEntryfilter()
getWALEntryfilter
in interface ReplicationEndpoint
WALEntryFilter
or null.protected WALEntryFilter getScopeWALEntryFilter()
protected WALEntryFilter getTableCfWALEntryFilter()
public boolean canReplicateToSameCluster()
ReplicationEndpoint
canReplicateToSameCluster
in interface ReplicationEndpoint
public void close()
Copyright © 2007–2019 The Apache Software Foundation. All rights reserved.