Skip to content

FIX: 팔로우 알림 id 할당 이슈 조치#215

Merged
Be-HinD merged 1 commit intomainfrom
fix/alarm
Jan 16, 2026
Merged

FIX: 팔로우 알림 id 할당 이슈 조치#215
Be-HinD merged 1 commit intomainfrom
fix/alarm

Conversation

@Be-HinD
Copy link
Member

@Be-HinD Be-HinD commented Jan 16, 2026

📝 Pull Request

📌 PR 종류

해당하는 항목에 체크해주세요.

  • 기능 추가 (Feature)
  • 버그 수정 (Fix)
  • 문서 수정 (Docs)
  • 코드 리팩터링 (Refactor)
  • 테스트 추가 (Test)
  • 기타 변경 (Chore)

✨ 변경 내용

팔로우 알림 전송 시 알림 ID 할당이 안되는 문제 조치.
flush()통한 DB insert 시점 명시


🔍 관련 이슈


🧪 테스트

변경된 기능에 대한 테스트 범위 또는 테스트 결과를 작성해주세요.

  • 유닛 테스트 추가 / 수정
  • 통합 테스트 검증
  • 수동 테스트 완료

🚨 확인해야 할 사항 (Checklist)

PR을 제출하기 전에 아래 항목들을 확인해주세요.

  • 코드 포매팅 완료
  • 불필요한 파일/코드 제거
  • 로직 검증 완료
  • 프로젝트 빌드 성공
  • 린트/정적 분석 통과 (해당 시)

🙋 기타 참고 사항

리뷰어가 참고하면 좋을 만한 추가 설명이 있다면 적어주세요.

Summary by CodeRabbit

릴리스 노트

  • 버그 수정
    • 팔로우 알림이 더 안정적으로 전송되도록 개선했습니다. 알림이 정상적으로 동기화된 후 사용자에게 전달되도록 수정했습니다.

✏️ Tip: You can customize this high-level summary in your review settings.

@Be-HinD Be-HinD self-assigned this Jan 16, 2026
@Be-HinD Be-HinD added the 🐞bug Something isn't working label Jan 16, 2026
@coderabbitai
Copy link

coderabbitai bot commented Jan 16, 2026

Walkthrough

NotificationDispatcher의 dispatch 메서드들에서 트랜잭션 전파 전략을 REQUIRES_NEW로 변경하고, 팔로우 알림 저장 후 명시적 flush() 호출을 추가하여 SSE 이전에 데이터 동기화를 강제합니다.

Changes

결합 / 파일 변경 요약
트랜잭션 경계 및 동기화 개선
src/main/java/team/wego/wegobackend/notification/application/dispatcher/NotificationDispatcher.java
세 개의 dispatch 메서드 오버로드에서 @Transactional의 propagation 속성을 Propagation.REQUIRES_NEW로 변경하여 각 dispatch 호출이 독립적인 트랜잭션에서 실행되도록 수정. 팔로우 알림 저장 후 notificationRepository.flush() 추가하여 SSE 이전에 데이터베이스 동기화 보장.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8분

Possibly related PRs

Poem

🐰 트랜잭션 경계를 명확히 하여
각 dispatch가 독립적으로 뛸 수 있게,
flush()로 데이터를 서둘러 저장하니
SSE 알림이 시간 맞춰 날아오네!
깔끔한 동기화, 완벽하게! ✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed PR 제목이 변경사항의 주요 목적(팔로우 알림 ID 할당 이슈 수정)을 명확하게 요약하고 있으며, 실제 코드 변경과 일치합니다.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@Be-HinD Be-HinD merged commit 96f22b0 into main Jan 16, 2026
1 check passed
@Be-HinD Be-HinD deleted the fix/alarm branch January 16, 2026 13:39
@github-project-automation github-project-automation bot moved this from Backlog to Done in WeGo-Together Backend Jan 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🐞bug Something isn't working

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant