You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is pathological case, but if the remaining window size is less than MAX_HTTP_PAYLOAD_SIZE, and it is not the last piece of response, the response stream is stalled.
It can be reproducible using nghttp with -w13 and response file size is bigger than that.
The text was updated successfully, but these errors were encountered:
I've solved this with a better heuristic algorithm for chunking that tries to achieve equally sized chunks that are smaller than the initial window size (and MAX_HTTP_PAYLOAD_SIZE), but probably needs more work in the future.
So if there is 99 bytes window left, then dead lock still occurs. Why do
you just cut the first min(remaining_window, MAX_HTTP_PAYLOAD_SIZE,
buffer.size) bytes of buffer and send it?
Sounds good, but I feel like deadlocks will be possible even then... The best thing would be maybe to postpone chunking until before sending out the next chunk (lazy chunking). The next chunk size would be determined by the function you mentioned, and then next chunk size with the same function etc. And when window runs out, stop until there's window available again.
This is pathological case, but if the remaining window size is less than MAX_HTTP_PAYLOAD_SIZE, and it is not the last piece of response, the response stream is stalled.
It can be reproducible using nghttp with -w13 and response file size is bigger than that.
The text was updated successfully, but these errors were encountered: