Refactor: webRTC 도메인 리팩토링 (#223) #227
Merged
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.
📌 개요
WebRTC 시그널링 서버의 효율성, 유연성, 유지보수성을 높이고, 1:1 메시징이 정상 동작하도록 오류를 수정했습니다.
🔨 작업 내용
시그널링 방식 개선 (Broadcast → Unicast)
ICE 서버 설정 외부화
@ConfigurationProperties를 이용해 주입받도록 수정했습니다.컨트롤러 구조 개선
WebRTCSignalingController내의 반복적인 try-catch 구문을@MessageExceptionHandler로 중앙화하고, 인증 정보 추출 로직을WebSocketAuthHelper로 통합하여 코드 중복을 제거하고 가독성을 향상시켰습니다.1:1 메시징 오류 수정
convertAndSendToUser메서드 호출 시 sessionId 대신 username을 사용하도록 수정하여, 메시지가 정상적으로 대상 클라이언트에게 전달되도록 버그를 해결했습니다.WebSocketSessionInfo에 username 필드를 추가하고, 관련 서비스 로직 및 테스트 코드를 모두 수정했습니다.🔗 관련 이슈
Closes #223
📝 참고 사항
WS_TARGET_OFFLINE을 추가했습니다.✅ 체크리스트