Loading tutorials
application.properties. It covers the setup that every later caching annotation depends on.2 min read@EnableCaching and spring-boot-starter-cache to your project. Here you will learn how @Cacheable decides when to run your method and when to return a stored result.3 min read@Cacheable and know what a cache name is. It covers how Spring builds the key that identifies each entry, and how to override it.2 min read@Cacheable, and read simple SpEL (Spring Expression Language) expressions such as #id. Not every result deserves a cache entry. Two attributes on @Cacheable let you decide: condition and unless.2 min read@Cacheable, know how SpEL cache keys work, and have caching enabled with @EnableCaching. A cache holds a copy of your data. When the source changes, the copy must change too, or readers see stale values. Spring gives you two annotations for this: `@CacheP3 min read@Cacheable on a service method. You should also have @EnableCaching in place.2 min readapplication.properties. You have already enabled caching with @EnableCaching and used @Cacheable. Here you decide where the cached data actually lives.2 min read@EnableCaching and used @Cacheable. Here you will plug in Caffeine as the cache provider and set its size, expiry, and stati2 min read@Cacheable, @CachePut and @CacheEvict, and that you can run a Redis server locally (for example with Docker). It covers moving the cache from application memory into Redis.2 min read@Cacheable, @CachePut and @CacheEvict, and that you have picked Caffeine or Redis as a provider. Here you will decide how long entries live and what happens when a cache grows too large.2 min read@Cacheable works, how cache keys are built, and how to configure a provider such as Caffeine. It covers what happens when many threads miss the same key at once, and how sync = true addresses it.3 min read@SpringBootTest, you know how @Cacheable, @CachePut and @CacheEvict behave, and you have used Mockito. Cached code needs tests because the annotations change behavior without changing the method body. A wrong key, a missing @EnableCaching or a self-invo2 min read@Cacheable on a service method, and edit application.properties. You also need spring-boot-starter-actuator on the classpath. Here you will learn how to see which caches exist and how well they perform.2 min read@Cacheable, @CachePut and @CacheEvict, and that you know a Spring bean is wrapped in a proxy. It covers the mistakes that most often turn a working cache into a source of wrong answers.2 min read