Skip to content

8주차 미션 [빈]#35

Open
deli-minju wants to merge 4 commits into
mainfrom
bean/week8
Open

8주차 미션 [빈]#35
deli-minju wants to merge 4 commits into
mainfrom
bean/week8

Conversation

@deli-minju
Copy link
Copy Markdown
Collaborator

🚩 관련 이슈

📌 구현 결과

  • Spring Security 적용 및 인증 체계 구성(formLogin + httpBasic)
  • 회원가입 API(Public) 구현: email/password 수집, BCrypt 암호화 저장
  • 선호 카테고리 선택값(member_prefer) 저장 로직 반영
  • API 접근 제어 적용: 회원가입/Swagger 공개, 그 외 Private
  • 인증/인가 실패 응답을 ApiResponse 형식으로 통일 (401/403)

❓ 리뷰 요청

🤔 질문

💬 기타 공유 사항

@deli-minju deli-minju self-assigned this May 20, 2026
Copy link
Copy Markdown
Member

@yangjiae12 yangjiae12 left a comment

Choose a reason for hiding this comment

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

회원가입에서 음식 카테고리 선택은 잘 반영되어 있는 것 같습니다! 다만 약관 동의에 대한 내용이 없는 것 같아 약관 동의 정보도 요청 DTO와 서비스 로직에 추가하면 좋을 것 같습니다

Comment on lines +68 to +75
List<Long> distinctCategoryIds = request.preferCategoryIds().stream()
.distinct()
.toList();

List<FoodCategory> categories = foodCategoryRepository.findAllById(distinctCategoryIds);
if (categories.size() != distinctCategoryIds.size()) {
throw new MemberException(MemberErrorCode.FOOD_CATEGORY_NOT_FOUND);
}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

요청한 카테고리 ID의 중복을 제거하고, 실제 조회된 개수와 비교해 존재 여부를 검증하는 흐름이 좋은 거 같습니다~

@NotBlank @Size(max = 255) String address,
@NotBlank @Size(max = 20) String nickname,
@NotBlank @Email @Size(max = 100) String email,
@NotBlank @Size(min = 8, max = 30) String password,
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

보안 요구사항에 따라 영문/숫자/특수문자 조합 등의 @pattern 검증을 추가해도 좋을 것 같습니다

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.

[Mission] 8주차 미션

2 participants