Package io.micronaut.cache.annotation
Annotation Interface CacheConfig
@Target({TYPE,ANNOTATION_TYPE})
@Retention(RUNTIME)
@Documented
@Inherited
public @interface CacheConfig
An annotation that can be used on either a type or an annotation stereotype to configure common caching behaviour.
- Since:
 - 1.0
 - Author:
 - Graeme Rocher
 
- 
Optional Element Summary
Optional ElementsModifier and TypeOptional ElementDescriptionString[]Specifies one or many cache names to store cache operation values in.Class<? extends CacheKeyGenerator>String[] 
- 
Element Details
- 
value
- Returns:
 - Same as 
cacheNames() 
- Default:
 - {}
 
 - 
cacheNames
String[] cacheNamesSpecifies one or many cache names to store cache operation values in. If specified at the type level, can be overridden at the method level.- Returns:
 - The names of the caches to to store values in
 
- Default:
 - {}
 
 - 
keyGenerator
Class<? extends CacheKeyGenerator> keyGenerator- Returns:
 - The default bean type of the key generator
 
- Default:
 - io.micronaut.cache.interceptor.DefaultCacheKeyGenerator.class
 
 
 -