public class CacheDrSenderConfiguration extends Object implements Serializable
| Modifier and Type | Field and Description |
|---|---|
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 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.
|
| Constructor and Description |
|---|
CacheDrSenderConfiguration()
Default constructor.
|
CacheDrSenderConfiguration(CacheDrSenderConfiguration cfg)
Copying constructor.
|
| Modifier and Type | Method and Description |
|---|---|
long |
getBatchSendFrequency()
Gets batch send frequency.
|
int |
getBatchSendSize()
Gets batch send size.
|
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.
|
int |
getStateTransferThreadsCount()
Gets state transfer threads count.
|
long |
getStateTransferThrottle()
Gets state transfer throttle.
|
boolean |
isPreferLocalSender()
Whether to prefer the local sender hub (if available) ignoring the load balancing policy.
|
void |
setBatchSendFrequency(long batchSndFreq)
Sets batch send frequency.
|
void |
setBatchSendSize(int batchSndSize)
Sets batch send size.
|
void |
setEntryFilter(CacheDrEntryFilter entryFilter)
Set entry filter.
|
void |
setLoadBalancingMode(DrSenderLoadBalancingMode loadBalancingMode)
Sets sender hub load balancing mode.
|
void |
setMaxBackupQueueSize(int maxBackupSize)
Sets maximum size of backup entries queue.
|
void |
setMaxBatches(int maxBatches)
Sets maximum amount of batches awaiting for sender hub acknowledge.
|
void |
setPreferLocalSender(boolean preferLocSnd)
Sets whether to prefer the local sender hub.
|
void |
setStateTransferThreadsCount(int stateTransferThreadsCnt)
Sets state transfer threads count.
|
void |
setStateTransferThrottle(long stateTransferThrottle)
Sets state transfer throttle.
|
String |
toString() |
public static final long DFLT_BATCH_SND_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 CacheDrSenderConfiguration()
public CacheDrSenderConfiguration(CacheDrSenderConfiguration cfg)
cfg - Configuration to copy.public int getBatchSendSize()
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.
public void setBatchSendSize(int batchSndSize)
getBatchSendSize() for more information.batchSndSize - Batch send size.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 void setBatchSendFrequency(long batchSndFreq)
getBatchSendFrequency() for more
information.batchSndFreq - Batch send frequency.public int getMaxBatches()
When set to non-positive value, maximum amount of batches is unlimited.
Defaults to DFLT_MAX_BATCHES.
public void setMaxBatches(int maxBatches)
getMaxBatches() for more
information.maxBatches - Maximum amount of batches awaiting for sender hub acknowledge.public int getMaxBackupQueueSize()
getMaxBatches(), batch send size batchSndSize and number of backup nodes
CacheConfiguration.backups. You may set it's maximum size manually with this method.public void setMaxBackupQueueSize(int maxBackupSize)
getMaxBackupQueueSize() for more information.maxBackupSize - Maximum size of backup entries queue.public CacheDrEntryFilter getEntryFilter()
Defaults to null.
public void setEntryFilter(@Nullable
CacheDrEntryFilter entryFilter)
getEntryFilter() for more information.entryFilter - Entry filter.public DrSenderLoadBalancingMode getLoadBalancingMode()
Defaults to DFLT_SND_HUB_LOAD_BALANCING_MODE.
public void setLoadBalancingMode(DrSenderLoadBalancingMode loadBalancingMode)
getLoadBalancingMode() for more information.loadBalancingMode - Sender hub load balancing mode.public long getStateTransferThrottle()
When set to 0 throttling is disabled.
Defaults to DFLT_STATE_TRANSFER_THROTTLE.
public void setStateTransferThrottle(long stateTransferThrottle)
getStateTransferThrottle() for more information.stateTransferThrottle - State transfer throttle.public int getStateTransferThreadsCount()
Defaults to DFLT_STATE_TRANSFER_THREADS_CNT.
public void setStateTransferThreadsCount(int stateTransferThreadsCnt)
getStateTransferThreadsCount() for more information.stateTransferThreadsCnt - State transfer threads count.public boolean isPreferLocalSender()
Defaults to DFLT_PREFER_LOC_SND.
True whether to prefer local sender hub.public void setPreferLocalSender(boolean preferLocSnd)
isPreferLocalSender() for more information.preferLocSnd - Whether to prefer the local sender.
GridGain Fabric : ver. 7.8.12 Release Date : October 2 2017