Package io.micronaut.cache.caffeine
Class DefaultDynamicCacheManager
java.lang.Object
io.micronaut.cache.caffeine.DefaultDynamicCacheManager
- All Implemented Interfaces:
io.micronaut.cache.DynamicCacheManager<com.github.benmanes.caffeine.cache.Cache>
@Singleton
@Requires(missingBeans=io.micronaut.cache.DynamicCacheManager.class) @Requires(property="micronaut.cache.dynamic",notEquals="false")
public class DefaultDynamicCacheManager
extends Object
implements io.micronaut.cache.DynamicCacheManager<com.github.benmanes.caffeine.cache.Cache>
Default
DynamicCacheManager implementation that creates DefaultSyncCaches with default values.- Since:
- 1.3.0
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultDynamicCacheManager(io.micronaut.context.ApplicationContext applicationContext, io.micronaut.core.convert.ConversionService conversionService, io.micronaut.runtime.ApplicationConfiguration applicationConfiguration) Creates a default dynamic cache manager. -
Method Summary
-
Constructor Details
-
DefaultDynamicCacheManager
public DefaultDynamicCacheManager(io.micronaut.context.ApplicationContext applicationContext, io.micronaut.core.convert.ConversionService conversionService, io.micronaut.runtime.ApplicationConfiguration applicationConfiguration) Creates a default dynamic cache manager.- Parameters:
applicationContext- the application contextconversionService- the conversion serviceapplicationConfiguration- the application configuration
-
-
Method Details
-
getCache
@NonNull public @NonNull io.micronaut.cache.SyncCache<com.github.benmanes.caffeine.cache.Cache> getCache(String name) - Specified by:
getCachein interfaceio.micronaut.cache.DynamicCacheManager<com.github.benmanes.caffeine.cache.Cache>
-