public static final class WriteBehindConfigurationBuilder.BatchedWriteBehindConfigurationBuilder extends WriteBehindConfigurationBuilder
WriteBehindConfigurationBuilder
for WriteBehindConfiguration
s that supports batchingWriteBehindConfigurationBuilder.BatchedWriteBehindConfigurationBuilder, WriteBehindConfigurationBuilder.UnBatchedWriteBehindConfigurationBuilder
concurrency, queueSize, threadPoolAlias
newBatchedWriteBehindConfiguration, newUnBatchedWriteBehindConfiguration
public WriteBehindConfigurationBuilder.BatchedWriteBehindConfigurationBuilder enableCoalescing()
disableCoalescing()
public WriteBehindConfigurationBuilder.BatchedWriteBehindConfigurationBuilder disableCoalescing()
enableCoalescing()
public WriteBehindConfigurationBuilder.BatchedWriteBehindConfigurationBuilder batchSize(int batchSize)
batchSize
- the new batch sizepublic WriteBehindConfigurationBuilder.BatchedWriteBehindConfigurationBuilder maxWriteDelay(long maxDelay, java.util.concurrent.TimeUnit maxDelayUnit)
maxDelay
- the max delay amountmaxDelayUnit
- the max delay unitpublic WriteBehindConfigurationBuilder.BatchedWriteBehindConfigurationBuilder queueSize(int size)
Default queue size is Integer.MAX_VALUE
.
queueSize
in class WriteBehindConfigurationBuilder
size
- the new queue sizepublic WriteBehindConfigurationBuilder.BatchedWriteBehindConfigurationBuilder concurrencyLevel(int concurrency)
Default concurrency is 1
.
concurrencyLevel
in class WriteBehindConfigurationBuilder
concurrency
- the concurrency levelpublic WriteBehindConfigurationBuilder.BatchedWriteBehindConfigurationBuilder useThreadPool(java.lang.String alias)
useThreadPool
in class WriteBehindConfigurationBuilder
alias
- the thread pool aliasPooledExecutionServiceConfigurationBuilder
public WriteBehindConfiguration<?> build()
WriteBehindConfiguration