-
Notifications
You must be signed in to change notification settings - Fork 4
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
refactor: 알림 Entity 구조 변경 #42
Open
junest66
wants to merge
50
commits into
CHZZK-Study:develop
Choose a base branch
from
junest66:feat/refactor-notification
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
refactor: 알림 Entity 구조 변경 #42
junest66
wants to merge
50
commits into
CHZZK-Study:develop
from
junest66:feat/refactor-notification
+648
−215
Conversation
This file contains 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
(#94)
- AuctionRegistrationCanceledNotification -> PreRegistrationCanceledNotification 로 변경 (#94)
(#94)
(#94)
viaunixue
approved these changes
Sep 13, 2024
YeaChan05
reviewed
Sep 20, 2024
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.
#️⃣연관된 이슈
CHZZ-94 #done
📝작업 내용
abstract Notification createNotification
추상 메서드를 둬서, 알림 타입을 추가할때 해당 알림 객체를 만드는 메서드를 추가하는 것을 강제하였습니다.NotifactionEvent
,NotificationRealMessage
,NotificationSseResponse
를 모두 바꿔야하는 문제가 있었으나, 공통된 필드는 냅두고, 알림 타입마다 다른 필드는Map<String, Object> additionalFields
에 추가하는 방식으로 변경하였습니다. -> 이를 통해 새로운 알림타입을 만들때 해당 NotifcationType에만 추가하면 됩니다.@JsonAnyGetter
를 통해 추가적인 필드가 포함된Map
데이터를 개별 JSON 필드로 변환하여 동적으로 처리할 수 있습니다.(ex:
notification.acutionId
) 싱글테이블 전략을 사용함으로써 데이터베이스에는 해당 컬럼이 존재하므로PathBuilder
를 통해 조회합니다.✅테스트 결과
1. 판매자 낙찰/ 유찰 알림
2. 미낙찰자 알림
3. 낙찰자 알림/ 경매시작 알림 / 사전경매 취소 알림
🙏리뷰 요구사항(선택)