Skip to content

[DPMBE-101] 알림이 필요한 이벤트일때 FCM 메세지를 발송한다 #185

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 11 commits into from
Jul 11, 2023

Conversation

kdomo
Copy link
Member

@kdomo kdomo commented Jul 10, 2023

개요

작업사항

각 이벤트에 FCM을 발송하고, 알립 탭에서 조회하기 위한 notification 테이블에 데이터 적재

이벤트 목록

  • 이미지를 올렸을 때 지각여부에 따라 지각한 친구의 사진 도착, 도착한 친구들의 사진 도착 전송
  • 위치 공유 시작할 때 위치 공유 시작! 전송
  • TIMEOVER 되었을 때 지각여부에 따라 친구들에게 용서를 비는 사진을 보내봐!, 친구들에게 재촉하는 사진을 보내 전송
  • Interaction 전송 시 이모지 투척! 전송
  • 위취 공유 종료될 때 위치 공유 종료! 전송
  • interaction 100개 달성 시 이모지 100개 달성! 전송
  • 만남이벤트(서현님 개발 완료되면 이슈열어서 추가하겠습니다)

이번 PR에서 적재한 알림 데이터는 다음 PR에서 하이라이트와 함께 조회하는 기능 추가하겠습니닷

@kdomo kdomo self-assigned this Jul 10, 2023
@kdomo kdomo marked this pull request as ready for review July 11, 2023 07:07
@kdomo kdomo requested review from ImNM and BlackBean99 as code owners July 11, 2023 07:07
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 1 Code Smell

15.7% 15.7% Coverage
0.0% 0.0% Duplication

val logger: KLogger = KotlinLogging.logger {}

@Async
@Transactional(propagation = Propagation.REQUIRES_NEW)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Transaction을 handler 에 넣어주셨군용

)

// notification 저장
val targetUserIds = users.map { user -> user.id!! }.toSet()
Copy link
Collaborator

Choose a reason for hiding this comment

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

유니크 고를때 그냥 Set 으로 해도 되겠네요ㅋㅋ

Copy link
Member Author

Choose a reason for hiding this comment

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

오 ㅋㅋㅋㅋ
kotlin에 .distinct 가 내부적으로 뮤터블셋을만든후에 List를 반환하네용?

.build()
FirebaseMessaging.getInstance().send(message)
return FirebaseMessaging.getInstance().sendAsync(message)
Copy link
Collaborator

Choose a reason for hiding this comment

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

으음 슬랙이랑 구조가 똑같네요

Copy link
Member

@ImNM ImNM left a comment

Choose a reason for hiding this comment

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

굿입니다요!!!

@kdomo kdomo merged commit 8659135 into develop Jul 11, 2023
@kdomo kdomo deleted the feature/DPMBE-101 branch July 11, 2023 15:20
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.

[DPMBE-101] 알림이 필요한 이벤트일때 FCM 메세지를 발송한다
3 participants