Server disconnection
Lu par 123 utilisateurs
Hi, in the Vint.ee solution, there is a websocket connection between the client (browser) and the server. I have also seen a case where the connection to the server is lost but the client (browser) does not understand this. As one solution, I could have the client ping the server if no message has come from the server for more than 15 seconds, then the browser could be refreshed. If it turns out that such pinging would significantly increase the server load, then one possibility would be to make such a solution for VIP users. And of course, such pinging would only occur when the user is playing.
Done, It works for everyone at the moment, I'm investigating how much load the server actually has. Solution: If no message has been received from the server within 15 seconds, the server is pinged. If there is no ping response within 5 seconds, the user is notified that the connection has been lost. So the user will be notified of the connection loss no later than 20 seconds later. Is that enough?
I changed the settings so that the server is pinged after 12 seconds and the ping response is waited for 3 seconds.