Class AerospikeCacheManager

All Implemented Interfaces:
InitializingBean, CacheManager

public class AerospikeCacheManager extends AbstractTransactionSupportingCacheManager
CacheManager implementation for Aerospike. By default AerospikeCaches will be lazily initialized for each AbstractCacheManager.getCache(String) request unless a set of predefined cache names is provided.

Setting AbstractTransactionSupportingCacheManager.setTransactionAware(boolean) to true will force Caches to be decorated as TransactionAwareCacheDecorator so values will only be written to the cache after successful commit of surrounding transaction.
Author:
Venil Noronha
  • Constructor Details

    • AerospikeCacheManager

      public AerospikeCacheManager(com.aerospike.client.IAerospikeClient aerospikeClient, AerospikeConverter aerospikeConverter, AerospikeCacheConfiguration defaultCacheConfiguration)
      Create a new AerospikeCacheManager instance - Specifying a default cache configuration.
      Parameters:
      aerospikeClient - the instance that implements IAerospikeClient.
      aerospikeConverter - the instance that implements AerospikeConverter.
      defaultCacheConfiguration - the default cache configuration.
    • AerospikeCacheManager

      public AerospikeCacheManager(com.aerospike.client.IAerospikeClient aerospikeClient, AerospikeConverter aerospikeConverter, AerospikeCacheConfiguration defaultCacheConfiguration, Map<String,AerospikeCacheConfiguration> initialPerCacheConfiguration)
      Create a new AerospikeCacheManager instance - Specifying a default cache configuration and a map of caches (cache names) and matching configurations.
      Parameters:
      aerospikeClient - the instance that implements IAerospikeClient.
      aerospikeConverter - the instance that implements AerospikeConverter.
      defaultCacheConfiguration - the default aerospike cache configuration.
      initialPerCacheConfiguration - a map of caches (cache names) and matching configurations.