-
Notifications
You must be signed in to change notification settings - Fork 1
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
SocketTimeoutException
s from WebSockets connections isn't handled
#302
Comments
From what I reproduced, it was actually working and wrapping in a |
Indeed. Though it's interesting that |
Yup, it should be something like that. I'll investigate tomorrow. |
From what I can tell it's being handled at the Flow level. Any steps to reproduce this issue? I haven't been able to. I also noticed that the PDC interface is outdated. These throws come from inside the Flow, not from the method call: https://github.com/relaycorp/awala-jvm/blob/bb426493379c605eec0a0c628f8c1dab82f5f6ad/src/main/kotlin/tech/relaycorp/relaynet/bindings/pdc/PDCClient.kt#L54 |
Handled at the flow level by whom? Not even disconnecting the router from the Internet did the trick? I haven't experienced this myself. @mgulyaev10, any idea on how to reproduce this? I suspect it may be intermittent and happen rarely.
Thanks! Fixed in relaycorp/awala-jvm#300 |
That only triggered a wrapped |
Looks like KTOR as an history of uncatchable exceptions that don't reference the app source code. Here's at least once that mentions SocketTimeoutException, although with a different stacktrace: https://youtrack.jetbrains.com/issue/KTOR-577/java.net.SocketTimeoutException-with-no-lines-referencing-my-code Since our stacktraces also don't mention our own source code, we might not be able to handle the exception regularly. Maybe we can fix the underlying issue causing the timeout, which might not be possible. Other solutions look to be pretty last resort like |
Thanks for looking into this @sdsantos! That doesn't look good :( I guess even if we wanted to use |
At least with |
That's a bit better then, but I'd be concerned with the code complexity to restart/end the WebSocket connection when that happens. Since this has only happened once in Letro in the past 90 days, let's put a pin on this for now and revisit if it happens more often. Hopefully that'll buy enough time until Jet Brains fix this. |
The following doesn't appear to have any effect (
SocketTimeoutException
is a subclass ofIOException
):awala-poweb-jvm/src/main/kotlin/tech/relaycorp/poweb/PoWebClient.kt
Lines 325 to 327 in 380529f
Because Letro is crashing when the connection to the Awala server stops responding to pings:
The text was updated successfully, but these errors were encountered: