chore: 팀 워크플로우 초기화 및 CLAUDE.md 프로젝트 특화

- CLAUDE.md: 프로젝트 실제 구조(com.snp.batch) 및 기술 스택 반영
- settings.json: hooks 섹션 추가 (SessionStart, PreCompact, PostToolUse)
- settings.json: chmod, scripts 실행 권한 추가
- workflow-version.json: v1.6.1 초기 생성
- .githooks: 서버 최신 버전으로 동기화 (commit-msg, post-checkout, pre-commit)
- frontend/.gitignore: 프론트엔드 빌드 산출물 제외 패턴

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
HYOJIN 2026-03-23 14:18:34 +09:00
부모 f6683b269e
커밋 a8135dbf89
7개의 변경된 파일122개의 추가작업 그리고 22개의 파일을 삭제

파일 보기

@ -26,7 +26,9 @@
"Bash(git show *)",
"Bash(git tag *)",
"Bash(curl -s *)",
"Bash(sdk *)"
"Bash(sdk *)",
"Bash(chmod +x *)",
"Bash(bash .claude/scripts/*)"
],
"deny": [
"Bash(git push --force*)",
@ -46,5 +48,42 @@
"Read(./**/application-local.yml)",
"Read(./**/application-local.properties)"
]
},
"hooks": {
"SessionStart": [
{
"matcher": "compact",
"hooks": [
{
"type": "command",
"command": "bash .claude/scripts/on-post-compact.sh",
"timeout": 10
}
]
}
],
"PreCompact": [
{
"hooks": [
{
"type": "command",
"command": "bash .claude/scripts/on-pre-compact.sh",
"timeout": 30
}
]
}
],
"PostToolUse": [
{
"matcher": "Bash",
"hooks": [
{
"type": "command",
"command": "bash .claude/scripts/on-commit.sh",
"timeout": 15
}
]
}
]
}
}

파일 보기

@ -0,0 +1,6 @@
{
"applied_global_version": "1.6.1",
"applied_date": "2026-03-23",
"project_type": "java-maven",
"gitea_url": "https://gitea.gc-si.dev"
}

0
.githooks/commit-msg Normal file → Executable file
파일 보기

0
.githooks/post-checkout Normal file → Executable file
파일 보기

0
.githooks/pre-commit Normal file → Executable file
파일 보기

파일 보기

@ -1,17 +1,21 @@
# 프로젝트 개요
- **타입**: Java + Spring Boot + Maven
- **JDK**: 17 (`.sdkmanrc` 참조)
- **프레임워크**: Spring Boot
- **프로젝트명**: SNP Sync Batch
- **타입**: Java + Spring Boot + Spring Batch + Maven
- **설명**: S&P Global 해양 데이터를 API로 수집하여 PostgreSQL에 동기화하는 배치 시스템 (Web GUI 포함)
- **JDK**: 17 (`.sdkmanrc` 참조, 17.0.18-amzn)
- **프레임워크**: Spring Boot 3.2.1, Spring Batch 5.1.0, Quartz 2.5.0
- **빌드 도구**: Maven (Maven Wrapper 사용)
- **DB**: PostgreSQL (dual datasource: batch-meta + business)
- **프론트엔드**: React (frontend-maven-plugin으로 빌드 통합)
## 빌드 및 실행
```bash
# 빌드
./mvnw clean compile
# 빌드 (백엔드만)
./mvnw clean compile -DskipTests
# 패키징
# 전체 패키징 (프론트엔드 포함)
./mvnw clean package -DskipTests
# 테스트
@ -20,7 +24,7 @@
# 특정 테스트 클래스 실행
./mvnw test -Dtest=클래스명
# 로컬 실행
# 로컬 실행 (포트 8051, context-path: /snp-sync)
./mvnw spring-boot:run
# 린트 (Checkstyle 설정된 경우)
@ -33,21 +37,48 @@
src/
├── main/
│ ├── java/
│ │ └── com/gcsc/{프로젝트}/
│ │ ├── config/ # 설정 클래스
│ │ ├── controller/ # REST 컨트롤러
│ │ ├── service/ # 비즈니스 로직
│ │ ├── repository/ # 데이터 접근
│ │ ├── domain/ # 엔티티
│ │ ├── dto/ # 데이터 전송 객체
│ │ ├── exception/ # 예외 처리
│ │ └── util/ # 유틸리티
│ │ └── com/snp/batch/
│ │ ├── SnpBatchApplication.java # 메인 클래스
│ │ ├── common/
│ │ │ ├── batch/ # 배치 공통 (Base 클래스들)
│ │ │ │ ├── config/ # BaseJobConfig
│ │ │ │ ├── entity/ # BaseEntity
│ │ │ │ ├── processor/ # BaseProcessor
│ │ │ │ ├── reader/ # BaseApiReader
│ │ │ │ ├── repository/ # BaseJdbcRepository
│ │ │ │ └── writer/ # BaseWriter, BaseChunkedWriter
│ │ │ ├── util/ # 유틸리티 (EntityUtils, CommonSql 등)
│ │ │ └── web/ # 웹 공통 (BaseController, BaseService)
│ │ ├── jobs/datasync/batch/ # 동기화 배치 Job 모듈
│ │ │ ├── code/ # 코드 동기화 (Stat5Code, FlagCode)
│ │ │ ├── compliance/ # 컴플라이언스 동기화
│ │ │ ├── facility/ # 시설/항구 동기화
│ │ │ ├── movement/ # 선박 이동 동기화
│ │ │ ├── psc/ # PSC 검사 동기화
│ │ │ └── ... # ship, event, risk 등
│ │ └── scheduler/ # Quartz 스케줄러
│ └── resources/
│ ├── application.yml # 공통 설정
│ ├── application-local.yml # 로컬 설정 (.gitignore)
│ └── application-prod.yml # 운영 설정
└── test/
└── java/ # 테스트 코드
│ ├── application-dev.yml # 개발 설정
│ ├── application-prod.yml # 운영 설정
│ └── application-local.yml # 로컬 설정 (.gitignore)
├── test/
│ └── java/ # 테스트 코드
└── frontend/ # React 프론트엔드
```
## 배치 Job 구조 패턴
각 도메인 모듈은 동일한 구조를 따름:
```
jobs/datasync/batch/{도메인}/
├── config/ # JobConfig (Step, Job 정의)
├── dto/ # API 응답 DTO
├── entity/ # DB Entity
├── reader/ # ItemReader (API 호출)
├── processor/ # ItemProcessor (DTO → Entity 변환)
├── repository/ # JdbcRepository (SQL 직접 사용)
└── writer/ # ItemWriter (DB 저장)
```
## 팀 규칙

24
frontend/.gitignore vendored Normal file
파일 보기

@ -0,0 +1,24 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*
node_modules
dist
dist-ssr
*.local
# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?