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: FCM 토큰 저장 API 구현 #298

Merged
merged 11 commits into from
Oct 17, 2024
Merged

Conversation

leeeeeyeon
Copy link
Collaborator

@leeeeeyeon leeeeeyeon commented Oct 17, 2024

🛰️ Issue Number

#280

🪐 작업 내용

  • 클라이언트로부터 기기 정보와 FCM 토큰을 받아 DB에 저장하는 API를 구현했습니다.
    • request에 있는 기기 정보에 해당하는 Device 엔티티가 없을 경우, 새로운 Device 엔티티를 저장합니다.
    • request에 있는 기기 정보에 해당하는 Device 엔티티가 존재하는 경우
      • member가 다르다면 Device 엔티티의 member를 업데이트 (여러 유저가 하나의 기기를 동시에 사용하는 것은 물리적으로 불가능)
      • fcmToken이 다르다면 Device 엔티티의 fcmToken를 업데이트 (앱 데이터 삭제, FCM Token 만료 등에 대비)
  • 회원 탈퇴 시 해당 유저를 member로 가지고 있는 Device 엔티티를 모두 hard delete하도록 회원탈퇴 API에 로직을 추가했습니다.

📚 Reference

✅ Check List

  • DB 스키마가 일치하는지 확인했나요?
  • SonarLint를 반영하여 코드를 수정했나요?
  • merge할 브랜치의 위치를 확인했나요?
  • Label을 지정했나요?

@leeeeeyeon leeeeeyeon added the 🎁 feature New feature or request label Oct 17, 2024
@leeeeeyeon leeeeeyeon self-assigned this Oct 17, 2024
@leeeeeyeon
Copy link
Collaborator Author

Overall Project 42.75% -0.31%
Files changed 91.43% 🍏

File Coverage
MemberWriter.java 100% 🍏
DeviceWriter.java 100% 🍏
DeviceReader.java 100% 🍏
MemberController.java 100% 🍏
Device.java 100% 🍏
Platform.java 100% 🍏
AuthService.java 59.59% -7.77%
MemberService.java 46.83% 🍏
MemberReader.java 44.44% 🍏

@leeeeeyeon
Copy link
Collaborator Author

Overall Project 41.98% -0.85%
Files changed 79.21%

File Coverage
MemberWriter.java 100% 🍏
DeviceWriter.java 100% 🍏
DeviceReader.java 100% 🍏
MemberController.java 100% 🍏
Device.java 100% 🍏
Platform.java 100% 🍏
AuthService.java 59.59% -7.77%
MemberService.java 46.83% 🍏
MemberReader.java 44.44% 🍏
SlackService.java 16.95% 🍏
SlackAspect.java 0% 🍏
FCMNotificationAspect.java 0%

Copy link

@leeeeeyeon
Copy link
Collaborator Author

Overall Project 41.98% -0.85%
Files changed 79.21%

File Coverage
MemberWriter.java 100% 🍏
DeviceWriter.java 100% 🍏
DeviceReader.java 100% 🍏
MemberController.java 100% 🍏
Device.java 100% 🍏
Platform.java 100% 🍏
AuthService.java 59.59% -7.77%
MemberService.java 46.83% 🍏
MemberReader.java 44.44% 🍏
SlackService.java 16.95% 🍏
SlackAspect.java 0% 🍏
FCMNotificationAspect.java 0%

@leeeeeyeon leeeeeyeon merged commit af415df into develop Oct 17, 2024
2 checks passed
@leeeeeyeon leeeeeyeon deleted the feature/fcm-token-issue branch October 17, 2024 03:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🎁 feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant