I'm using Spring Cache abstraction and I have multiple caches defined. Sometimes, when data changes, I want to evict more than one caches.
Is there away to evict multiple cache using Spring's @CacheEvict annotation?
I'm using spring-cache to improve database queries, which works fine as follows:
@Bean
public CacheManager cacheManager() {
return new ConcurrentMapCacheManager("books");
}
@Cacheable("books")
public Book getByIsbn(String isbn) {
return dao.findByIsbn(isbn);
}
But now I want to prepopulate the full book-cache …
I'm looking for 2 things:
How to disable all caching during development with Spring boot "dev" profile. There doesn't seam to be a general setting to turn it all off in application.properties. What's the easiest way?
How to disable caching …
I want to have multiple spring cache managers configured in my web-application and I would be able to use different cache manager at various places in my project. Is there any way to do this.