After deploying more than 1 replica set for my server, websocket stopped working.
Anything I can check about it? Issues or discussions?
7 Replies
Project ID:
1c75cd96-f9af-4552-afd9-e563c1c8a532
1c75cd96-f9af-4552-afd9-e563c1c8a532
i cant reproduce this issue, can you give us more information
It's weird.. I've been using 1 replica set since forever.
Yesterday I changed to deploy 10 replica sets of our server... The only thing that didn't work and fails to connect is our websocket
we are going to need more specifics than "WebSocket fails to connect"
since i cant reproduce this myself, i need all the information i can get from you
Got it
Looks like if we use socket.io with multiple replica sets we gotta define the sessionAffinity as ClientIP..
If you plan to distribute the load of connections among different processes or machines, you have to make sure that all requests associated with a particular session ID reach the process that originated them.
It's what socket.io calls: Sticky load balancing
ah yeah you are using socket.io, that would have been very good information to know