3 years ago
Hi, I have a project with node.js,
and I use ws
as the socket library. The socket connection closes after 10 minutes, even if messages are sent back and forward between the client and the server. I think the problem is not related to my code because when I run the server locally, I do not get the socket disconnected error, and the error code is 1006.
Is there any socket connection duration limit in the default configuration for the free tier?
0 Replies
3 years ago
3 years ago
oof
3 years ago
When you proxy requests at Railway scale, keep alive connections have to be killed.
3 years ago
yes
3 years ago
Our guess, could be wrong is that if you are hosting a realtime application, it's likely its a serious usecase. Hence, most people who need it would likely be using a domain.
3 years ago
We have a fix on the way, but it will be a long time till we get to it.
3 years ago
Yes, so the other thing you need to do is -> send some keepalive traffic on your websocket every 10-30 secs (socketio does this with websocket pings by default) so that you don't hit any TCP idle timeouts.
3 years ago
You are likely hitting timeouts
3 years ago
Not great then, will talk to our engineer on that once they are awake.
3 years ago
What are you trying to host on here?
3 years ago
Personal project? Very commerical mission critical workload?
3 years ago
This will help me determine the priority.
3 years ago
gtocha
3 years ago
cool: project id?
a month ago
@antoniobelluci if your websockets are disconnecting see this thread https://discord.com/channels/713503345364697088/1385626689802997906
team is aware