Nginx的gzip模块中gzip_http_version设置的默认值是HTTP 1.1.为什么?使用gzip和HTTP 1.0有什么问题吗?
最佳答案
Nginx gzip_http_version可以有HTTP 1.0并且有它的警告.
原文链接:https://www.f2er.com/nginx/435113.htmlWhen HTTP version 1.0 is used,the Vary: Accept-Encoding header is not set. As
this can lead to proxy cache corruption,consider adding it with add_header.
Also note that the Content-Length header is not set when using either version.
Keepalives will therefore be impossible with version 1.0,while for 1.1 it is
handled by chunked transfers.