Skip to content
Back to skills

Spring Boot Architecture

ASecurity

Organize by business feature, with layers inside each feature, rather than one global `controllers`, `services`, and `repositories` package: ```text com.example.app order/ OrderController.java // web adapter OrderService.java // business orchestration OrderRepository.java // persistence adapter/port OrderRequest.java OrderResponse.java // records user/ ... shared/ error/ ``` The dependency direction is inward: web depends on service/domain, and persistence impl...

  • 549 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 5, 2026
developmentjavaapidatabase

Works with

  • api

Security analysis

A100/100

Pro scans all 11 files and shows the line behind each finding

Scanned September 5, 2026

npx -y skills add HoangNguyen0403/agent-skills-standard --skill spring-boot-architecture --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Spring Boot Architecture?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Spring Boot Architecture
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/hoangnguyen0403-spring-boot-architecture-agent-skills-standard/badge)](https://www.skillsdirectory.com/skills/hoangnguyen0403-spring-boot-architecture-agent-skills-standard)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
Organize by business feature, with layers inside each feature, rather than one global `controllers`, `services`, and `repositories` package:

```text
com.example.app
  order/
    OrderController.java       // web adapter
    OrderService.java           // business orchestration
    OrderRepository.java        // persistence adapter/port
    OrderRequest.java
    OrderResponse.java          // records
  user/
    ...
  shared/
    error/
```

The dependency direction is inward: web depends on service/domain, and persistence implements an inner-facing repository port. Services must not depend on controllers. Controllers should handle HTTP, `@Valid`, and DTO mapping; services should own business rules, orchestration, and transaction boundaries; repositories should do database work only.

Use Java 17+ records for immutable API DTOs and never return a JPA entity directly. Add `@RestControllerAdvice` with RFC 7807 `ProblemDetail` for errors and Jakarta Bean Validation constraints on input DTOs. Put `@Transactional` on the service boundary, normally with `readOnly = true` for read paths. A practical verification pass checks that every response is a DTO, every input is validated, no inner layer imports web classes, and error responses do not expose stack traces.


Files in this skill

  • eval-1.baseline.md777 B
  • eval-1.with-skill.md1.2 KB
  • eval-2.baseline.md690 B
  • eval-2.with-skill.md1.2 KB
  • eval-3.baseline.md694 B
  • eval-3.with-skill.md1004 B
  • trigger-1.md132 B
  • trigger-2.md102 B
  • trigger-3.md126 B
  • trigger-4.md127 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…