Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Add receive timeout to UDP AniDBSocketHandler #1121

Open
LordFlashmeow opened this issue Apr 24, 2024 · 3 comments
Open

Feature request: Add receive timeout to UDP AniDBSocketHandler #1121

LordFlashmeow opened this issue Apr 24, 2024 · 3 comments

Comments

@LordFlashmeow
Copy link
Contributor

LordFlashmeow commented Apr 24, 2024

VERSION INFORMATION

Server Version:
Daily

DESCRIPTION

_aniDBSocket.ReceiveFromAsync can hang on network disconnect, blocking the UDP worker. Attempting to ctrl-c the server is ineffective, because the logout process tries to send a UDP logout message (which gets blocked behind the frozen socket).

var receivedResult = await _aniDBSocket.ReceiveFromAsync(result, SocketFlags.None, temp);

@LordFlashmeow
Copy link
Contributor Author

#1122 implements the timeouts, which seems to fix the issue when a connection is dropped (or the server wakes up from sleep). However, 598 UNKNOWN COMMAND responses show up instead, but at least the server is ctrl-cable now.

@ElementalCrisis
Copy link
Member

@fearnlj01, tagged you since you made the initial fix, is this something we can also address?

@da3dsoul
Copy link
Member

da3dsoul commented May 3, 2024

I know how to fix it, theoretically. I just need time

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants