加入收藏 | 设为首页 | 会员中心 | 我要投稿 莱芜站长网 (https://www.0634zz.com/)- 云连接、建站、智能边缘云、设备管理、大数据!
当前位置: 首页 > 运营中心 > Nginx > 正文

为什么nginx gzip_http_version默认为HTTP 1.1

发布时间:2020-10-19 17:08:56 所属栏目:Nginx 来源:互联网
导读:nginx的gzip模块中gzip_http_version设置的默认值是HTTP 1.1.为什么?使用gzip和HTTP 1.0有什么问题吗?最佳答案nginx gzip_http_version可以有HTTP 1.0并且有它的警告.When HTTP version 1.0 is used, the Vary: Accept-Encoding heade

nginx的gzip模块中gzip_http_version设置的默认值是HTTP 1.1.为什么?使用gzip和HTTP 1.0有什么问题吗? 最佳答案 nginx gzip_http_version可以有HTTP 1.0并且有它的警告.

When 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.  

更多这里 – http://wiki.nginx.org/HttpGzipModule

(编辑:莱芜站长网)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读