jmeter中get请求gzip数据的方法:

在jmeter线程组中添加“http信息头管理器”,并添加名称:Accept-Encoding值: gzip,deflate
注:HTTP信息头Accept-Encoding 是客户端发给服务器,声明客户端支持的编码类型

验证服务器是否返回了gzip格式数据:

1. 线程组中添加一个“查看结果树”监听器

2.运行测试后,在监听器取样器结果标签页查看http服务器的响应头:

Content-Encoding: gzip
Vary: Accept-Encoding

post方式发送gzip格式文件:

1.http sample里选择“同请求一起发送文件:”MIME类似设置为gzip

2.http 信息头管理器添加http头:
content-type:x-application/x-gzip
content-encoding:gzip

相关文章:

  • 2021-12-04
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-23
  • 2021-04-08
  • 2022-12-23
猜你喜欢
  • 2021-12-16
  • 2021-06-30
  • 2022-12-23
  • 2021-07-15
  • 2021-06-19
相关资源
相似解决方案