Class CRDTReplicationConfig

java.lang.Object
com.hazelcast.config.CRDTReplicationConfig

public class CRDTReplicationConfig
extends Object
Configures the replication mechanism for all CRDT implementations. The CRDT states are replicated in rounds (the period is configurable) and in each round the state is replicated up to the configured number of members.
  • Field Details

    • DEFAULT_REPLICATION_PERIOD_MILLIS

      public static final int DEFAULT_REPLICATION_PERIOD_MILLIS
      The default period between two CRDT replication rounds.
      See Also:
      Constant Field Values
    • DEFAULT_MAX_CONCURRENT_REPLICATION_TARGETS

      public static final int DEFAULT_MAX_CONCURRENT_REPLICATION_TARGETS
      The default maximum number of members to which the CRDT states are replicated in a single round.
      See Also:
      Constant Field Values
  • Constructor Details

    • CRDTReplicationConfig

      public CRDTReplicationConfig()
  • Method Details

    • getReplicationPeriodMillis

      public int getReplicationPeriodMillis()
      Returns the period between two replications of CRDT states in milliseconds.
    • setReplicationPeriodMillis

      public CRDTReplicationConfig setReplicationPeriodMillis​(int replicationPeriodMillis)
      Sets the period between two replications of CRDT states in milliseconds. A lower value will increase the speed at which changes are disseminated to other cluster members at the expense of burst-like behaviour - less updates will be batched together in one replication message and one update to a CRDT may cause a sudden burst of replication messages in a short time interval. The value must be a positive non-null integer.
      Parameters:
      replicationPeriodMillis - the replication period
      Returns:
      this config
    • getMaxConcurrentReplicationTargets

      public int getMaxConcurrentReplicationTargets()
      Returns the maximum number of target members that we replicate the CRDT states to in one period.
    • setMaxConcurrentReplicationTargets

      public CRDTReplicationConfig setMaxConcurrentReplicationTargets​(int maxConcurrentReplicationTargets)
      Sets the maximum number of target members that we replicate the CRDT states to in one period. A higher count will lead to states being disseminated more rapidly at the expense of burst-like behaviour - one update to a CRDT will lead to a sudden burst in the number of replication messages in a short time interval.
      Parameters:
      maxConcurrentReplicationTargets - the maximum number of replication targets in a replication period
      Returns:
      this config