Class DynamoDBStoreConfigurationBuilder
java.lang.Object
org.infinispan.configuration.cache.AbstractPersistenceConfigurationChildBuilder
org.infinispan.configuration.cache.AbstractStoreConfigurationBuilder<DynamoDBStoreConfiguration,DynamoDBStoreConfigurationBuilder>
com.nimbusds.infinispan.persistence.dynamodb.config.DynamoDBStoreConfigurationBuilder
- All Implemented Interfaces:
DynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
,org.infinispan.commons.configuration.Builder<DynamoDBStoreConfiguration>
,org.infinispan.commons.configuration.Self<DynamoDBStoreConfigurationBuilder>
,org.infinispan.configuration.cache.ConfigurationChildBuilder
,org.infinispan.configuration.cache.PersistenceConfigurationChildBuilder
,org.infinispan.configuration.cache.StoreConfigurationBuilder<DynamoDBStoreConfiguration,
,DynamoDBStoreConfigurationBuilder> org.infinispan.configuration.cache.StoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
public class DynamoDBStoreConfigurationBuilder
extends org.infinispan.configuration.cache.AbstractStoreConfigurationBuilder<DynamoDBStoreConfiguration,DynamoDBStoreConfigurationBuilder>
implements DynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
DynamoDB store configuration builder.
Used by the Infinispan ConfigurationBuilder to implement fluent configuration for the DynamoDB CacheLoader / CacheWriter. Methods should use the fluent style, rather than the setter/getter style and should return an instance of this object.
-
Field Summary
Modifier and TypeFieldDescriptionprotected final org.infinispan.configuration.cache.ConfigurationBuilder
Fields inherited from class org.infinispan.configuration.cache.AbstractStoreConfigurationBuilder
async, attributes
-
Constructor Summary
ConstructorDescriptionDynamoDBStoreConfigurationBuilder
(org.infinispan.configuration.cache.PersistenceConfigurationBuilder builder) Creates a new DynamoDB store configuration builder. -
Method Summary
Modifier and TypeMethodDescriptionapplyRangeKey
(String rangeKeyName) Sets the name of the optional range key to apply to all DynamoDB operations.org.infinispan.configuration.cache.Configuration
build()
org.infinispan.configuration.cache.ClusteringConfigurationBuilder
consistentReads
(boolean enable) Sets the consistent read flag.create()
org.infinispan.configuration.cache.CustomInterceptorsConfigurationBuilder
Deprecated.enableContinuousBackups
(boolean enable) Sets the enable continuous backups / point in time recovery.enableStream
(boolean enable) Sets the enable stream flag.enableTTL
(boolean enable) Sets the enable DynamoDB item expiration.org.infinispan.configuration.cache.EncodingConfigurationBuilder
encoding()
Sets the DynamoDB endpoint.org.infinispan.configuration.cache.ExpirationConfigurationBuilder
protected org.infinispan.configuration.cache.ConfigurationBuilder
hmacSHA256Key
(String key) Sets the HMAC SHA-256 key.httpProxyHost
(String host) Sets the HTTP proxy host.httpProxyPort
(int port) Sets the HTTP proxy port.indexedAttributes
(Set<String> indexAttributes) Sets the optional indexed DynamoDB table attributes.org.infinispan.configuration.cache.IndexingConfigurationBuilder
indexing()
org.infinispan.configuration.cache.InvocationBatchingConfigurationBuilder
itemTransformerClass
(Class itemTransformerClass) Sets the class for transforming between Infinispan entries (key / value pair and optional metadata) and a corresponding DynamoDB item.org.infinispan.configuration.cache.LockingConfigurationBuilder
locking()
org.infinispan.configuration.cache.MemoryConfigurationBuilder
memory()
metricRegistry
(com.codahale.metrics.MetricRegistry metricRegistry) Sets an explicit metric registry to use (other than singletonMonitorRegistries
).org.infinispan.configuration.cache.PersistenceConfigurationBuilder
purgeLimit
(long purgeLimit) Sets the limit of expired entries to purge during a run of the expired entry reaper task.purgeMaxReadCapacity
(Capacity purgeReadCapacity) Sets the maximum read capacity to use when scanning a DynamoDB table for expired items.org.infinispan.configuration.cache.QueryConfigurationBuilder
query()
queryExecutorClass
(Class queryExecutorClass) Sets the optional class for executing direct queries against DynamoDB.rangeKeyValue
(String rangeKeyValue) Sets the value of the optional range key.readCapacity
(long readCapacity) Sets the read capacity to provision when creating a new DynamoDB table.region
(com.amazonaws.regions.Regions region) Sets the DynamoDB region.org.infinispan.configuration.cache.SecurityConfigurationBuilder
security()
self()
boolean
org.infinispan.configuration.cache.ConfigurationChildBuilder
simpleCache
(boolean arg0) org.infinispan.configuration.cache.SitesConfigurationBuilder
sites()
org.infinispan.configuration.cache.StatisticsConfigurationBuilder
tablePrefix
(String tablePrefix) Sets the DynamoDB table prefix.tableWithEncryptionAtRest
(boolean encryptionAtRest) Sets the DynamoDB table encryption at rest.org.infinispan.configuration.cache.ConfigurationChildBuilder
template
(boolean arg0) org.infinispan.configuration.cache.TransactionConfigurationBuilder
org.infinispan.configuration.cache.UnsafeConfigurationBuilder
unsafe()
void
validate()
withProperties
(Properties properties) writeCapacity
(long writeCapacity) Sets the write capacity to provision when creating a new DynamoDB table.Methods inherited from class org.infinispan.configuration.cache.AbstractStoreConfigurationBuilder
addProperty, async, attributes, fetchPersistentState, ignoreModifications, maxBatchSize, preload, properties, purgeOnStartup, read, segmented, shared, toString, transactional, validate, validate, writeOnly
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.infinispan.commons.configuration.Builder
read, reset
Methods inherited from interface org.infinispan.configuration.cache.ConfigurationChildBuilder
build, clustering, customInterceptors, encoding, expiration, indexing, invocationBatching, jmxStatistics, locking, memory, query, security, simpleCache, simpleCache, sites, statistics, template, transaction, unsafe, validate
Methods inherited from interface org.infinispan.configuration.cache.PersistenceConfigurationChildBuilder
persistence
Methods inherited from interface org.infinispan.configuration.cache.StoreConfigurationChildBuilder
addProperty, async, fetchPersistentState, ignoreModifications, maxBatchSize, preload, purgeOnStartup, segmented, shared, transactional, writeOnly
-
Field Details
-
builder
protected final org.infinispan.configuration.cache.ConfigurationBuilder builder
-
-
Constructor Details
-
DynamoDBStoreConfigurationBuilder
public DynamoDBStoreConfigurationBuilder(org.infinispan.configuration.cache.PersistenceConfigurationBuilder builder) Creates a new DynamoDB store configuration builder.- Parameters:
builder
- The general persistence configuration builder.
-
-
Method Details
-
create
- Specified by:
create
in interfaceorg.infinispan.commons.configuration.Builder<DynamoDBStoreConfiguration>
-
endpoint
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the DynamoDB endpoint.- Specified by:
endpoint
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
endpoint
- The endpoint,null
if not specified.- Returns:
- The builder.
-
region
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the DynamoDB region.- Specified by:
region
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
region
- The region,null
if not specified.- Returns:
- The builder.
-
itemTransformerClass
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the class for transforming between Infinispan entries (key / value pair and optional metadata) and a corresponding DynamoDB item.- Specified by:
itemTransformerClass
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
itemTransformerClass
- The item transformer class. Must not benull
.- Returns:
- The builder.
-
queryExecutorClass
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the optional class for executing direct queries against DynamoDB. If setDynamoDBStoreConfigurationChildBuilder.indexedAttributes(java.util.Set<java.lang.String>)
must also be specified.- Specified by:
queryExecutorClass
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
queryExecutorClass
- The query executor class,null
if not required.- Returns:
- The builder.
-
indexedAttributes
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the optional indexed DynamoDB table attributes. If setDynamoDBStoreConfigurationChildBuilder.queryExecutorClass(java.lang.Class)
must also be specified.- Specified by:
indexedAttributes
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
indexAttributes
- The indexed attributes,null
if not required.- Returns:
- The builder.
-
consistentReads
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the consistent read flag.- Specified by:
consistentReads
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
enable
-true
for consistent reads,false
for eventually consistent.- Returns:
- The builder.
-
readCapacity
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the read capacity to provision when creating a new DynamoDB table.- Specified by:
readCapacity
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
readCapacity
- The read capacity. Must be equal or larger than one.- Returns:
- The builder.
-
writeCapacity
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the write capacity to provision when creating a new DynamoDB table.- Specified by:
writeCapacity
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
writeCapacity
- The write capacity. Must be equal or larger than one.- Returns:
- The builder.
-
purgeMaxReadCapacity
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the maximum read capacity to use when scanning a DynamoDB table for expired items.- Specified by:
purgeMaxReadCapacity
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
purgeReadCapacity
- The maximum read capacity to use when scanning a DynamoDB table for expired items.- Returns:
- This builder.
-
tableWithEncryptionAtRest
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the DynamoDB table encryption at rest.- Specified by:
tableWithEncryptionAtRest
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
encryptionAtRest
-true
to create the DynamoDB table with encryption at rest,false
with no encryption.- Returns:
- The builder.
-
tablePrefix
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the DynamoDB table prefix.- Specified by:
tablePrefix
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
tablePrefix
- The table prefix,null
if not specified.- Returns:
- The builder.
-
metricRegistry
public DynamoDBStoreConfigurationBuilder metricRegistry(com.codahale.metrics.MetricRegistry metricRegistry) Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets an explicit metric registry to use (other than singletonMonitorRegistries
).- Specified by:
metricRegistry
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
metricRegistry
- The metric registry to use.- Returns:
- The builder.
-
applyRangeKey
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the name of the optional range key to apply to all DynamoDB operations.- Specified by:
applyRangeKey
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
rangeKeyName
- The range key name,null
if not specified.- Returns:
- The builder.
-
rangeKeyValue
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the value of the optional range key.- Specified by:
rangeKeyValue
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
rangeKeyValue
- The range key value,null
if not specified.- Returns:
- The builder.
-
enableStream
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the enable stream flag.- Specified by:
enableStream
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
enable
-true
to enable a stream for a global table,false
for a regular table.- Returns:
- The builder.
-
enableContinuousBackups
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the enable continuous backups / point in time recovery.- Specified by:
enableContinuousBackups
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
enable
-true
to enable continuous backups,false
without.- Returns:
- The builder.
-
enableTTL
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the enable DynamoDB item expiration.- Specified by:
enableTTL
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
enable
-true
to enable item expiration,false
without.- Returns:
- The builder.
-
purgeLimit
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the limit of expired entries to purge during a run of the expired entry reaper task.- Specified by:
purgeLimit
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
purgeLimit
- The purge limit, -1 for no limit.- Returns:
- The builder.
-
httpProxyHost
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the HTTP proxy host.- Specified by:
httpProxyHost
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
host
- The host,null
if none.- Returns:
- The builder.
-
httpProxyPort
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the HTTP proxy port.- Specified by:
httpProxyPort
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
port
- The port, -1 if none.- Returns:
- The builder.
-
hmacSHA256Key
Description copied from interface:DynamoDBStoreConfigurationChildBuilder
Sets the HMAC SHA-256 key.- Specified by:
hmacSHA256Key
in interfaceDynamoDBStoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Parameters:
key
- The HMAC SHA-256 key,null
if none.- Returns:
- The builder.
-
withProperties
- Specified by:
withProperties
in interfaceorg.infinispan.configuration.cache.StoreConfigurationChildBuilder<DynamoDBStoreConfigurationBuilder>
- Overrides:
withProperties
in classorg.infinispan.configuration.cache.AbstractStoreConfigurationBuilder<DynamoDBStoreConfiguration,
DynamoDBStoreConfigurationBuilder>
-
validate
- Specified by:
validate
in interfaceorg.infinispan.commons.configuration.Builder<DynamoDBStoreConfiguration>
- Overrides:
validate
in classorg.infinispan.configuration.cache.AbstractStoreConfigurationBuilder<DynamoDBStoreConfiguration,
DynamoDBStoreConfigurationBuilder>
-
self
- Specified by:
self
in interfaceorg.infinispan.commons.configuration.Self<DynamoDBStoreConfigurationBuilder>
-
template
public org.infinispan.configuration.cache.ConfigurationChildBuilder template(boolean arg0) - Specified by:
template
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
simpleCache
public org.infinispan.configuration.cache.ConfigurationChildBuilder simpleCache(boolean arg0) - Specified by:
simpleCache
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
simpleCache
public boolean simpleCache()- Specified by:
simpleCache
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
clustering
public org.infinispan.configuration.cache.ClusteringConfigurationBuilder clustering()- Specified by:
clustering
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
customInterceptors
@Deprecated public org.infinispan.configuration.cache.CustomInterceptorsConfigurationBuilder customInterceptors()Deprecated.- Specified by:
customInterceptors
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
encoding
public org.infinispan.configuration.cache.EncodingConfigurationBuilder encoding()- Specified by:
encoding
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
expiration
public org.infinispan.configuration.cache.ExpirationConfigurationBuilder expiration()- Specified by:
expiration
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
query
public org.infinispan.configuration.cache.QueryConfigurationBuilder query()- Specified by:
query
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
indexing
public org.infinispan.configuration.cache.IndexingConfigurationBuilder indexing()- Specified by:
indexing
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
invocationBatching
public org.infinispan.configuration.cache.InvocationBatchingConfigurationBuilder invocationBatching()- Specified by:
invocationBatching
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
statistics
public org.infinispan.configuration.cache.StatisticsConfigurationBuilder statistics()- Specified by:
statistics
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
persistence
public org.infinispan.configuration.cache.PersistenceConfigurationBuilder persistence()- Specified by:
persistence
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
locking
public org.infinispan.configuration.cache.LockingConfigurationBuilder locking()- Specified by:
locking
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
security
public org.infinispan.configuration.cache.SecurityConfigurationBuilder security()- Specified by:
security
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
transaction
public org.infinispan.configuration.cache.TransactionConfigurationBuilder transaction()- Specified by:
transaction
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
unsafe
public org.infinispan.configuration.cache.UnsafeConfigurationBuilder unsafe()- Specified by:
unsafe
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
sites
public org.infinispan.configuration.cache.SitesConfigurationBuilder sites()- Specified by:
sites
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
memory
public org.infinispan.configuration.cache.MemoryConfigurationBuilder memory()- Specified by:
memory
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-
getBuilder
protected org.infinispan.configuration.cache.ConfigurationBuilder getBuilder() -
build
public org.infinispan.configuration.cache.Configuration build()- Specified by:
build
in interfaceorg.infinispan.configuration.cache.ConfigurationChildBuilder
-