Class CouchbaseCacheManager
java.lang.Object
org.springframework.cache.support.AbstractCacheManager
org.springframework.cache.transaction.AbstractTransactionSupportingCacheManager
org.springframework.data.couchbase.cache.CouchbaseCacheManager
- All Implemented Interfaces:
InitializingBean
,CacheManager
-
Nested Class Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuilder
(CouchbaseCacheWriter cacheWriter) Entry point for builder styleCouchbaseCacheManager
configuration.builder
(CouchbaseClientFactory clientFactory) Entry point for builder styleCouchbaseCacheManager
configuration.static CouchbaseCacheManager
create
(CouchbaseClientFactory clientFactory) Create a newCouchbaseCacheManager
with defaults applied.protected CouchbaseCache
createCouchbaseCache
(String name, CouchbaseCacheConfiguration cacheConfig) Configuration hook for creatingCouchbaseCache
with given name andcacheConfig
.protected CouchbaseCache
getMissingCache
(String name) protected Collection<? extends Cache>
Methods inherited from class org.springframework.cache.transaction.AbstractTransactionSupportingCacheManager
decorateCache, isTransactionAware, setTransactionAware
Methods inherited from class org.springframework.cache.support.AbstractCacheManager
afterPropertiesSet, getCache, getCacheNames, initializeCaches, lookupCache
-
Method Details
-
create
Create a newCouchbaseCacheManager
with defaults applied.- Parameters:
clientFactory
- must not be null.- Returns:
- new instance of
CouchbaseCacheManager
.
-
builder
public static CouchbaseCacheManager.CouchbaseCacheManagerBuilder builder(CouchbaseClientFactory clientFactory) Entry point for builder styleCouchbaseCacheManager
configuration.- Parameters:
clientFactory
- must not be null.- Returns:
- new
CouchbaseCacheManager.CouchbaseCacheManagerBuilder
.
-
builder
public static CouchbaseCacheManager.CouchbaseCacheManagerBuilder builder(CouchbaseCacheWriter cacheWriter) Entry point for builder styleCouchbaseCacheManager
configuration.- Parameters:
cacheWriter
- must not be null.- Returns:
- new
CouchbaseCacheManager.CouchbaseCacheManagerBuilder
.
-
loadCaches
- Specified by:
loadCaches
in classAbstractCacheManager
-
getMissingCache
- Overrides:
getMissingCache
in classAbstractCacheManager
-
createCouchbaseCache
protected CouchbaseCache createCouchbaseCache(String name, @Nullable CouchbaseCacheConfiguration cacheConfig) Configuration hook for creatingCouchbaseCache
with given name andcacheConfig
.- Parameters:
name
- must not be null.cacheConfig
- can be null.- Returns:
- never null.
-