-
Notifications
You must be signed in to change notification settings - Fork 0
SCRUM-122 예약 내역에 수정이 생기면 알림이 발송 된다 #7
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
Merged
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| package com.wellmeet.config; | ||
|
|
||
| import java.security.GeneralSecurityException; | ||
| import java.security.Security; | ||
| import lombok.RequiredArgsConstructor; | ||
| import nl.martijndwars.webpush.PushService; | ||
| import org.bouncycastle.jce.provider.BouncyCastleProvider; | ||
| import org.springframework.context.annotation.Bean; | ||
| import org.springframework.context.annotation.Configuration; | ||
| import org.springframework.context.annotation.Profile; | ||
|
|
||
| @Configuration | ||
| @Profile("!test") | ||
| @RequiredArgsConstructor | ||
| public class WebPushConfig { | ||
|
|
||
| private final VapidConfig vapidConfig; | ||
|
|
||
| @Bean | ||
| public PushService pushService() throws GeneralSecurityException { | ||
| Security.addProvider(new BouncyCastleProvider()); | ||
| PushService pushService = new PushService(); | ||
| pushService.setPublicKey(vapidConfig.getPublicKey()); | ||
| pushService.setPrivateKey(vapidConfig.getPrivateKey()); | ||
| pushService.setSubject(vapidConfig.getSubject()); | ||
| return pushService; | ||
| } | ||
| } |
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
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
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
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
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
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
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
3 changes: 3 additions & 0 deletions
3
src/test/java/com/wellmeet/WellmeetNotificationApplicationTests.java
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| package com.wellmeet.config; | ||
|
|
||
| import static org.mockito.Mockito.mock; | ||
|
|
||
| import nl.martijndwars.webpush.PushService; | ||
| import org.springframework.boot.test.context.TestConfiguration; | ||
| import org.springframework.context.annotation.Bean; | ||
| import org.springframework.context.annotation.Primary; | ||
|
|
||
| @TestConfiguration | ||
| public class WebPushTestConfig { | ||
|
|
||
| @Bean | ||
| @Primary | ||
| public PushService pushService() { | ||
| return mock(PushService.class); | ||
| } | ||
| } |
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.
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.
🧩 Analysis chain
예약 생명주기를 위한 알림 타입 추가가 적절합니다.
새로운 알림 타입들(RESERVATION_CONFIRMED, RESERVATION_UPDATED, RESERVATION_CANCELED)이 PR 목표와 일치하며, 네이밍 컨벤션도 올바르게 적용되었습니다.
다만 코드베이스 전체에서 이 새로운 알림 타입들을 올바르게 처리하는지 확인해 주세요. 특히 알림 소비자(consumer)와 생성자(producer) 쪽에서 모든 타입에 대한 처리 로직이 구현되어 있는지 검증이 필요합니다.
다음 스크립트를 실행하여 새로운 알림 타입의 사용처를 확인하세요:
🏁 Script executed:
Length of output: 1885
새 알림 타입에 대한 핸들링 로직 구현 필요
새로 추가된 RESERVATION_CONFIRMED, RESERVATION_UPDATED, RESERVATION_CANCELED 타입이 enum에만 정의되어 있으며, 알림 소비자·생성자 코드에서 해당 타입을 처리하는 분기나 핸들러가 없습니다. 각 이벤트에 맞춰 알림 발송·수신 로직을 구현해주세요.