public class EnterpriseWanReplicationService extends Object implements com.hazelcast.wan.WanReplicationService, com.hazelcast.spi.FragmentedMigrationAwareService, com.hazelcast.spi.PostJoinAwareService, com.hazelcast.spi.LiveOperationsTracker
| Constructor and Description |
|---|
EnterpriseWanReplicationService(com.hazelcast.instance.Node node) |
| Modifier and Type | Method and Description |
|---|---|
void |
addWanReplicationConfig(com.hazelcast.config.WanReplicationConfig wanConfig) |
boolean |
addWanReplicationConfigIfAbsent(com.hazelcast.config.WanReplicationConfig wanConfig) |
void |
beforeMigration(com.hazelcast.spi.PartitionMigrationEvent event) |
void |
checkWanReplicationQueues(String name) |
void |
clearQueues(String wanReplicationName,
String targetGroupName) |
void |
commitMigration(com.hazelcast.spi.PartitionMigrationEvent event) |
Collection<com.hazelcast.spi.ServiceNamespace> |
getAllServiceNamespaces(com.hazelcast.spi.PartitionReplicationEvent event) |
WanReplicationEndpoint |
getEndpoint(String wanReplicationName,
String groupName)
Returns a WAN replication configured under a WAN replication config with
the name
wanReplicationName and with a group name of
target. |
com.hazelcast.spi.Operation |
getPostJoinOperation() |
com.hazelcast.wan.impl.WanEventCounter |
getReceivedEventCounter(String serviceName) |
com.hazelcast.wan.impl.WanEventCounter |
getSentEventCounter(String serviceName) |
Map<String,com.hazelcast.monitor.LocalWanStats> |
getStats()
Returns map from WAN replication config name to
LocalWanStats. |
WanSyncManager |
getSyncManager() |
com.hazelcast.wan.WanReplicationPublisher |
getWanReplicationPublisher(String name) |
com.hazelcast.monitor.WanSyncState |
getWanSyncState() |
void |
handleEvent(com.hazelcast.nio.serialization.Data data,
WanOperation wanOperation)
Processes the replication event sent from the source cluster.
|
void |
handleEvent(com.hazelcast.wan.WanReplicationEvent event) |
void |
initializeCustomConsumers()
Construct and initialize all WAN consumers by fetching the class names or implementations from the config and store them
under the WAN replication config name in
wanConsumers. |
boolean |
isKnownServiceNamespace(com.hazelcast.spi.ServiceNamespace namespace) |
void |
pause(String name,
String targetGroupName) |
void |
populate(com.hazelcast.spi.LiveOperations liveOperations) |
void |
populateSyncEventOnMembers(String wanReplicationName,
String targetGroupName,
WanSyncEvent syncEvent) |
com.hazelcast.spi.Operation |
prepareReplicationOperation(com.hazelcast.spi.PartitionReplicationEvent event) |
com.hazelcast.spi.Operation |
prepareReplicationOperation(com.hazelcast.spi.PartitionReplicationEvent event,
Collection<com.hazelcast.spi.ServiceNamespace> namespaces) |
void |
publishSyncEvent(String wanReplicationName,
String targetGroupName,
WanSyncEvent syncEvent) |
void |
removeWanEventCounters(String serviceName,
String dataStructureName) |
void |
resume(String name,
String targetGroupName) |
void |
rollbackMigration(com.hazelcast.spi.PartitionMigrationEvent event) |
void |
shutdown() |
void |
syncAllMaps(String wanReplicationName,
String targetGroupName) |
void |
syncMap(String wanReplicationName,
String targetGroupName,
String mapName) |
public EnterpriseWanReplicationService(com.hazelcast.instance.Node node)
public void initializeCustomConsumers()
wanConsumers.public void beforeMigration(com.hazelcast.spi.PartitionMigrationEvent event)
beforeMigration in interface com.hazelcast.spi.MigrationAwareServicepublic void commitMigration(com.hazelcast.spi.PartitionMigrationEvent event)
commitMigration in interface com.hazelcast.spi.MigrationAwareServicepublic void rollbackMigration(com.hazelcast.spi.PartitionMigrationEvent event)
rollbackMigration in interface com.hazelcast.spi.MigrationAwareServicepublic com.hazelcast.wan.WanReplicationPublisher getWanReplicationPublisher(String name)
getWanReplicationPublisher in interface com.hazelcast.wan.WanReplicationServicepublic WanReplicationEndpoint getEndpoint(String wanReplicationName, String groupName)
wanReplicationName and with a group name of
target.wanReplicationName - the name of the WanReplicationConfiggroupName - the group name of the publishercom.hazelcast.config.InvalidConfigurationException - if there is no replication config
with the name wanReplicationName
and group name groupNameWanReplicationConfig.getName(),
WanPublisherConfig.getGroupName()public void handleEvent(com.hazelcast.nio.serialization.Data data,
WanOperation wanOperation)
data - the serialized event, can be of type WanReplicationEvent or BatchWanReplicationEventwanOperation - the operation sent by the source clusterpublic void handleEvent(com.hazelcast.wan.WanReplicationEvent event)
public Map<String,com.hazelcast.monitor.LocalWanStats> getStats()
LocalWanStats.getStats in interface com.hazelcast.spi.StatisticsAwareService<com.hazelcast.monitor.LocalWanStats>public com.hazelcast.monitor.WanSyncState getWanSyncState()
getWanSyncState in interface com.hazelcast.wan.WanReplicationServicepublic com.hazelcast.wan.impl.WanEventCounter getReceivedEventCounter(String serviceName)
getReceivedEventCounter in interface com.hazelcast.wan.WanReplicationServicepublic com.hazelcast.wan.impl.WanEventCounter getSentEventCounter(String serviceName)
getSentEventCounter in interface com.hazelcast.wan.WanReplicationServicepublic void removeWanEventCounters(String serviceName, String dataStructureName)
removeWanEventCounters in interface com.hazelcast.wan.WanReplicationServicepublic com.hazelcast.spi.Operation getPostJoinOperation()
getPostJoinOperation in interface com.hazelcast.spi.PostJoinAwareServicepublic void populate(com.hazelcast.spi.LiveOperations liveOperations)
populate in interface com.hazelcast.spi.LiveOperationsTrackerpublic Collection<com.hazelcast.spi.ServiceNamespace> getAllServiceNamespaces(com.hazelcast.spi.PartitionReplicationEvent event)
getAllServiceNamespaces in interface com.hazelcast.spi.FragmentedMigrationAwareServicepublic boolean isKnownServiceNamespace(com.hazelcast.spi.ServiceNamespace namespace)
isKnownServiceNamespace in interface com.hazelcast.spi.FragmentedMigrationAwareServicepublic com.hazelcast.spi.Operation prepareReplicationOperation(com.hazelcast.spi.PartitionReplicationEvent event,
Collection<com.hazelcast.spi.ServiceNamespace> namespaces)
prepareReplicationOperation in interface com.hazelcast.spi.FragmentedMigrationAwareServicepublic com.hazelcast.spi.Operation prepareReplicationOperation(com.hazelcast.spi.PartitionReplicationEvent event)
prepareReplicationOperation in interface com.hazelcast.spi.MigrationAwareServicepublic void shutdown()
shutdown in interface com.hazelcast.wan.WanReplicationServicepublic void pause(String name, String targetGroupName)
pause in interface com.hazelcast.wan.WanReplicationServicepublic void resume(String name, String targetGroupName)
resume in interface com.hazelcast.wan.WanReplicationServicepublic void checkWanReplicationQueues(String name)
checkWanReplicationQueues in interface com.hazelcast.wan.WanReplicationServicepublic void syncMap(String wanReplicationName, String targetGroupName, String mapName)
syncMap in interface com.hazelcast.wan.WanReplicationServicepublic void syncAllMaps(String wanReplicationName, String targetGroupName)
syncAllMaps in interface com.hazelcast.wan.WanReplicationServicepublic void clearQueues(String wanReplicationName, String targetGroupName)
clearQueues in interface com.hazelcast.wan.WanReplicationServicepublic void addWanReplicationConfig(com.hazelcast.config.WanReplicationConfig wanConfig)
addWanReplicationConfig in interface com.hazelcast.wan.WanReplicationServicepublic boolean addWanReplicationConfigIfAbsent(com.hazelcast.config.WanReplicationConfig wanConfig)
public void publishSyncEvent(String wanReplicationName, String targetGroupName, WanSyncEvent syncEvent)
public void populateSyncEventOnMembers(String wanReplicationName, String targetGroupName, WanSyncEvent syncEvent)
public WanSyncManager getSyncManager()
Copyright © 2020 Hazelcast, Inc.. All Rights Reserved.