Reputation: 2731
I have simple chatroom application and if no users send any messages, the websocket closes after about 10 minutes. What is the best solution to keep the connection alive without reconnecting?
Upvotes: 6
Views: 9719
Reputation: 3029
It is always possible to send pings, the other side will have to reply with pong. (proof)
This tutorial might help you with that.
Upvotes: 3