Wraps Spring Boot's caching abstraction with support for Caffeine, Redis, and EhCache. You get a six-step workflow covering dependencies, @EnableCaching setup, method annotations (@Cacheable, @CachePut, @CacheEvict), TTL configuration, SpEL key expressions, and Actuator metrics validation. Includes guard clauses for conditional caching and examples of common eviction patterns. The troubleshooting section correctly calls out the proxy gotcha where self-invocation bypasses the cache, which trips up a lot of people. References include curated Spring docs excerpts and end-to-end test examples. Best used when you need to add caching to service methods and want concrete patterns instead of reading the full Spring documentation.

skills.sh installs
4K
GitHub stars
369
last updated
Aug 21, 2026

Install

$ npx -y skills add giuseppe-trisciuoglio/developer-kit --skill spring-boot-cache --agent claude-code

Installs into .claude/skills of the current project.

Files

Spring Boot Cache Abstraction

Overview

6-step workflow for enabling cache abstraction, configuring providers (Caffeine, Redis, Ehcache), annotating service methods, and validating behavior in Spring Boot 3.5+ applications. Apply @Cacheable for reads, @CachePut for writes, @CacheEvict for deletions. Configure TTL/eviction policies and expose metrics via Actuator.

When to Use

  • Add @Cacheable, @CachePut, or @CacheEvict to service methods.
  • Configure Caffeine, Redis, or Ehcache with TTL and capacity policies.
  • Implement eviction strategies for stale data.
  • Diagnose cache misses or invalidation issues.
  • Expose hit/miss metrics via Actuator or Micrometer.

Instructions

  1. Add dependencies — spring-boot-starter-cache plus a provider:

    • Caffeine: caffeine starter
    • Redis: spring-boot-starter-data-redis
    • Ehcache: ehcache starter
  2. Enable caching — annotate a @Configuration class with @EnableCaching and define a CacheManager bean.

  3. Annotate methods — @Cacheable for reads, @CachePut for writes, @CacheEvict for deletions.

Sponsors

Details

Repository
github.com/giuseppe-trisciuoglio/developer-kit
Categories
Backend & APIs, Java & JVM, Databases
First seen
May 16, 2026

More from giuseppe-trisciuoglio/developer-kit

All 102
1analogjs avatarangular-ssranalogjs/angular-skillsImplement server-side rendering and hydration in Angular v20+ using @angular/ssr. Use for SSR setup, hydration strategies, prerendering static pages, and handli3.9Kskills.sh installs
2yaklang avatarrecon-for-secyaklang/hack-skillsEntry P1 category router for reconnaissance and methodology. Use when mapping scope, discovering assets, fingerprinting technology, building endpoint inventory,3.9Kskills.sh installs
3mantinedev avatarmantine-custom-componentsmantinedev/skillsBuild custom components that integrate with Mantine's theming, Styles API, and core features. Use this skill when: (1) creating a new component using factory(),3.9Kskills.sh installs
4jackwener avataropencli-oneshotjackwener/opencliUse when quickly generating a single OpenCLI command from a specific URL and goal description. 4-step process — open page, capture API, write TS adapter, test. 3.9Kskills.sh installs
5dotnet avatarmaui-safe-areadotnet/skills.NET MAUI safe area and edge-to-edge layout guidance for .NET 10+. Covers the new SafeAreaEdges property, SafeAreaRegions enum, per-edge control, keyboard avoid3.9Kskills.sh installs
6dpearson2699 avatarspeech-recognitiondpearson2699/swift-ios-skillsTranscribe speech to text using Apple's Speech framework. Use when implementing live microphone transcription with AVAudioEngine, recognizing recorded audio fil3.8Kskills.sh installs