Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weโ€™ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: user #2

Open
wants to merge 21 commits into
base: main
Choose a base branch
from
Open

feat: user #2

wants to merge 21 commits into from

Conversation

23tae
Copy link
Collaborator

@23tae 23tae commented Aug 13, 2024

๐Ÿ”๏ธ ์ด PR์„ ํ†ตํ•ด ํ•ด๊ฒฐํ•˜๋ ค๋Š” ๋ฌธ์ œ๊ฐ€ ๋ฌด์—‡์ธ๊ฐ€์š”?

์–ด๋–ค ๊ธฐ๋Šฅ์„ ๊ตฌํ˜„ํ•œ๊ฑด์ง€, ์ด์Šˆ ๋Œ€์‘์ด๋ผ๋ฉด ์–ด๋–ค ์ด์Šˆ์ธ์ง€ PR์ด ์—ด๋ฆฌ๊ฒŒ ๋œ ๊ณ„๊ธฐ์™€ ๋ชฉ์ ์„ Reviewer ๋“ค์ด ์‰ฝ๊ฒŒ ์ดํ•ดํ•  ์ˆ˜ ์žˆ๋„๋ก ์ ์–ด ์ฃผ์„ธ์š”
์ผ๊ฐ ๋ฐฑ๋กœ๊ทธ ๋งํฌ๋‚˜ ๋‹ค์ด์–ด๊ทธ๋žจ, ํ”ผ๊ทธ๋งˆ, ์บก์ณ๋ฅผ ์ฒจ๋ถ€ํ•ด๋„ ์ข‹์•„์š”

  • User ๋„๋ฉ”์ธ์„ ๊ตฌํ˜„ํ•ฉ๋‹ˆ๋‹ค.(์ง„ํ–‰์ค‘)

โœจ ์ด PR์—์„œ ํ•ต์‹ฌ์ ์œผ๋กœ ๋ณ€๊ฒฝ๋œ ์‚ฌํ•ญ์€ ๋ฌด์—‡์ผ๊นŒ์š”?

๋ฌธ์ œ๋ฅผ ํ•ด๊ฒฐํ•˜๋ฉด์„œ ์ฃผ์š”ํ•˜๊ฒŒ ๋ณ€๊ฒฝ๋œ ์‚ฌํ•ญ๋“ค์„ ์ ์–ด ์ฃผ์„ธ์š”

๐Ÿ”– ํ•ต์‹ฌ ๋ณ€๊ฒฝ ์‚ฌํ•ญ ์™ธ์— ์ถ”๊ฐ€์ ์œผ๋กœ ๋ณ€๊ฒฝ๋œ ๋ถ€๋ถ„์ด ์žˆ๋‚˜์š”?

์—†์œผ๋ฉด "์—†์Œ" ์ด๋ผ๊ณ  ๊ธฐ์žฌํ•ด ์ฃผ์„ธ์š”

๐Ÿ™ Reviewer ๋ถ„๋“ค์ด ์ด๋Ÿฐ ๋ถ€๋ถ„์„ ์‹ ๊ฒฝ์จ์„œ ๋ด ์ฃผ์‹œ๋ฉด ์ข‹๊ฒ ์–ด์š”

๊ฐœ๋ฐœ ๊ณผ์ •์—์„œ ๋‹ค๋ฅธ ๋ถ„๋“ค์˜ ์˜๊ฒฌ์€ ์–ด๋– ํ•œ์ง€ ๊ถ๊ธˆํ–ˆ๊ฑฐ๋‚˜ ํฌ๋กœ์Šค ์ฒดํฌ๊ฐ€ ํ•„์š”ํ•˜๋‹ค๊ณ  ๋Š๊ปด์ง„ ์ฝ”๋“œ๊ฐ€ ์žˆ๋‹ค๋ฉด ๋‚จ๊ฒจ์ฃผ์„ธ์š”

๐Ÿฉบ ์ด PR์—์„œ ํ…Œ์ŠคํŠธ ํ˜น์€ ๊ฒ€์ฆ์ด ํ•„์š”ํ•œ ๋ถ€๋ถ„์ด ์žˆ์„๊นŒ์š”?

ํ…Œ์ŠคํŠธ๊ฐ€ ํ•„์š”ํ•œ ํ•ญ๋ชฉ์ด๋‚˜ ํ…Œ์ŠคํŠธ ์ฝ”๋“œ๊ฐ€ ์ถ”๊ฐ€๋˜์—ˆ๋‹ค๋ฉด ํ•จ๊ป˜ ์ ์–ด์ฃผ์„ธ์š”

