Skip to main content
skill CX Codex

512-frameworks-micronaut-data — Claude Code skill for Micronaut Data

A skill for Micronaut Data work: entity mapping, repositories, transactions, pagination, projections and Testcontainers tests.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add jabrena/plinth --skill 512-frameworks-micronaut-data -a claude-code
Open on GitHub

What 512-frameworks-micronaut-data does

The skill kicks in when you write or review a Micronaut Data persistence layer. It walks the agent through @MappedEntity, @Id, @GeneratedValue and @MappedProperty, @Repository interfaces built on CrudRepository or PageableRepository, derived finder methods, and @Query with named parameters. It also covers @Transactional on @Singleton services, Page and Pageable for list endpoints, DTO and interface projections, and @Version for optimistic locking.

The workflow has four steps. First the agent reads references/512-frameworks-micronaut-data.md and inspects the project. Then it settles on the smallest safe set of changes, applies them along the reference patterns, and runs the build with tests. Before touching anything it runs ./mvnw compile or mvn compile. A failed compile stops the skill right there. After the edits come ./mvnw clean verify or mvn clean verify.

Integration tests are covered through @MicronautTest with TestPropertyProvider and Testcontainers. If your goal is vague, or files and credentials are missing, the skill stops and asks a clarifying question instead of editing files across the project. Raw java.sql access without generated repositories is a different skill in the same set, 511-frameworks-micronaut-jdbc — the two are easy to mix up, so check which layer you are actually changing.

What it helps with

  • map an entity with @MappedEntity and bind fields to columns
  • add a repository on CrudRepository or PageableRepository
  • write a @Query with named parameters instead of hand-rolled SQL
  • wrap a service in @Transactional and split out readOnly calls
  • return a list page by page with Page and Pageable

Example prompts for the agent

  • Review my Micronaut Data repositories and entities and tell me what to fix
  • Add pagination to the orders list endpoint with Page and Pageable
  • Check the transactions in my services and point out where readOnly fits

How to install 512-frameworks-micronaut-data

1Skills CLI (Vercel)

npx skills add jabrena/plinth --skill 512-frameworks-micronaut-data -a claude-code

2Manually: put the files in place

~/.claude/skills/512-frameworks-micronaut-data/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/512-frameworks-micronaut-data/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about 512-frameworks-micronaut-data

How do I install 512-frameworks-micronaut-data in Claude?

Run npx skills add jabrena/plinth --skill 512-frameworks-micronaut-data -a claude-code. The skill file lands at ~/.claude/skills/512-frameworks-micronaut-data/SKILL.md.

What does this skill do?

It guides the agent through Micronaut Data patterns: entity mapping, repositories, @Query, transactions, pagination, projections, optimistic locking and integration tests with Testcontainers.

How is it different from the Micronaut JDBC skill?

This one covers generated Micronaut Data repositories. For direct java.sql access without them, the same set ships 511-frameworks-micronaut-jdbc.

Source text

SKILL.md · Apache-2.0
---
name: 512-frameworks-micronaut-data
description: Use when you need data access with Micronaut Data — @MappedEntity, CrudRepository/PageableRepository, @Query with parameters, @Transactional services, projections, @Version, and @MicronautTest with TestPropertyProvider and Testcontainers. For raw java.sql access without generated repositories, use @511-frameworks-micronaut-jdbc. This should trigger for requests such as Review or implement Micronaut Data repositories and entities; Add transactions, pagination, or projections in Micronaut persistence layer; Model Micronaut Data entities and repositories; Review Micronaut Data transactions and pageable queries; Improve projections or optimistic locking with Micronaut Data. Part of Plinth Toolkit
license: Apache-2.0
metadata:
  author: Juan Antonio Breña Moral
  version: 0.19.0
---
# Micronaut Data Guidelines

Apply Micronaut Data patterns for relational repositories and safe SQL.

**What is covered in this Skill?**

