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

Multiple Websocket connections #489

Closed
dennislabajo opened this issue Sep 24, 2019 · 5 comments
Closed

Multiple Websocket connections #489

dennislabajo opened this issue Sep 24, 2019 · 5 comments

Comments

@dennislabajo
Copy link

Is there a way or feature I can use to tell how many websocket connections the client has made to the server? I would like to be able to manage these and ensure there should only be one. The reason for the question is because I'm seeing at the server http logs multiple xhr_streaming calls originating from the same client. It does not happen all the time, for the most part, there's only one connection which is good but there are cases where we're seeing multiple connections which we would like to prevent as this could max out server connection resources.

@brycekahle
Copy link
Contributor

One instance of SockJS will only have a single open connection at a time. Is it possible they have multiple tabs open? How are you distinguishing clients from each other?

@dennislabajo
Copy link
Author

Hi Bryce. It is not possible to have multiple tabs. The browser is hard-wired to connect to just one and specific web application and the device is locked-down. There are no users that can directly intervene/open a secondary tab. To distinguish a client from each other, a client has a unique identifier passed as a parameter to the xhr_streaming event that I can key off from the http access logs and count the instances.

@brycekahle
Copy link
Contributor

Do you have logs that you can share to help debug this issue?

@rupebac
Copy link

rupebac commented Nov 29, 2019

I think this may be related with my issue here:
#493

@github-actions
Copy link

github-actions bot commented Aug 3, 2020

This issue has been inactive for 30 days. It will be in closed in 5 days without any new activity.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants