chore: 문서를 작성할 때 한국어의 표현 작성 스킬 추가 및 1인칭 관점의 글 작성 검증 테스트 추가
This commit is contained in:
+30
@@ -0,0 +1,30 @@
|
||||
---
|
||||
title: ca-tmpl - Clean Architecture 패키지 레이아웃 결정
|
||||
source_type: project
|
||||
status: verified
|
||||
confidence: high
|
||||
---
|
||||
|
||||
# ca-tmpl - Clean Architecture 패키지 레이아웃 결정
|
||||
|
||||
## 프로젝트 컨텍스트
|
||||
|
||||
ca-tmpl은 Java 21, Spring Boot 3.4, Gradle multi-module 기반 Clean Architecture template이다. `domain-core`, `application-core`, `adapter-*`, `shared-contract`, `app-bootstrap`, `sample-portfolio`를 물리적으로 분리한다.
|
||||
|
||||
## 실제 구현 내용
|
||||
|
||||
`domain-core`는 Spring, JPA, Servlet, Hibernate, Lombok, application, adapter, bootstrap 의존을 금지해 framework-neutral POJO 경계를 유지한다.
|
||||
|
||||
`application-core`는 adapter와 bootstrap, Spring Web, persistence, Hibernate에 의존하지 못한다. `@Transactional`과 `ApplicationContext` 직접 의존도 금지한다.
|
||||
|
||||
`shared-contract`는 response, request, error, operation, headers, logging, tracing, metrics, registry, annotation 같은 운영 계약 package만 허용한다. business common dumping ground로 사용하지 않는다.
|
||||
|
||||
## 경계 검증
|
||||
|
||||
Gradle의 `verifyCleanArchitectureDependencies`는 project dependency graph를 검사한다. ArchUnit의 `CleanArchitectureTest`는 source import graph를 검사한다. 두 검사는 서로 다른 그래프를 담당한다.
|
||||
|
||||
정적 분석은 모든 우회를 잡지 못한다. `getBean(String)`, `Class.forName(String)`, `BeanFactory#getBeansOfType` 같은 reflection-style bypass는 code review checklist로 보완한다.
|
||||
|
||||
## 검증 범위
|
||||
|
||||
module dependency matrix와 ArchUnit rule은 로컬에서 검증했다. 운영 배포와 운영 metric으로 검증한 결과는 없다.
|
||||
Reference in New Issue
Block a user