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

[BG-387]: 유저 웹 소켓 연결 커넥션 수 제한 (4h / 2h) #107

Merged
merged 5 commits into from
Aug 30, 2024

Conversation

GGHDMS
Copy link
Member

@GGHDMS GGHDMS commented Aug 29, 2024

Why

분산된 서버 환경에서 커넥션 수를 제한을 구현해야 되서
기존에 생각했던 것 보다 오래 걸렸다

How

워크스페이스 유저의 최대 커넥션 수를 20으로 제한하였다

제한된 커넥션 보다 너 많은 요청시
가장 오래된 커넥션을 찾고
해당 서버에 관련 커넥션이 있으면 redis 와 socket session을 삭제하고
해당 서버에 없으면 redis pub/sub을 사용하여 삭제 요청을 한다

Link

BG-387

@GGHDMS GGHDMS requested a review from Dltmd202 August 29, 2024 09:23
@GGHDMS GGHDMS self-assigned this Aug 29, 2024
Copy link
Member

@Dltmd202 Dltmd202 left a comment

Choose a reason for hiding this comment

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

구욷~

@GGHDMS GGHDMS merged commit 321592d into develop Aug 30, 2024
1 check passed
@GGHDMS GGHDMS deleted the feature/BG-387-ws-connection-limit branch August 30, 2024 07:30
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.

2 participants