-
-
Notifications
You must be signed in to change notification settings - Fork 199
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
Issue 361 - Improve http2 connection error handling #363
Issue 361 - Improve http2 connection error handling #363
Conversation
- Partial fix for hatoo#361 - ONLY implemented for the `-z 10s` (work_until) case - TODO: - [ ] The futures are not aborted when the timer is hit, which will cause long running requests to delay the program exit - this is only due to a borrow/move problem that I cannot figure out - [ ] Implement for the non-`work_until` cases - [ ] Add a timeout to the TCP socket setup - this appears to be where some of the delay on shutdown is happening if the server closes after startup - [ ] Consider adding a delay to the reconnect loop so that it will not try to connect more than 1 time per second per concurrent connection - Without this the connect loop will spin at ~23k connect attempts/second for `-c 20`, for example - Test cases: - Start with the server not running at all (never connects) - Currently this will exit on time - IMPROVED: Previously this would attempt to connect once for each `-c`, fail, and immediately exit - IMPROVED: Currently this will repeatedly try to connect until the specified timeout expires, then it will exit - Start with the server running and leave it running - This works fine as before - Start with the server running, exit the server, then restart the server before the test completes - This initially makes requests - IMPROVED: Previously this would OOM even if the server restarted - IMPROVED: Currently this will reconnect and continue making requests if the server restarts
Great catch! 👍 I understand that a TCP connection should be restarted when one of the parallel connections gets an IO/hyper error. I updated
I can't see any effect of connection timeout in my environment.
Is it a big problem for you? |
3719022
to
2d55312
Compare
http2
- 50 GB of RAM usage on MacBook, causing system OOM #361-z 10s
(work_until) casework_until
cases-c 20
, for example-c
, fail, and immediately exit - IMPROVED: Currently this will repeatedly try to connect until the specified timeout expires, then it will exitAfter - Improved Behavior
oha-pr-363-after.mp4
Before - Existing Behavior
oha-pr-363-before.mp4