Provides patterns to implement persistence layers with Spring Data JPA.

MITAuto-check: notesDevelopment

Install Spring Data Jpa

skills CLI
$ npx skills add giuseppe-trisciuoglio/developer-kit --skill spring-data-jpa -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install giuseppe-trisciuoglio/developer-kit spring-data-jpa --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/giuseppe-trisciuoglio/developer-kit.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/developer-kit-java/skills/spring-data-jpa .claude/skills/spring-data-jpa && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
spring-data-jpa
GitHub stars
357
Token cost
~1.5k tokens
SKILL.md length
444 words
Files
3 (incl. references)
Skills in repo
115
Repo updated
First seen
Licence
MIT

At a glance

Provides patterns to implement persistence layers with Spring Data JPA.

  • Works in 3 steps: Extend the appropriate repository… → Use derived queries for simple conditions → Implement custom queries with @Query
  • Creating repositories
  • SKILL.md covers Overview, When to Use, Instructions and Examples, plus 2 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Spring Data Jpa is an agent skill from giuseppe-trisciuoglio/developer-kit. Provides patterns to implement persistence layers with Spring Data JPA. Use when creating repositories, configuring entity relationships, writing queries (derived and @Query), setting up pagination, database auditing, transactions, UUID primary keys, multiple databases, and database indexing.

Its SKILL.md is about 1.5k tokens, which your agent loads only when the skill is triggered. The skill folder holds 3 other files, including reference files (for example `references/examples.md` and `references/reference.md`).

It sits in Development, covering Diagrams. The repository describes itself as: Modular plugin marketplace for Claude Code and agentic CLIs, with validated, spec-driven skills, agents, commands, and workflows for Java, TypeScript, Python, PHP, AWS, and AI. The licence is MIT.

When your agent uses it

  • Creating repositories
  • Configuring entity relationships
  • Writing queries (derived and @Query)
  • Setting up pagination

Example prompts

  • “Use the spring-data-jpa skill to provide patterns to implement persistence layers with Spring Data JPA”
  • “/spring-data-jpa”

Requirements

  • Pre-approved tools (allowed-tools): Read, Write, Edit, Bash, Glob, Grep

Workflow steps

3 steps, taken from the first numbered list in SKILL.md.

  1. Extend the appropriate repository interface
  2. Use derived queries for simple conditions
  3. Implement custom queries with @Query

What it can do on your machine

Read from SKILL.md and the folder at commit fe73fb3. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Read
    • Write
    • Edit
    • Bash
    • Glob
    • Grep

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are java).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Spring Data Jpa loads about 1.5k tokens when it runs, and up to ~31k if it reads all its reference files. Until then it costs about 78 tokens; SKILL.md has 444 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~78
When it runs · the whole SKILL.md, loaded when a task matches
~1.5k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~31k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check: notes

The automated check noted patterns worth knowing about, such as sudo or a known installer.

  • NotePre-approves every shell command (allowed-tools: Bash)SKILL.md
    allowed-tools: Read, Write, Edit, Bash, Glob, Grep

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from giuseppe-trisciuoglio/developer-kit at commit fe73fb3, republished under its MIT licence (© giuseppe-trisciuoglio). 444 words, ~1,513 tokens.

Download SKILL.mdSave it as .claude/skills/spring-data-jpa/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.
name
spring-data-jpa
description
Provides patterns to implement persistence layers with Spring Data JPA. Use when creating repositories, configuring entity relationships, writing queries (derived and `@Query`), setting up pagination, database auditing, transactions, UUID primary keys, multiple databases, and database indexing.
allowed-tools
Read, Write, Edit, Bash, Glob, Grep

Spring Data JPA

Overview

Provides patterns for Spring Data JPA repositories, entity relationships, queries, pagination, auditing, and transactions.

When to Use

Creating repositories with CRUD operations, entity relationships, @Query annotations, pagination, auditing, or UUID primary keys.

Instructions

Create Repository Interfaces

