public class CacheDrSenderConfiguration extends Object implements Serializable
Modifier and Type | Field and Description |
---|---|
static long |
DFLT_BACKUP_SYNC_FREQUENCY
Default backup partition's DR state synchronization frequency.
|
static long |
DFLT_BATCH_SND_FREQUENCY
Default data center replication sender cache batch send frequency.
|
static int |
DFLT_BATCH_SND_SIZE
Default data center replication sender cache batch send size.
|
static int |
DFLT_MAX_BATCHES
Default data center replication sender cache maximum amount of pending batches.
|
static boolean |
DFLT_PREFER_LOC_SND
Default value of if to prefer the local sender hub (if available) ignoring the load balancing policy.
|
static DrSenderLoadBalancingMode |
DFLT_SND_HUB_LOAD_BALANCING_MODE
Default data center replication sender cache sender hub load balancing mode.
|
static int |
DFLT_STATE_TRANSFER_THREADS_CNT
Default data center replication sender cache amount of worker threads responsible for full state transfer.
|
static long |
DFLT_STATE_TRANSFER_THROTTLE
Default data center replication sender cache state transfer throttle.
|
static int |
DFLT_STATE_TRANSFER_THROTTLE_BYTES
Default data center replication sender cache state transfer throttle bytes.
|
Constructor and Description |
---|
CacheDrSenderConfiguration()
Default constructor.
|
CacheDrSenderConfiguration(CacheDrSenderConfiguration cfg)
Copying constructor.
|
Modifier and Type | Method and Description |
---|---|
long |
getBackupSyncFrequency()
Gets backup part's DR state synchronization frequency.
|
long |
getBatchSendFrequency()
Gets batch send frequency.
|
int |
getBatchSendSize()
Deprecated.
Use
GridGainConfiguration.getBatchSendSizeBytes() instead. |
CacheDrEntryFilter |
getEntryFilter()
Gets entry filter.
|
DrSenderLoadBalancingMode |
getLoadBalancingMode()
Gets sender hub load balancing mode.
|
int |
getMaxBackupQueueSize()
Gets maximum size of backup entries queue.
|
int |
getMaxBatches()
Gets maximum amount of batches awaiting for sender hub acknowledge.
|
String |
getSenderGroup()
Gets sender group name which sender will be used for replication.
|
int |
getStateTransferThreadsCount()
Deprecated.
|
long |
getStateTransferThrottle()
Deprecated.
Use
getStateTransferThrottleBytes() instead. |
int |
getStateTransferThrottleBytes()
Gets state transfer throttle bytes.
|
boolean |
isPreferLocalSender()
Whether to prefer the local sender hub (if available) ignoring the load balancing policy.
|
CacheDrSenderConfiguration |
setBackupSyncFrequency(long backupSyncFreq)
Sets backup part's DR state synchronization frequency.
|
CacheDrSenderConfiguration |
setBatchSendFrequency(long batchSndFreq)
Sets batch send frequency.
|
CacheDrSenderConfiguration |
setBatchSendSize(int batchSndSize)
Deprecated.
Use
GridGainConfiguration.setBatchSendSizeBytes(int) instead. |
CacheDrSenderConfiguration |
setEntryFilter(@Nullable CacheDrEntryFilter entryFilter)
Set entry filter.
|
CacheDrSenderConfiguration |
setLoadBalancingMode(DrSenderLoadBalancingMode loadBalancingMode)
Sets sender hub load balancing mode.
|
CacheDrSenderConfiguration |
setMaxBackupQueueSize(int maxBackupSize)
Sets maximum size of backup entries queue.
|
CacheDrSenderConfiguration |
setMaxBatches(int maxBatches)
Sets maximum amount of batches awaiting for sender hub acknowledge.
|
CacheDrSenderConfiguration |
setPreferLocalSender(boolean preferLocSnd)
Sets whether to prefer the local sender hub.
|
CacheDrSenderConfiguration |
setSenderGroup(String senderGroup)
Sets sender group name which sender will be used for replication.
|
CacheDrSenderConfiguration |
setStateTransferThreadsCount(int stateTransferThreadsCnt)
Deprecated.
|
CacheDrSenderConfiguration |
setStateTransferThrottle(long stateTransferThrottle)
Deprecated.
|
CacheDrSenderConfiguration |
setStateTransferThrottleBytes(int stateTransferThrottleBytes)
Sets state transfer throttle bytes.
|
String |
toString() |
public static final long DFLT_BATCH_SND_FREQUENCY
public static final long DFLT_BACKUP_SYNC_FREQUENCY
public static final int DFLT_BATCH_SND_SIZE
public static final int DFLT_MAX_BATCHES
public static final DrSenderLoadBalancingMode DFLT_SND_HUB_LOAD_BALANCING_MODE
public static final int DFLT_STATE_TRANSFER_THREADS_CNT
public static final long DFLT_STATE_TRANSFER_THROTTLE
public static final int DFLT_STATE_TRANSFER_THROTTLE_BYTES
public static final boolean DFLT_PREFER_LOC_SND
public CacheDrSenderConfiguration()
public CacheDrSenderConfiguration(CacheDrSenderConfiguration cfg)
cfg
- Configuration to copy.@Deprecated public int getBatchSendSize()
GridGainConfiguration.getBatchSendSizeBytes()
instead.getBatchSendFrequency()
batch will be sent to a sender hub.
When set to non-positive value, batch will be sent only in case it's lifetime is greater than
getBatchSendFrequency()
.
Defaults to DFLT_BATCH_SND_SIZE
.
@Deprecated public CacheDrSenderConfiguration setBatchSendSize(int batchSndSize)
GridGainConfiguration.setBatchSendSizeBytes(int)
instead.getBatchSendSize()
for more information.batchSndSize
- Batch send size.this
for chaining.public long getBatchSendFrequency()
getBatchSendSize()
or it's lifetime
is greater than the given value batch will be sent to a sender hub.
When set to non-positive value, batch will be sent only in case it's size is greater than
#getBatchSendSize()
.
Defaults to DFLT_BATCH_SND_FREQUENCY
.
public CacheDrSenderConfiguration setBatchSendFrequency(long batchSndFreq)
getBatchSendFrequency()
for more
information.batchSndFreq
- Batch send frequency.this
for chaining.public long getBackupSyncFrequency()
DFLT_BACKUP_SYNC_FREQUENCY
.public CacheDrSenderConfiguration setBackupSyncFrequency(long backupSyncFreq)
getBackupSyncFrequency()
for more information.backupSyncFreq
- Backup partition's DR state sync frequency.this
for chaining.public int getMaxBatches()
When set to non-positive value, maximum amount of batches is unlimited.
Defaults to DFLT_MAX_BATCHES
.
public CacheDrSenderConfiguration setMaxBatches(int maxBatches)
getMaxBatches()
for more
information.maxBatches
- Maximum amount of batches awaiting for sender hub acknowledge.this
for chaining.public int getMaxBackupQueueSize()
getMaxBatches()
, batch send size batchSndSize
and number of backup nodes
CacheConfiguration.getBackups()
. You may set it's maximum size manually with this method.public CacheDrSenderConfiguration setMaxBackupQueueSize(int maxBackupSize)
getMaxBackupQueueSize()
for more information.maxBackupSize
- Maximum size of backup entries queue.this
for chaining.public CacheDrEntryFilter getEntryFilter()
Defaults to null
.
public CacheDrSenderConfiguration setEntryFilter(@Nullable @Nullable CacheDrEntryFilter entryFilter)
getEntryFilter()
for more information.entryFilter
- Entry filter.this
for chaining.public DrSenderLoadBalancingMode getLoadBalancingMode()
Defaults to DFLT_SND_HUB_LOAD_BALANCING_MODE
.
public CacheDrSenderConfiguration setLoadBalancingMode(DrSenderLoadBalancingMode loadBalancingMode)
getLoadBalancingMode()
for more information.loadBalancingMode
- Sender hub load balancing mode.this
for chaining.@Deprecated public long getStateTransferThrottle()
getStateTransferThrottleBytes()
instead.
When set to 0
throttling is disabled.
Defaults to DFLT_STATE_TRANSFER_THROTTLE
.
@Deprecated public CacheDrSenderConfiguration setStateTransferThrottle(long stateTransferThrottle)
getStateTransferThrottle()
for more information.stateTransferThrottle
- State transfer throttle.this
for chaining.public int getStateTransferThrottleBytes()
When set to 0
throttling is disabled.
Defaults to DFLT_STATE_TRANSFER_THROTTLE_BYTES
.
public CacheDrSenderConfiguration setStateTransferThrottleBytes(int stateTransferThrottleBytes)
getStateTransferThrottleBytes()
for more information.stateTransferThrottleBytes
- State transfer throttle bytes.this
for chaining.@Deprecated public int getStateTransferThreadsCount()
GridGainConfiguration.setDrStateTransferThreadPoolSize(int)
instead.
Defaults to DFLT_STATE_TRANSFER_THREADS_CNT
.
@Deprecated public CacheDrSenderConfiguration setStateTransferThreadsCount(int stateTransferThreadsCnt)
GridGainConfiguration.setDrStateTransferThreadPoolSize(int)
instead.getStateTransferThreadsCount()
for more information.stateTransferThreadsCnt
- State transfer threads count.this
for chaining.public boolean isPreferLocalSender()
Defaults to DFLT_PREFER_LOC_SND
.
True
whether to prefer local sender hub.public CacheDrSenderConfiguration setPreferLocalSender(boolean preferLocSnd)
isPreferLocalSender()
for more information.preferLocSnd
- Whether to prefer the local sender.this
for chaining.public String getSenderGroup()
public CacheDrSenderConfiguration setSenderGroup(String senderGroup)
null
, then default group will be used
DrUtils.DFLT_SENDER_GROUP_NAME
.senderGroup
- Sender group name.this
for chaining.
GridGain In-Memory Computing Platform : ver. 8.9.14 Release Date : November 5 2024