Remove duplicated Spring/Kotlin/Testing guidance from AGENTS.md files#2976
Remove duplicated Spring/Kotlin/Testing guidance from AGENTS.md files#2976
Conversation
…NTS.md Co-authored-by: afranken <763000+afranken@users.noreply.github.com>
…; replace with references to docs/ Co-authored-by: afranken <763000+afranken@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
This pull request consolidates documentation by removing duplicated Spring, Kotlin, and testing guidance from various AGENTS.md files and creating a new canonical docs/SPRING.md reference. This reduces maintenance overhead and eliminates the risk of inconsistent documentation across the codebase.
Changes:
- Created
docs/SPRING.mdas the canonical reference for Spring Boot patterns, dependency injection, exception handling, and testing conventions - Replaced 13 duplicated items in root
AGENTS.mdDO/DON'T section with references todocs/KOTLIN.md,docs/SPRING.md, anddocs/TESTING.md - Updated error handling sections in root and
server/AGENTS.mdto referencedocs/SPRING.md - Removed redundant bullets from
docs/TESTING.mdthat were already covered by the existing reference todocs/KOTLIN.md
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
docs/SPRING.md |
New canonical documentation for Spring Boot patterns including bean registration, dependency injection, controllers, configuration properties, exception handling, and testing guidelines |
AGENTS.md |
Replaced duplicated DO/DON'T guidance with references to canonical docs; updated error handling section to reference both docs/SPRING.md and server/AGENTS.md |
server/AGENTS.md |
Updated implementation flow and error handling sections to reference docs/SPRING.md instead of inline rules |
docs/TESTING.md |
Removed redundant naming, visibility, and legacy-names bullets that are already covered by the reference to docs/KOTLIN.md |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| ## Controllers | ||
|
|
||
| - `@RestController` classes map HTTP only — never contain business logic | ||
| - All logic is delegated to a `@Service`; controllers call the service and return the result |
There was a problem hiding this comment.
The use of backticks around "@service" is ambiguous and potentially confusing. Line 7 explicitly states not to use "@service" annotations, but this line suggests delegating to a "@service". Consider changing this to "service class" or "service bean" without backticks to avoid confusion with the Spring @Service annotation.
| - All logic is delegated to a `@Service`; controllers call the service and return the result | |
| - All logic is delegated to a service class; controllers call the service and return the result |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
AGENTS.mdfiles across the repo were re-stating guidance already covered in full bydocs/SPRING.md,docs/KOTLIN.md, anddocs/TESTING.md, creating maintenance overhead and inconsistency risk.Changes
Root
AGENTS.md— DO/DON'T sectionReplaced 13 duplicated items (Kotlin idioms, Spring patterns, testing conventions) with a three-line blockquote pointing to the canonical docs. Kept only project-specific rules with no other home: AWS SDK v2/v1, JUnit 5/4, copyright year, sub-module dependency versions.
Root
AGENTS.md— Error Handling sectionAdded a reference to
docs/SPRING.mdalongside the existingserver/AGENTS.mdpointer.server/AGENTS.mddocs/SPRING.mdS3Exceptionconstants rule bullet; replaced with a reference todocs/SPRING.md(server-specific handler class names retained)docs/TESTING.md— Conventions sectionRemoved Naming, Visibility, and Legacy-names bullets that verbatim restated
docs/KOTLIN.md; the existing reference at the top of that section already covers them.✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.