To implement a repository interface:

  1. Extend the appropriate repository interface:

    java
    @Repository
    public interface UserRepository extends JpaRepository<User, Long> {
        // Custom methods defined here
    }
  2. Use derived queries for simple conditions:

    java
    Optional<User> findByEmail(String email);
    List<User> findByStatusOrderByCreatedDateDesc(String status);
  3. Implement custom queries with @Query:

    java
    @Query("SELECT u FROM User u WHERE u.status = :status")
    List<User> findActiveUsers(@Param("status") String status);
Configure Entities
  1. Define entities with proper annotations:

    java
    @Entity
    @Table(name = "users")
    public class User {
        @Id
        @GeneratedValue(strategy = GenerationType.IDENTITY)
        private Long id;
    
        @Column(nullable = false, length = 100)
        private String email;
    }
  2. Configure relationships using appropriate cascade types:

    java
    @OneToMany(mappedBy = "user", cascade = CascadeType.ALL, orphanRemoval = true)
    private List<Order> orders = new ArrayList<>();

    Validation: Test cascade behavior with a small dataset before applying to production data. Verify delete operations don't cascade unexpectedly.

  3. Set up database auditing:

    java
    @CreatedDate
    @Column(nullable = false, updatable = false)
    private LocalDateTime createdDate;
Apply Query Patterns
  1. Use derived queries for simple conditions
  2. Use @Query for complex queries
  3. Return Optional<T> for single results
  4. Use Pageable for pagination
  5. Apply @Modifying for update/delete operations
Manage Transactions
  1. Mark read-only operations with @Transactional(readOnly = true)
  2. Use explicit transaction boundaries for modifying operations
  3. Specify rollback conditions when needed
Validate and Optimize

1. Verify entity configuration:

  • Test cascade behavior in a transaction before production deployment
  • Validate bidirectional relationships sync correctly

2. Optimize query performance:

  • Run EXPLAIN ANALYZE on queries against large tables
  • If performance issues detected: add indexes → verify with EXPLAIN → repeat
  • Use @EntityGraph to prevent N+1 queries

3. Validate pagination:

  • Ensure indexed columns support pagination queries
  • Test with large datasets to verify cursor stability

Examples

Basic CRUD Repository
java
@Repository
public interface ProductRepository extends JpaRepository<Product, Long> {
    // Derived query
    List<Product> findByCategory(String category);

    // Custom query
    @Query("SELECT p FROM Product p WHERE p.price > :minPrice")
    List<Product> findExpensiveProducts(@Param("minPrice") BigDecimal minPrice);
}
Pagination Implementation
java
@Service
public class ProductService {
    private final ProductRepository repository;

    public Page<Product> getProducts(int page, int size) {
        Pageable pageable = PageRequest.of(page, size, Sort.by("name").ascending());
        return repository.findAll(pageable);
    }
}
Entity with Auditing
java
@Entity
@EntityListeners(AuditingEntityListener.class)
public class Order {
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;

    @CreatedDate
    @Column(nullable = false, updatable = false)
    private LocalDateTime createdDate;

    @LastModifiedDate
    private LocalDateTime lastModifiedDate;

    @CreatedBy
    @Column(nullable = false, updatable = false)
    private String createdBy;
}

Best Practices

Show full SKILL.md (208 more words)Show less
Entity Design
  • Use constructor injection exclusively (never field injection)
  • Prefer immutable fields with final modifiers
  • Use Java records (16+) or @Value for DTOs
  • Always provide proper @Id and @GeneratedValue annotations
  • Use explicit @Table and @Column annotations
Performance Optimization
  • Use appropriate fetch strategies (LAZY vs EAGER)
  • Implement pagination for large datasets
  • Use database indexes for frequently queried fields
  • Consider using @EntityGraph to avoid N+1 query problems
Reference Documentation

For comprehensive examples, detailed patterns, and advanced configurations, see:

  • Examples - Complete code examples for common scenarios
  • Reference - Detailed patterns and advanced configurations

