]> git.kaiwu.me - nginx.git/commit
SSL: set TCP_NODELAY on SSL connections before handshake.
authorMaxim Dounin <mdounin@mdounin.ru>
Mon, 29 May 2017 13:34:29 +0000 (16:34 +0300)
committerMaxim Dounin <mdounin@mdounin.ru>
Mon, 29 May 2017 13:34:29 +0000 (16:34 +0300)
commit2db69fed2c200a4f4017e82bc9239f22dfac846f
tree1c867137daf53bc2e73d16d260bbe3752f15a87e
parentb66c18d2d50c53b063cd14a2c3e4c8ff8b1b22a5
SSL: set TCP_NODELAY on SSL connections before handshake.

With OpenSSL 1.1.0+, the workaround for handshake buffer size as introduced
in a720f0b0e083 (ticket #413) no longer works, as OpenSSL no longer exposes
handshake buffers, see https://github.com/openssl/openssl/commit/2e7dc7cd688.
Moreover, it is no longer possible to adjust handshake buffers at all now.

To avoid additional RTT if handshake uses more than 4k we now set TCP_NODELAY
on SSL connections before handshake.  While this still results in sub-optimal
network utilization due to incomplete packets being sent, it seems to be
better than nothing.
src/http/ngx_http_request.c
src/stream/ngx_stream_ssl_module.c