-
Notifications
You must be signed in to change notification settings - Fork 1
[Feat] 프로필 수정 기능 제거 및 회원정보 등록 API에서 리프레시 토큰을 반환하도록 수정 #160
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
Conversation
- BREAKING CHANGE : 프로필 수정 API를 삭제. 프론트에서는 프로필 수정 기능을 제거해야함
- BREAKING CHANGE : 응답에서 profileImage 필드를 삭제. 프론트에서 수정 필요
- 생성자의 인자에서 프로필 이미지를 제거
- 불필요한 모킹을 제거
- BREAKING CHANGE : 요청에서 profileImageFile과 defaultProfileImageName 제거. 프론트 수정 필요.
- BREAKING CHANGE : 프론트 수정 필요
- 필요한 모킹을 추가
- 필요한 모킹 수정 - 리프레시 토큰 반환 여부 검증 추가
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Walkthrough토큰 재발급 API와 Redis 기반 리프레시 토큰 관리를 구현하고, 프로필 이미지 기능을 제거하며, 보호 보고서의 S3 조회 및 createdAt 필드를 추가하고, 인증 서비스를 리팩토링합니다. Changes
Sequence Diagram(s)sequenceDiagram
participant Client
participant AuthController
participant AuthServiceFacade
participant ReissueTokenService
participant JwtUtil
participant RedisRefreshTokenRepository
participant UserRepository
rect rgb(200, 220, 230)
note over Client,UserRepository: Token Reissue Flow
Client->>AuthController: POST /reissue/token<br/>(ReissueTokenRequest)
AuthController->>AuthServiceFacade: reissueToken(request)
AuthServiceFacade->>ReissueTokenService: reissueToken(request)
ReissueTokenService->>JwtUtil: extractUserId(refreshToken)
JwtUtil-->>ReissueTokenService: userId
ReissueTokenService->>RedisRefreshTokenRepository: findByUserId(userId)
RedisRefreshTokenRepository-->>ReissueTokenService: Optional<storedToken>
alt Token Valid & Stored
ReissueTokenService->>UserRepository: findById(userId)
UserRepository-->>ReissueTokenService: User
ReissueTokenService->>JwtUtil: createAccessJwt(userId, role)
JwtUtil-->>ReissueTokenService: newAccessToken
ReissueTokenService->>JwtUtil: createRefreshJwt(userId)
JwtUtil-->>ReissueTokenService: newRefreshToken
ReissueTokenService->>RedisRefreshTokenRepository: save(userId, newRefreshToken)
ReissueTokenService-->>AuthServiceFacade: ReissueTokenResponse
AuthServiceFacade-->>AuthController: ReissueTokenResponse
AuthController-->>Client: 200 OK<br/>(accessToken, refreshToken)
else Token Expired/Invalid
ReissueTokenService-->>AuthController: CustomException(EXPIRED_JWT)
AuthController-->>Client: 401 Unauthorized
else Token Not Matched
ReissueTokenService-->>AuthController: CustomException(REFRESH_TOKEN_NOT_FOUND)
AuthController-->>Client: 404 Not Found
end
end
sequenceDiagram
participant Client
participant ReportController
participant ProtectingReportRetrieveWithS3ServiceImpl
participant ProtectingReportRepository
participant RestTemplate
participant ImageUploader
participant ProtectingReportDetailStrategy
rect rgb(230, 220, 200)
note over Client,ProtectingReportDetailStrategy: Random Protecting Reports with S3 Retrieval
Client->>ReportController: GET /api/v2/reports/protecting-reports/random-s3?count=X
ReportController->>ProtectingReportRetrieveWithS3ServiceImpl: getRandomProtectingReportsWithS3(count)
ProtectingReportRetrieveWithS3ServiceImpl->>ProtectingReportRepository: findByDate(yesterday)
ProtectingReportRepository-->>ProtectingReportRetrieveWithS3ServiceImpl: List<ProtectingReport>
loop For each report (up to count)
loop For each image URL
ProtectingReportRetrieveWithS3ServiceImpl->>RestTemplate: getForObject(originalImageUrl)
RestTemplate-->>ProtectingReportRetrieveWithS3ServiceImpl: byte[] imageContent
alt Image Download Success
ProtectingReportRetrieveWithS3ServiceImpl->>ImageUploader: upload(bytes, filename, contentType)
ImageUploader-->>ProtectingReportRetrieveWithS3ServiceImpl: s3Url
else Image Download Failed
ProtectingReportRetrieveWithS3ServiceImpl->>ProtectingReportRetrieveWithS3ServiceImpl: log error & skip
end
end
ProtectingReportRetrieveWithS3ServiceImpl->>ProtectingReportDetailStrategy: toDetailDto(report, s3Urls, false)
ProtectingReportDetailStrategy-->>ProtectingReportRetrieveWithS3ServiceImpl: ProtectingReportDetailResponseDTO
end
ProtectingReportRetrieveWithS3ServiceImpl-->>ReportController: List<ProtectingReportDetailResponseDTO>
alt Results Not Empty
ReportController-->>Client: 200 OK<br/>(BaseResponse<List<DTO>>)
else Results Empty
ReportController-->>Client: 204 No Content
end
end
Estimated code review effort🎯 5 (Critical) | ⏱️ ~90+ minutes Possibly related issues
Possibly related PRs
Suggested reviewers
Pre-merge checks and finishing touches❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Test Results372 tests 372 ✅ 56s ⏱️ Results for commit 0fbf3b8. ♻️ This comment has been updated with latest results. |
📊 JaCoCo Coverage
|
7d4fbe1 to
fab1d9e
Compare
ksg1227
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
확인했습니당
Related issue 🛠
Work Description 📝
Screenshot 📸
Uncompleted Tasks 😅
To Reviewers 📢
Summary by CodeRabbit
릴리스 노트
새로운 기능
기능 제거
✏️ Tip: You can customize this high-level summary in your review settings.