- @MappedEntity, @Id, @GeneratedValue, @MappedProperty for column mapping
- @Repository interfaces extending CrudRepository / PageableRepository
- Derived finder methods and @Query with named parameters
- @Transactional on @Singleton services (readOnly where appropriate)
- Page and Pageable for list endpoints
- DTO/interface projections for read-heavy queries
- @Version for optimistic locking
- Integration tests: @MicronautTest + TestPropertyProvider + Testcontainers

**Scope:** Apply recommendations based on the reference rules and good/bad code examples.

## Constraints

Compile before persistence changes; verify the full build after.

- **MANDATORY**: Run `./mvnw compile` or `mvn compile` before applying any change
- **SAFETY**: If compilation fails, stop immediately
- **VERIFY**: Run `./mvnw clean verify` or `mvn clean verify` after applying improvements
- **BEFORE APPLYING**: Read the reference for detailed rules and examples
- **EDGE CASE**: If the user goal is ambiguous, stop and ask a clarifying question before editing files or running project-wide commands
- **EDGE CASE**: If required context, files, credentials, or tools are missing, report the blocker explicitly and ask whether to proceed with setup or fallback guidance
- **EDGE CASE**: If requested changes conflict with project constraints or safety boundaries, explain the conflict and ask for user confirmation on the preferred trade-off

## When to use this skill

- Review or implement Micronaut Data repositories and entities
- Add transactions, pagination, or projections in Micronaut persistence layer
- Model Micronaut Data entities and repositories
- Review Micronaut Data transactions and pageable queries
- Improve projections or optimistic locking with Micronaut Data

## Workflow

1. **Read reference and assess project context**

Read `references/512-frameworks-micronaut-data.md` and inspect the current project setup before proposing changes.

2. **Gather scope and decide target improvements**

Identify requested outcomes, constraints, and the minimum safe set of changes to apply.

3. **Apply framework-aligned changes**

Implement or refactor configuration/code following the reference patterns and project conventions.

4. **Run verification and report results**

Execute appropriate build/tests and summarize what changed, what was verified, and any follow-up actions.

## Reference

For detailed guidance, examples, and constraints, see [references/512-frameworks-micronaut-data.md](references/512-frameworks-micronaut-data.md).

© Juan Antonio Breña Moral · Apache-2.0 · jabrena/plinth

Similar skills

Everything for Backend and APIs →

From the same set40

323-frameworks-spring-boot-testing-acceptance-tests Turns maintainer-sanitized Gherkin scenarios into Spring Boot acceptance tests with TestRestTemplate, Testcontainers and WireMock. CX Codex +1 324installs 401-frameworks-quarkus-core A skill that reviews and fixes the core of a Quarkus app: CDI beans, profiles, interceptors, virtual threads. Useful once the Java project already compiles. CX Codex +1 321installs 114-java-maven-search Reads outdated dependency and plugin reports from your pom.xml and helps verify Maven artifact coordinates from approved evidence. CX Codex +1 315installs 413-frameworks-quarkus-db-migrations-flyway A skill that has your coding agent add and review Flyway migrations in a Quarkus app: the quarkus-flyway extension, SQL scripts, config and ordering. CX Codex +1 313installs 411-frameworks-quarkus-jdbc A skill for programmatic JDBC in Quarkus: Agroal DataSource, parameterized SQL, transactions, batching and Dev Services. Useful when reviewing data access. CX Codex +1 312installs 701-technologies-openapi Guides you through an OpenAPI 3.x contract: spec structure, reusable schemas, security schemes, breaking-change checks. Useful when the contract lives apart from the code. CX Codex +1 309installs 303-frameworks-spring-boot-validation A skill that tells your coding agent how to design and review Spring Boot validation: Bean Validation on DTOs, @Valid at API boundaries, constraint groups and consistent 400 responses. CX Codex +1 303installs 501-frameworks-micronaut-core A skill that reviews and fixes Micronaut Java code: beans, configuration, @Requires, scheduling and blocking I/O. CX Codex +1 302installs

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor