-
-
Notifications
You must be signed in to change notification settings - Fork 348
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
Handling TCP connection errors #2829
Labels
Comments
This was referenced Jun 23, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
There is an ongoing issue with the apparent lack of response when HTTP connections fail, such as with invalid URLs (issue #1937).
PR #1939 was a simple attempt to address this problem, but I'm closing that because this issue requires scoping out properly first and applies to all types of TCP connections, not just HTTP.
When a HTTP request is issued a
completed
delgate is supplied, which receives a booleansuccessful
parameter. This parameter is false if HTTP parsing fails or the remote connection returns an HTTP error code.If, when sending the request, a failure occurs in the connection process then the callback is never invoked. This can happen if:
And probabaly others. Issues are:
DEBUG_VERBOSE_LEVEL=3
and observing outputMy feeling is that invoking the HttpRequest completion callback is not the correct approach here since a failure (
successful=false
) should only relate to the response from the remote server. Here, the request hasn't actually completed and is still in the queue.This suggests that a new API for catching such errors would be useful for an application.
We'd need to:
The text was updated successfully, but these errors were encountered: