Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/cagridursun/ai-peer-live-coding-agentWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/rules/cagridursun/ai-peer-live-coding-agent/spring-boot-patterns)<a href="https://agentmods.dev/rules/cagridursun/ai-peer-live-coding-agent/spring-boot-patterns"><img src="https://agentmods.dev/badge/rules/cagridursun/ai-peer-live-coding-agent/spring-boot-patterns/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/rules/cagridursun/ai-peer-live-coding-agent/spring-boot-patterns"><img src="https://agentmods.dev/badge/rules/cagridursun/ai-peer-live-coding-agent/spring-boot-patterns.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00760 | $0.00760 |
| Opus 5.5 | $0.00304 | $0.00304 |
| Sonnet 5.5 | $0.00152 | $0.00152 |
| Haiku 4.5 | $0.00076 | $0.00076 |
Grade A, and why
spring-boot-patterns scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 56 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Spring Boot — Preferred Patterns & Conventions
Reference Code
When building a new service, look for proven patterns in your own practice projects or open-source Spring Boot examples:
- [EXAMPLE_PROJECT_PATH/URL] conversational / workflow APIs (state machines, step validation)
- [EXAMPLE_PROJECT_PATH/URL] CRUD REST APIs (standard controller → service → repository)
- [EXAMPLE_PROJECT_PATH/URL] OpenAPI-first services (codegen for interfaces and DTOs)
Consult those references for project structure, Maven config, test patterns, and error handling — adapt to the interview scope, not copy wholesale.
Architecture
- 3-layer max: Controller → Service → Repository
- Kotlin for entity/model classes only (no Lombok); Java for all other code — optional, use when the problem fits
- OpenAPI codegen for controller interfaces and DTOs (
interfaceOnly=true) — optional - JPA + H2 in-memory with
create-dropDDL — when persistence is required @RestControllerAdvicefor centralized error responsesBigDecimalfor monetary valuesConcurrentHashMapfor in-memory rate limiting or caches
Maven / Build
- Kotlin compiler plugins:
spring+jpa(allopen + noarg) — when using Kotlin entities kotlin-maven-noargdependency required for JPA entity no-arg constructors- Kotlin compiles before Java; OpenAPI generated sources in Kotlin
sourceDirs - Java
default-compilephasenone, customjava-compileafter Kotlin — when mixing Kotlin + Java - Set
maven.compiler.source,maven.compiler.target,maven.compiler.releaseexplicitly in<properties>for IDE compatibility - JaCoCo 0.8.14+ for Java 21+ (older versions may fail on newer class file versions)
- Exclude generated API packages from JaCoCo coverage reports
Error Handling
- Custom exceptions: NotFoundException (404), ConflictException (409), ValidationException (400), RateLimitException (429)
GlobalExceptionHandlermaps toErrorResponsewithcode,message,details(list ofFieldError)- Filter-thrown exceptions: inject
HandlerExceptionResolver, callresolveException()to route through@RestControllerAdvice - Always structured JSON, never plain text
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2mo ago First seen · 56 lines · 760 tokens per session scan A 4870840e8950
spring-boot-patterns is a cursor rule published in the GitHub repository cagridursun/ai-peer-live-coding-agent (14 stars, last pushed 2mo ago), licensed MIT. It adds 760 tokens to every session, about $0.0030 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other cursor rules, from other repositories
springboot-jpa-best-practices
A set of Chinese-language rules for structuring Java Spring Boot applications that use JPA, a library for database access.
graftcode-java
Mandatory Graftcode architecture rules for building Java backend services (plain Maven/Gradle modules exposed via Graftcode Gateway, not REST).
spring-boot-architecture
Spring Boot Java architecture contract for feature packaging, service boundaries, repositories, DTOs, mappers, and controller dependencies.
spring-boot-http-client
Spring Boot outbound HTTP contract for RestClient beans, timeouts, and repository-side remote calls.
spring-retry-conventions
Spring Boot database retry conventions using AbstractDatabaseService and RetryTemplate.
java-springboot-standards
Java Spring Boot coding standards and patterns for your monorepo services.