I'm not sure if this is a setting somewhere that I've missed or an actual issue with Node.js.
Anyhow, my problem is that I want to run a script that handles web socket connections. I can get the script running as a service and it handles the connections as it should. After being idle for a while (ie. not receiving or sending any data; I'm still connected from the client, but I'm doing something else, like checking my gmail for a while in another window) the script shuts down. It does respawn as it should since I told it to in my .conf, but that doesn't matter since the clients already have been disconnected.
So the question is this: is there a way to make sure that the script keeps running even when the clients are idle? Maybe it's a setting on the ubuntu server?
Tech:
Running on a Ubuntu Server 10.04 on Slicehost
I'm using Node v0.5.0开发者_Python百科-pre and the websocket-server module
socket.setTimeout(0) ?
精彩评论