Constraints and Warnings

  • Never expose JPA entities directly in REST APIs; always use DTOs to prevent lazy loading issues.
  • Avoid N+1 query problems by using @EntityGraph or JOIN FETCH in queries.
  • Be cautious with CascadeType.REMOVE on large collections as it can cause performance issues.
  • Do not use EAGER fetch type for collections; it can cause excessive database queries.
  • Avoid long-running transactions as they can cause database lock contention.
  • Use @Transactional(readOnly = true) for read operations to enable optimizations.
  • Be aware of the first-level cache; entities may not reflect database changes within the same transaction.
  • UUID primary keys can cause index fragmentation; consider using sequential UUIDs or Long IDs.
  • Pagination on large datasets requires proper indexing to avoid full table scans.

© giuseppe-trisciuoglio, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 2 other files (references) in plugins/developer-kit-java/skills/spring-data-jpa of giuseppe-trisciuoglio/developer-kit.

  • SKILL.md
  • references/examples.md
  • references/reference.md

Open the folder on GitHubat commit fe73fb3

Compare with similar skills

Spring Data Jpa next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Spring Data Jpa compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Spring Data Jpa this skillgiuseppe-trisciuoglio/developer-kit357—~1.5kAutomated safety check: NotesMIT
Walkthroughalexanderop/walkthrough141—~3.4kAutomated safety check: NotesNone
Archify Diagramstt-a1i/archify82k—~2.9kAutomated safety check: PassMIT
JSON Canvasheyitsnoah/claudesidian2.6k18 repos~3.5kAutomated safety check: PassMIT
Diagram Designcathrynlavery/diagram-design49k1 repos~7.6kAutomated safety check: PassMIT
Fireworks Tech Graphtisfeng/Easydict15k1 repos~1.4kAutomated safety check: PassMIT

Similar skills

  • Walkthrough

    alexanderop/walkthrough

    Generates a self-contained HTML file with an interactive, clickable Mermaid diagram (flowchart or ER diagram) that explains how a codebase feature, flow, architecture, or database schema works.

    141 GitHub stars~3.4k tokensUpdated 6 mo ago
    DevelopmentAuto-check: notes
  • Archify Diagrams

    tt-a1i/archify

    Creates interactive architecture, workflow, sequence, data-flow and lifecycle diagrams as standalone HTML with inline SVG, themes and image or video export.

    82k GitHub stars~2.9k tokensUpdated today
    DevelopmentAuto-check passed
  • JSON Canvas

    heyitsnoah/claudesidian

    Create and edit JSON Canvas files (.canvas) with nodes, edges, groups, and connections.

    2.6k GitHub starsUsed in 18 repos~3.5k tokens
    DevelopmentAuto-check passed
  • Diagram Design

    cathrynlavery/diagram-design

    Creates branded diagrams, from architecture, flowchart and sequence to charts and maps, as self-contained HTML with inline SVG, with import from draw.io, Mermaid and Excalidraw.

    49k GitHub starsUsed in 1 repo~7.6k tokens
    DevelopmentAuto-check passed
  • Fireworks Tech Graph

    tisfeng/Easydict

    Create precise SVG technical diagrams, export PNG or offline HTML, and animate supported semantic SVGs to GIF.

    15k GitHub starsUsed in 1 repo~1.4k tokens
    DevelopmentAuto-check passed
  • Excalidraw Diagram

    coleam00/excalidraw-diagram-skill

    Create Excalidraw diagram JSON files that make visual arguments.

    5k GitHub starsUsed in 2 repos~6.1k tokens
    DevelopmentAuto-check passed

More from giuseppe-trisciuoglio/developer-kit

