Conversation
seogwoojin
reviewed
Sep 6, 2024
|
|
||
| @GetMapping("/me") | ||
| fun getMyProfile( | ||
| @AuthenticationPrincipal userDetails: UserDetails |
Collaborator
There was a problem hiding this comment.
제가 주입한 MemberJwtToken은 SecurityContextHolder.getContext().authentication 객체를 가져와야해서,
@userid userId:Long 로 제가 커스텀한 어노테이션을 사용하셔야 할 것 같습니다.
| companion object { | ||
| fun toUserProfileResponse(user: User): UserProfileResponse { | ||
| return UserProfileResponse( | ||
| id = user.id ?: throw BusinessException(ErrorCode.USER_ID_NULL), |
Collaborator
There was a problem hiding this comment.
BusinessException에 ErrorCode를 넣는 것보다 BusinessException 객체를 상속한 UserNullException 같은 걸 만들어 쓰는 것 같습니다
| import org.springframework.cache.annotation.EnableCaching | ||
|
|
||
| @SpringBootApplication class SpringAccountApplication | ||
| @SpringBootApplication @EnableCaching class SpringAccountApplication |
Collaborator
There was a problem hiding this comment.
JVM 캐싱 사용하지 않으면 제거해야 할 것 같습니다.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
🔍️ 이 PR을 통해 해결하려는 문제가 무엇인가요?
✨ 이 PR에서 핵심적으로 변경된 사항은 무엇일까요?
🔖 핵심 변경 사항 외에 추가적으로 변경된 부분이 있나요?
🙏 Reviewer 분들이 이런 부분을 신경써서 봐 주시면 좋겠어요
🩺 이 PR에서 테스트 혹은 검증이 필요한 부분이 있을까요?
📌 PR 진행 시 이러한 점들을 참고해 주세요
📝 Assignee를 위한 CheckList