You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have been using this library for a few years now, but recently we have started observing strange behavior. On our AWS setup of two EC2 instances running under Elastic Beanstalk behind Amazon Load Balancer we noticed that one of the two servers has a lot of open connections. We can see that almost at all times there are 2 thousand connections and occasionally (last week we are observing this once a day) we run up to 11 thousand connections which takes up to 100% CPU and therefore makes our backend on that server irresponsive.
We can't see any obvious reason of what might be causing this and we were curious if we could get a push in the right direction over here.
We are using Restify server and we measure the connection count as Object.keys(this.socketSet):
server.js
const restify = require('restify');
const { SocketServer } = require('./socketServer');
const socketEventListener = require('./socketEventListener'); // Note: not sure if I should elaborate this one
async function listening ({ SocketEventDispatcher }) { // Note: not sure if I should elaborate this one either
const server = restify.createServer();
...
const socketServer = new SocketServer(server, { transports: ['polling'] });
server.socketEventDispatcher = new SocketEventDispatcher(socketServer);
socketEventListener.listening({ server });
...
}
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
Hello good people of Engine.io.
We have been using this library for a few years now, but recently we have started observing strange behavior. On our AWS setup of two EC2 instances running under Elastic Beanstalk behind Amazon Load Balancer we noticed that one of the two servers has a lot of open connections. We can see that almost at all times there are 2 thousand connections and occasionally (last week we are observing this once a day) we run up to 11 thousand connections which takes up to 100% CPU and therefore makes our backend on that server irresponsive.
We can't see any obvious reason of what might be causing this and we were curious if we could get a push in the right direction over here.
We are using Restify server and we measure the connection count as
Object.keys(this.socketSet)
:server.js
socketServer.js
Beta Was this translation helpful? Give feedback.
All reactions