[fix/48-room-roulette-filter] - 실시간 동기화 안정화(필터 무한 루프 및 방 퇴장 로직 수정)#49
Merged
Parkchanyoung0710 merged 1 commit intodevelopfrom Feb 12, 2026
Merged
Conversation
📝 Walkthrough워크스루채팅 게이트웨이에서 방 입장(joinRoom) 로직을 강화하고 새로운 방 퇴장(leaveRoom) 핸들러를 추가했습니다. 중복 입장 방지, 역할 할당 이벤트 흐름, 방 상태 정리, 호스트 재할당 로직이 개선되었으며, 메시지 브로드캐스트 범위와 타임스탬프 처리도 업데이트되었습니다. 변경사항
시퀀스 다이어그램sequenceDiagram
participant Client as 클라이언트
participant Gateway as ChatGateway
participant Room as 방 상태
participant Others as 다른 멤버들
rect rgba(100, 200, 150, 0.5)
Note over Client,Others: 방 입장 흐름
Client->>Gateway: joinRoom(roomCode)
Gateway->>Room: 중복 입장 확인
alt 이미 입장함
Gateway-->>Client: 중복 입장 방지
else 신규 입장
Gateway->>Room: 방 상태 초기화 (필요시)
Gateway->>Gateway: 호스트/게스트 역할 결정
Gateway-->>Client: roleAssigned (역할, 메뉴)
Gateway->>Others: systemMessage (입장 공지)
Gateway->>Others: userJoined (사용자 정보)
end
end
rect rgba(150, 150, 200, 0.5)
Note over Client,Others: 방 퇴장 흐름
Client->>Gateway: leaveRoom(roomCode)
Gateway->>Room: 멤버십 검증
Gateway->>Others: systemMessage (퇴장 공지)
Gateway->>Others: userLeft (사용자 정보)
Gateway->>Room: 클라이언트 방에서 제거
alt 방이 비어있음
Gateway->>Room: 방 상태 정리
else 멤버 남아있음
Gateway->>Room: 첫 남은 멤버를 호스트로 재할당
Gateway->>Room: roleAssigned 알림
end
end
예상 코드 리뷰 노력🎯 3 (보통) | ⏱️ ~25분 시Tip Issue Planner is now in beta. Read the docs and try it out! Share your feedback on Discord. Note 🎁 Summarized by CodeRabbit FreeYour organization is on the Free plan. CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please upgrade your subscription to CodeRabbit Pro by visiting https://app.coderabbit.ai/login. Comment |
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
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.
🛠 변경된 내용
🚀 결과
Summary by CodeRabbit
새로운 기능
버그 수정
리팩토링