OSDN Git Service

[shogi-server] Improve timed-up detection.
authorDaigo Moriwaki <beatles@sgtpepper.net>
Sun, 4 Oct 2020 02:16:49 +0000 (11:16 +0900)
committerDaigo Moriwaki <beatles@sgtpepper.net>
Sun, 4 Oct 2020 02:16:49 +0000 (11:16 +0900)
commit8d5884aa82cc5b0b31ca115cfea891ba37ad6fe3
treea8a0339caca451521ea16cbe17c618264383fbe5
parentc6ab4e68a7c76b1f8032f2310ed1c2a3af73383c
[shogi-server] Improve timed-up detection.

Previously, the server checked if a game got timed up when a player
in turn sent no message for a certain amount of time mainly defined
by Default_Timeout. If the player sent keep alive frequently, the
timed-up detection could be quite delayed.
This issue has been addressed. The server now checks timed up with
keep alive received as well. Players are notified with TIME_UP not
long before games gets timed up.
changelog
shogi_server/command.rb