๐Ÿ“Œ PR ์ง„ํ–‰ ์‹œ ์ด๋Ÿฌํ•œ ์ ๋“ค์„ ์ฐธ๊ณ ํ•ด ์ฃผ์„ธ์š”

  • Reviewer ๋ถ„๋“ค์€ ์ฝ”๋“œ ๋ฆฌ๋ทฐ ์‹œ ์ข‹์€ ์ฝ”๋“œ์˜ ๋ฐฉํ–ฅ์„ ์ œ์‹œํ•˜๋˜, ์ฝ”๋“œ ์ˆ˜์ •์„ ๊ฐ•์ œํ•˜์ง€ ๋ง์•„ ์ฃผ์„ธ์š”.
  • Reviewer ๋ถ„๋“ค์€ ์ข‹์€ ์ฝ”๋“œ๋ฅผ ๋ฐœ๊ฒฌํ•œ ๊ฒฝ์šฐ, ์นญ์ฐฌ๊ณผ ๊ฒฉ๋ ค๋ฅผ ์•„๋ผ์ง€ ๋ง์•„ ์ฃผ์„ธ์š”.
  • Review๋Š” ํŠน์ˆ˜ํ•œ ์ผ€์ด์Šค๊ฐ€ ์•„๋‹ˆ๋ฉด Reviewer๋กœ ์ง€์ •๋œ ์‹œ์  ๊ธฐ์ค€์œผ๋กœ 3์ผ ์ด๋‚ด์— ์ง„ํ–‰ํ•ด ์ฃผ์„ธ์š”.
  • Comment ์ž‘์„ฑ ์‹œ Prefix๋กœ P1, P2, P3 ๋ฅผ ์ ์–ด ์ฃผ์‹œ๋ฉด Assignee๊ฐ€ ๋ณด๋‹ค ๋ช…ํ™•ํ•˜๊ฒŒ Comment์— ๋Œ€ํ•ด ๋Œ€์‘ํ•  ์ˆ˜ ์žˆ์–ด์š”
    • P1 : ๊ผญ ๋ฐ˜์˜ํ•ด ์ฃผ์„ธ์š” (Request Changes) - ์ด์Šˆ๊ฐ€ ๋ฐœ์ƒํ•˜๊ฑฐ๋‚˜ ์ทจ์•ฝ์ ์ด ๋ฐœ๊ฒฌ๋˜๋Š” ์ผ€์ด์Šค ๋“ฑ
    • P2 : ๋ฐ˜์˜์„ ์ ๊ทน์ ์œผ๋กœ ๊ณ ๋ คํ•ด ์ฃผ์‹œ๋ฉด ์ข‹์„ ๊ฒƒ ๊ฐ™์•„์š” (Comment)
    • P3 : ์ด๋Ÿฐ ๋ฐฉ๋ฒ•๋„ ์žˆ์„ ๊ฒƒ ๊ฐ™์•„์š”~ ๋“ฑ์˜ ์‚ฌ์†Œํ•œ ์˜๊ฒฌ์ž…๋‹ˆ๋‹ค (Chore)


๐Ÿ“ Assignee๋ฅผ ์œ„ํ•œ CheckList

  • To-Do Item

@23tae 23tae self-assigned this Aug 13, 2024

@GetMapping("/me")
fun getMyProfile(
@AuthenticationPrincipal userDetails: UserDetails
Copy link
Collaborator

Choose a reason for hiding this comment

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

์ œ๊ฐ€ ์ฃผ์ž…ํ•œ 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),
Copy link
Collaborator

Choose a reason for hiding this comment

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

BusinessException์— ErrorCode๋ฅผ ๋„ฃ๋Š” ๊ฒƒ๋ณด๋‹ค BusinessException ๊ฐ์ฒด๋ฅผ ์ƒ์†ํ•œ UserNullException ๊ฐ™์€ ๊ฑธ ๋งŒ๋“ค์–ด ์“ฐ๋Š” ๊ฒƒ ๊ฐ™์Šต๋‹ˆ๋‹ค


@SpringBootApplication class SpringAccountApplication
@SpringBootApplication @EnableCaching class SpringAccountApplication
Copy link
Collaborator

Choose a reason for hiding this comment

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

JVM ์บ์‹ฑ ์‚ฌ์šฉํ•˜์ง€ ์•Š์œผ๋ฉด ์ œ๊ฑฐํ•ด์•ผ ํ•  ๊ฒƒ ๊ฐ™์Šต๋‹ˆ๋‹ค.

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.

2 participants