参考链接:
HTTP 协议中的 Transfer-Encoding
分块传输编码
一、背景:
二、分块编码(Transfer-Encoding: chunked)
具体方法
例:
HTTP/1.1 200 OK
Content-Type: text/plain
Transfer-Encoding: chunked
25\r\n
This is the data in the first chunk\r\n
1C\r\n
and this is the second one\r\n
3\r\n
con\r\n
8\r\n
sequence\r\n
0\r\n
\r\n