diff options
author | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2015-12-13 19:32:58 +0900 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2015-12-15 23:47:46 +0100 |
commit | 15cb03ad846a10c4aa4889d46804389ad11cdc1d (patch) | |
tree | 7b2e270cc7980ed5d1a54e08f10a958e14f95645 /docs/README.netware | |
parent | 871ad2a0f242ee036f35ccc6c48e5baa6389885f (diff) |
http2: Support trailer fields
This commit adds trailer support in HTTP/2. In HTTP/1.1, chunked
encoding must be used to send trialer fields. HTTP/2 deprecated any
trandfer-encoding, including chunked. But trailer fields are now
always available.
Since trailer fields are relatively rare these days (gRPC uses them
extensively though), allocating buffer for trailer fields is done when
we detect that HEADERS frame containing trailer fields is started. We
use Curl_add_buffer_* functions to buffer all trailers, just like we
do for regular header fields. And then deliver them when stream is
closed. We have to be careful here so that all data are delivered to
upper layer before sending trailers to the application.
We can deliver trailer field one by one using NGHTTP2_ERR_PAUSE
mechanism, but current method is far more simple.
Another possibility is use chunked encoding internally for HTTP/2
traffic. I have not tested it, but it could add another overhead.
Closes #564
Diffstat (limited to 'docs/README.netware')
0 files changed, 0 insertions, 0 deletions