在application.properties里启用压缩,并设置压缩支持的格式(默认支持text/html等,但不支持application/json),设置超过多少字节进行需要压缩 server.compression.enabled=trueserver.compression.mime-types=application/json,application/xml,text/html,text/xml,text/plainserver.compression.min-response-size=1024文章作者: LeFer文章链接: https://lefer.cn/posts/64628/版权声明: 本博客所有文章除特别声明外,均采用 CC BY-NC-SA 4.0 许可协议。转载请注明来自 LeFer!spring bootweb 评论