Interface IReplicationSourceGroup

All Known Implementing Classes:
AbstractReplicationSourceGroup, AsyncReplicationSourceGroup, ReliableAsyncReplicationSourceGroup, SyncReplicationSourceGroup

public interface IReplicationSourceGroup
A replication source group consists of one or more target members that shares the same data that needs to be replicated, each member is being replicated to using a dedicated IReplicationSourceChannel. Each target member is receiving and processing the replication by a corresponding IReplicationTargetGroup.
Since:
8.0
Author:
eitany
  • Method Details

    • beforeExecute

      void beforeExecute(ReplicationOutContext replicationContext, IEntryHolder entryHolder, ReplicationSingleOperationType operationType)
      Creates a single entry holder operation replication data from the given properties and add it to the provided context
      Parameters:
      replicationContext - context to attach the replication data to
      entryHolder - the entry holder data
      operationType - the operation type
    • beforeExecuteGeneric

      void beforeExecuteGeneric(ReplicationOutContext replicationContext, Object operationData, ReplicationSingleOperationType operationType)
      Create a single type descriptor operation replication data and add it to provided context
    • beforeTransactionExecute

      void beforeTransactionExecute(ReplicationOutContext replicationContext, ServerTransaction transaction, ArrayList<IEntryHolder> lockedEntries, ReplicationMultipleOperationType operationType)
      Creates transaction replication data and adds it to the provided context
    • execute

      int execute(IReplicationGroupOutContext groupContext)
      Executes the replication specified by the provided group context
      Returns:
      true iff the replication ended.
    • execute

      void execute(IReplicationUnreliableOperation operation)
    • close

      void close()
      Close this replication group, once closed it can no longer be used
    • checkChannelConnected

      boolean checkChannelConnected(String sourceMemberLookupName)
      Returns:
      true is an underlying channel to the specified member is connected
    • getChannelEndpointDetails

      ReplicationEndpointDetails getChannelEndpointDetails(String sourceMemberLookupName)
    • beginSynchronizing

      void beginSynchronizing(String synchronizingMemberLookupName, Object synchronizingSourceUniqueId)
      Signal this source group that one of its channel is now used for space synchronization replica
      Parameters:
      synchronizingMemberLookupName - the channel target name that is used for synchronization
    • beginSynchronizing

      void beginSynchronizing(String synchronizingMemberLookupName, Object synchronizingSourceUniqueId, boolean isDirectPersistencySync)
    • synchronizationDataGenerated

      boolean synchronizationDataGenerated(String synchronizingMemberLookupName, String uid)
      During synchronization process, notify the channel specified by the target name, that a sync data was generated in order for it to know to filter older data when replicating to target
    • synchronizationCopyStageDone

      void synchronizationCopyStageDone(String synchronizingMemberLookupName)
      During synchronization process, notify the channel specified by the target name that the copy iteration process is done in order for the filtering mechanism to know that any following packets occurred completely after the synchronization copy stage.
    • stopSynchronization

      void stopSynchronization(String synchronizingMemberLookupName)
      Signal this source group that one of its channel synchronization state is aborted beginSynchronizing(String, Object)
    • getGroupName

      String getGroupName()
      Returns:
      group name
    • getGroupBacklog

      IReplicationGroupBacklog getGroupBacklog()
      Returns:
      underlying group backlog
    • getChannelsStatus

      Map<String,Boolean> getChannelsStatus()
    • monitorConsistencyLevel

      void monitorConsistencyLevel() throws ConsistencyLevelViolationException
      Monitors sla state of the replication group
      Throws:
      ConsistencyLevelViolationException - if the sla is breached
      Since:
      9.5
    • getStatistics

    • setActive

      void setActive(MetricRegistrator metricRegistrator)
    • setPassive

      void setPassive(boolean closeProxy)
      Parameters:
      closeProxy - - whether to close the stub proxy when it has no more references.
    • flushPendingReplication

      boolean flushPendingReplication(long timeout, TimeUnit units)
    • sampleStatistics

      void sampleStatistics()
    • dumpState

      String dumpState()
    • getConfigHolder

    • createTemporaryChannel

      void createTemporaryChannel(String memberName, Object customBacklogMetadata)
      Creates a temporary channel to an existing member of this group, if a channel is already created then this method does nothing This method should be called when there is a need to create a temporary channel from this group to the target group to perform some operation and should not be used for a persistent channel
      Parameters:
      memberName - group member to create the channel to
      Since:
      9.0
    • closeTemporaryChannel

      void closeTemporaryChannel(String sourceMemberName)
      Closes a temporary created channel
      Since:
      9.0
      See Also:
    • registerWith

      void registerWith(MetricRegistrator metricRegister)