-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
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
h2/h3, things around POST, slow network simulation #11756
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Is this related to #11342 (review) |
This is part of the hunt for this issue, unsuccessful so far, but discovering other edge paths. |
icing
changed the title
h2/h3, things around POST
h2/h3, things around POST, slow network simulation
Aug 31, 2023
- added test cases for various code paths - fixed handling of blocked write when stream had been closed inbetween attempts - re-enabled DEBUGASSERT on send with smaller data size
…tely sent and acked. - transfer loop: treat keepon SEND without RECV the same when the connection is marked for close as for stream based transfers - ngtcp2|quiche: clear HOLD flag on transfer when stream is closed - ngtcp2|quiche: skip DATA_IDLE handling for transfers without an open stream
- servers may send a response without reading the full request body, e.g. when sending 30x or 40x responses - transfer loop might be sending when the stream switches to closed. Failing the send then leads to transfer failure which is not appropriate as the response is no longer evaluated then. - add code to silently discard request body data in such cases
- in debug builds, environment variables can be set to simulate a slow network when sending data. cf-socket.c and vquic.c support * CURL_DBG_SOCK_WBLOCK: percentage of send() calls that should be answered with a EAGAIN. TCP/UNIX sockets. This is chosen randomly. * CURL_DBG_SOCK_WPARTIAL: percentage of data that shall be written to the network. TCP/UNIX sockets. Example: 80 means a send with 1000 bytes would only send 800 This is applied to every send. * CURL_DBG_QUIC_WBLOCK: percentage of send() calls that should be answered with EAGAIN. QUIC only. This is chosen randomly. - Fixes in http2.c and cf-h2-proxy.c to make test cases pass - tests: some tests are skipped when the env vars are set, because they would time out just because of the amount of requests/data - multi.c: on debug, print the state a transfer was in when it switched to done, e.g. was ended/aborted.
- http2 RST FRAME traces now also the error code - http2 RST with error 0 does NOT indicate a failed transfer
bagder
approved these changes
Sep 4, 2023
ptitSeb
pushed a commit
to wasix-org/curl
that referenced
this pull request
Sep 25, 2023
- added test cases for various code paths - fixed handling of blocked write when stream had been closed inbetween attempts - re-enabled DEBUGASSERT on send with smaller data size - in debug builds, environment variables can be set to simulate a slow network when sending data. cf-socket.c and vquic.c support * CURL_DBG_SOCK_WBLOCK: percentage of send() calls that should be answered with a EAGAIN. TCP/UNIX sockets. This is chosen randomly. * CURL_DBG_SOCK_WPARTIAL: percentage of data that shall be written to the network. TCP/UNIX sockets. Example: 80 means a send with 1000 bytes would only send 800 This is applied to every send. * CURL_DBG_QUIC_WBLOCK: percentage of send() calls that should be answered with EAGAIN. QUIC only. This is chosen randomly. Closes curl#11756
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
slow network simulation, fixes
in debug builds, environment variables can be set to simulate a slow
network when sending data. cf-socket.c and vquic.c support
answered with a EAGAIN. TCP/UNIX sockets.
This is chosen randomly.
to the network. TCP/UNIX sockets.
Example: 80 means a send with 1000 bytes would only send 800
This is applied to every send.
answered with EAGAIN. QUIC only.
This is chosen randomly.
Fixes in http2.c and cf-h2-proxy.c to make test cases pass
tests: some tests are skipped when the env vars are set, because
they would time out just because of the amount of requests/data
multi.c: on debug, print the state a transfer was in when it
switched to done, e.g. was ended/aborted.