Class SyncReplicationPeerInfoProviderImpl
java.lang.Object
org.apache.hadoop.hbase.replication.regionserver.SyncReplicationPeerInfoProviderImpl
- All Implemented Interfaces:
SyncReplicationPeerInfoProvider
@Private
class SyncReplicationPeerInfoProviderImpl
extends Object
implements SyncReplicationPeerInfoProvider
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final SyncReplicationPeerMappingManagerprivate final ReplicationPeers -
Constructor Summary
ConstructorsConstructorDescriptionSyncReplicationPeerInfoProviderImpl(ReplicationPeers replicationPeers, SyncReplicationPeerMappingManager mapping) -
Method Summary
Modifier and TypeMethodDescriptionbooleancheckState(TableName table, BiPredicate<SyncReplicationState, SyncReplicationState> checker) Check whether the given table is contained in a sync replication peer which can pass the state checker.Return the peer id and remote WAL directory if the table is synchronously replicated and the state isSyncReplicationState.ACTIVE.
-
Field Details
-
replicationPeers
-
mapping
-
-
Constructor Details
-
SyncReplicationPeerInfoProviderImpl
SyncReplicationPeerInfoProviderImpl(ReplicationPeers replicationPeers, SyncReplicationPeerMappingManager mapping)
-
-
Method Details
-
getPeerIdAndRemoteWALDir
Description copied from interface:SyncReplicationPeerInfoProviderReturn the peer id and remote WAL directory if the table is synchronously replicated and the state isSyncReplicationState.ACTIVE.- Specified by:
getPeerIdAndRemoteWALDirin interfaceSyncReplicationPeerInfoProvider
-
checkState
public boolean checkState(TableName table, BiPredicate<SyncReplicationState, SyncReplicationState> checker) Description copied from interface:SyncReplicationPeerInfoProviderCheck whether the given table is contained in a sync replication peer which can pass the state checker.Will call the checker with current sync replication state and new sync replication state.
- Specified by:
checkStatein interfaceSyncReplicationPeerInfoProvider
-