All 115 skills in this repo
  • Nestjs Drizzle Crud Generator

    giuseppe-trisciuoglio/developer-kit

    Generates complete CRUD modules for NestJS applications with Drizzle ORM.

    357 GitHub stars~1.3k tokensUpdated 1 mo ago
    Auto-check: notes
  • Spring Boot Actuator

    giuseppe-trisciuoglio/developer-kit

    Provides patterns to configure Spring Boot Actuator for production-grade monitoring, health probes, secured management endpoints, and Micrometer metrics across JVM services.

    357 GitHub stars~2.2k tokensUpdated 1 mo ago
    Auto-check: notes
  • Spring Boot Crud Patterns

    giuseppe-trisciuoglio/developer-kit

    Provides and generates complete CRUD workflows for Spring Boot 3 services.

    357 GitHub stars~2.5k tokensUpdated 1 mo ago
    Auto-check: notes
  • Spring Boot Security JWT

    giuseppe-trisciuoglio/developer-kit

    Provides JWT authentication and authorization patterns for Spring Boot 3.5.x covering token generation with JJWT, Bearer/cookie authentication, database/OAuth2 integration, and RBAC/permission-based…

    357 GitHub stars~3.9k tokensUpdated 1 mo ago
    Auto-check: notes
  • AWS CLI Beast

    giuseppe-trisciuoglio/developer-kit

    Provides advanced AWS CLI patterns for managing EC2, Lambda, S3, DynamoDB, RDS, VPC, IAM, and CloudWatch.

    357 GitHub stars~1.7k tokensUpdated 1 mo ago
    Auto-check: notes
  • PR Review Comments

    giuseppe-trisciuoglio/developer-kit

    Posts review findings from a JSON file as inline comments on a GitHub Pull Request, attaching each comment to its file and line.

    357 GitHub stars~1k tokensUpdated 1 mo ago
    Auto-check: notes

Questions about Spring Data Jpa

What does Spring Data Jpa do?

Provides patterns to implement persistence layers with Spring Data JPA. Spring Data Jpa is an agent skill from giuseppe-trisciuoglio/developer-kit. Provides patterns to implement persistence layers with Spring Data JPA.

When should I use Spring Data Jpa?

Spring Data Jpa fits situations like: creating repositories; configuring entity relationships; writing queries (derived and @Query); setting up pagination.

How do I install Spring Data Jpa in Claude Code?

Run `npx skills add giuseppe-trisciuoglio/developer-kit --skill spring-data-jpa -a claude-code`. Or copy the skill folder (plugins/developer-kit-java/skills/spring-data-jpa in giuseppe-trisciuoglio/developer-kit) into .claude/skills/spring-data-jpa in your project. Claude Code loads it when a task matches its description.

How do I install Spring Data Jpa in Codex?

Run `npx skills add giuseppe-trisciuoglio/developer-kit --skill spring-data-jpa -a codex`. Or copy the skill folder (plugins/developer-kit-java/skills/spring-data-jpa in giuseppe-trisciuoglio/developer-kit) into .agents/skills/spring-data-jpa in your project. Codex loads it when a task matches its description.

Can I use Spring Data Jpa in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add giuseppe-trisciuoglio/developer-kit --skill spring-data-jpa -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/spring-data-jpa, .gemini/skills/spring-data-jpa, .github/skills/spring-data-jpa and .opencode/skills/spring-data-jpa in your project.

What does Spring Data Jpa need to run?

SKILL.md names no scripts, command-line tools or credentials: Spring Data Jpa is instructions for the agent only. Its frontmatter pre-approves these tools: Read, Write, Edit, Bash, Glob, Grep.

Does Spring Data Jpa access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Spring Data Jpa safe to install?

Our automated static check of SKILL.md found notes only (pre-approves every shell command (allowed-tools: bash)), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.

What licence does Spring Data Jpa use?

Spring Data Jpa is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Spring Data Jpa use?

About 1.5k tokens (SKILL.md is roughly 6.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 30k tokens, read only when the agent opens those files.

What are the alternatives to Spring Data Jpa?

Skills that share tags, products or a category with Spring Data Jpa: Walkthrough (alexanderop/walkthrough, 141 stars), Archify Diagrams (tt-a1i/archify, 82k stars), JSON Canvas (heyitsnoah/claudesidian, 2.6k stars) and Diagram Design (cathrynlavery/diagram-design, 49k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Spring Data Jpa?

giuseppe-trisciuoglio (a GitHub user) maintains it in giuseppe-trisciuoglio/developer-kit, which has 357 GitHub stars. The repository holds 115 skills in this directory. The repository was last updated on September 10, 2026.

Source: giuseppe-trisciuoglio/developer-kit on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.