Skip to content

feat/ #43 enum추가, 외부 출처 추가#44

Merged
warcat12 merged 2 commits into
developfrom
feat/#43
Jun 1, 2026
Merged

feat/ #43 enum추가, 외부 출처 추가#44
warcat12 merged 2 commits into
developfrom
feat/#43

Conversation

@warcat12
Copy link
Copy Markdown
Collaborator

@warcat12 warcat12 commented Jun 1, 2026

📌 관련 이슈

관련된 이슈 번호를 작성해 주세요.

Closes #43


🛠️ 작업 내용

구현한 내용을 간략히 설명해 주세요.
enum추가
외부 출처 추가

✅ 변경 사항

  • [ ]
  • [ ]

🔍 테스트 내용

테스트한 방법과 결과를 작성해 주세요.

  • 단위 테스트 작성 / 확인
  • 기능 동작 확인

📷 스크린샷 (선택사항)

UI 변경이 있는 경우 첨부해 주세요.

💬 리뷰어에게

리뷰 시 특별히 봐줬으면 하는 부분이 있다면 작성해 주세요.


📋 PR 체크리스트

  • develop 브랜치를 base로 설정했나요?
  • 코드 컨벤션을 준수했나요?
  • 불필요한 주석 / 디버그 코드를 제거했나요?
  • 관련 이슈 번호를 연결했나요?

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 1, 2026

ℹ️ Claude 코드 리뷰 생략: 변경된 파일이 15개로 너무 많습니다. 10개 이하로 분리하는 것을 권장합니다.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 1, 2026

Test Results

1 tests  ±0   1 ✅ ±0   0s ⏱️ ±0s
1 suites ±0   0 💤 ±0 
1 files   ±0   0 ❌ ±0 

Results for commit f0af276. ± Comparison against base commit c2b3e23.

♻️ This comment has been updated with latest results.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 1, 2026

✅ 테스트 결과: 모든 테스트 통과

항목
전체 1
통과 1
실패 0
건너뜀 0

Copy link
Copy Markdown
Collaborator

@jychoi0831 jychoi0831 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

현재 head commit 0ff7f645 기준으로 확인했습니다.

P1: 기존 registration_source=MANUAL 데이터를 새 enum으로 읽을 수 없습니다

src/main/java/com/closetnangam/be/domain/clothes/entity/WardrobeClothes.java:56에서 기존 wardrobe_clothes.registration_source 컬럼을 ClothesInfoSource enum으로 다시 매핑했습니다. 그런데 새 enum은 PHOTO, PURCHASE_HISTORY, EXTERNAL_SHOPPING만 가지고 있고, 기존 코드가 직접 등록/위시리스트 등록 시 저장하던 MANUAL 값은 더 이상 존재하지 않습니다. 현재 src/main/resources/db/migration.sql:40wardrobe_clothes.registration_source 보정 쿼리도 주석 처리되어 있어 실제로 실행되지 않습니다.

영향:

기존 DB에 registration_source = 'MANUAL' row가 하나라도 있으면 WardrobeClothes를 로딩하는 순간 Hibernate가 No enum constant ... ClothesInfoSource.MANUAL 형태로 실패할 수 있습니다. 옷장 목록 조회, 상세 조회, 즐겨찾기/수정/삭제처럼 WardrobeClothesRepository를 거치는 기존 사용자 데이터 플로우가 배포 직후 깨질 수 있습니다. 테스트가 통과한 것은 create-drop 기반 신규 스키마라 레거시 enum 값이 없어서 이 문제를 재현하지 못한 것으로 보입니다.

해결 방향:

배포 전에 실행되는 마이그레이션에서 wardrobe_clothes.registration_source의 기존 값들을 새 enum 값으로 실제 업데이트해야 합니다. 예를 들어 기존 MANUAL 중 보유 옷은 PURCHASE_HISTORY, 외부 위시리스트는 EXTERNAL_SHOPPING, 사진 기반은 PHOTO처럼 clothes.source_type, clothes.external_source, 기존 registration_source를 기준으로 명시적으로 백필한 뒤 애플리케이션을 올려야 합니다. 현재처럼 보정 SQL이 주석으로만 남아 있으면 안전하게 병합하기 어렵습니다.


검증:

  • git diff --check origin/develop..origin/feat/#43: 통과
  • ./gradlew compileJava --offline: 성공
  • ./gradlew test --offline: 성공

본 리뷰는 Codex를 사용해 작성했습니다.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 1, 2026

ℹ️ Claude 코드 리뷰 생략: 변경된 파일이 15개로 너무 많습니다. 10개 이하로 분리하는 것을 권장합니다.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 1, 2026

✅ 테스트 결과: 모든 테스트 통과

항목
전체 1
통과 1
실패 0
건너뜀 0

Copy link
Copy Markdown
Collaborator

@jychoi0831 jychoi0831 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

현재 head commit f0af2768 기준으로 확인했습니다.

추가 merge-blocking finding은 발견하지 못했습니다.

검증:

  • git diff --check origin/develop..origin/feat/#43: 통과
  • ./gradlew compileJava --offline: 성공
  • ./gradlew test --offline: 성공

잔여 리스크 또는 테스트 보강 권장:

  • registration_source enum 전환은 기존 DB 데이터와 직접 맞물립니다. 이번 head에서 db/migration-info-source-enum.sql이 추가되어 이전 blocker는 해소된 것으로 보지만, 현재 프로젝트 설정상 Flyway/Liquibase 자동 실행은 보이지 않으므로 앱 배포 전에 해당 스크립트를 실제 운영 DB에 먼저 적용하는 절차가 반드시 필요합니다.
  • 테스트는 신규 H2 스키마 기준이라 레거시 registration_source = 'MANUAL' 데이터 로딩까지 검증하지는 못합니다. 가능하면 마이그레이션 전/후 샘플 데이터로 WardrobeClothes 조회가 정상 동작하는 회귀 테스트를 보강하는 것을 권장합니다.

본 리뷰는 Codex를 사용해 작성했습니다.

@warcat12 warcat12 merged commit 28d84af into develop Jun 1, 2026
3 checks passed
@warcat12 warcat12 deleted the feat/#43 branch June 1, 2026 01:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat/ 옷 정보 출처 내역 enum

2 participants