RFR JDK-8161004 "Bulk sending WindowUpdate frame speedup HTTP/2 performance up to 18x times and improve scalability"
Sergey Kuksenko
sergey.kuksenko at oracle.com
Thu Jul 7 21:35:55 UTC 2016
Hi,
Could you please review the following fix for JDK-8158980?
http://cr.openjdk.java.net/~skuksenko/jep110/8161004/webrev.00/
https://bugs.openjdk.java.net/browse/JDK-8161004
Current HTTP/2 implementation sends WindowUpdate frame each time when
data frame is processed. That leads to network saturation and
oversynchronization on "Http2Connection.sendlock".
In case of getting small data (less than max frame size) we get 55% of
blocks on sendWindowUpdate (and only 37% on sendHeaders).
Even in case of getting large data (1Mbytes) - 18% of all blocks is
caused by sendWindowUpdate.
Suggested performance improvement provides 2x-18x performance speedup.
Implemented optimizations:
1. Accumulate size of received data and send bulk WindowUpdate when some
watermark is reached.
2. Don't send stream WindowUpdate when the last data frame is received
(set flag END_STREAM)
3. WindowUpdate frame goes directly to HttpConnection bypassing
Http2Connection.sendlock. That is allowed with proper protection for "do
not insert WindowUpdate frame between Headers and Continuation frames".
Thank you,
Sergey Kuksenko.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/net-dev/attachments/20160707/1515b617/attachment.html>
More information about the net-dev
mailing list