Feat: 회원가입 API 구현 (#50) #54
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
📌 개요
User↔UserProfile관계 리팩터링 (1:N → 1:1)🔨 작업 내용
1. 회원가입 서비스/컨트롤러
register메서드 구현 (중복 검증, 비밀번호 정책 검증, User & UserProfile 저장)CustomException+ErrorCode)POST /api/auth/register회원가입 API 구현201 Created반환, 실패 시 예외 매핑2. 테스트 코드
3. 예외 처리
MethodArgumentNotValidException처리 (COMMON_400)4. 엔티티 리팩터링
User↔UserProfile관계를 1:N → 1:1로 변경User.userProfiles (List<UserProfile>)→User.userProfile (단일 UserProfile)UserProfile에서@OneToOne매핑 적용UserProfile자동 생성 및 연관관계 설정🔗 관련 이슈
Closes #50
📝 참고 사항
✅ 체크리스트