@org.springframework.boot.autoconfigure.AutoConfiguration
@org.springframework.boot.autoconfigure.condition.ConditionalOnBooleanProperty(name: grails.cache.enabled, matchIfMissing: true)
@org.springframework.boot.autoconfigure.condition.ConditionalOnBean(value: CachePluginConfiguration)
@groovy.transform.CompileStatic
class GrailsCacheAutoConfiguration
extends java.lang.Object
Auto-configures the cache plugin's default cache manager and key generator. Registered here
rather than by the plugin descriptor so that a bean contributed by the application or another
plugin — for example a cache-provider plugin's grailsCacheManager — makes the default
back off cleanly instead of triggering a bean-definition override.
Gated on the CachePluginConfiguration definition contributed by the cache plugin
descriptor's registrar (which runs before auto-configuration conditions are evaluated), so the
auto-configuration backs off entirely when the plugin is not active — e.g. the jar is on the
classpath but the plugin is excluded — keeping it in lockstep with the descriptor.
- Since:
- 8.0