码迷,mamicode.com
首页 > 其他好文 > 详细

phar打包项目简单压力测试

时间:2016-06-07 20:41:03      阅读:138      评论:0      收藏:0      [点我收藏+]

标签:

工具 http_load
测试url:
http://api.test.chaoma.me/agent/ad/good_goods/query
http://api.test.chaoma.me/agent/common/area/query
http://api.test.chaoma.me/agent/index/getScreenList

 

未进行phar打包

861 fetches, 48 max parallel, 1.29985e+06 bytes, in 10 seconds
1509.69 mean bytes/connection
86.0999 fetches/sec, 129984 bytes/sec
msecs/connect: 0.121065 mean, 0.253 max, 0.059 min
msecs/first-response: 268.232 mean, 537.221 max, 20.177 min
HTTP response codes:
  code 200 -- 861

 

 

GZ 压缩 phar 引入单独入口文件 857k

550 fetches, 283 max parallel, 834656 bytes, in 10 seconds
1517.56 mean bytes/connection
54.9998 fetches/sec, 83465.4 bytes/sec
msecs/connect: 0.141062 mean, 0.412 max, 0.06 min
msecs/first-response: 1430.25 mean, 4242.23 max, 30.521 min
HTTP response codes:
  code 200 -- 550

 

GZ压缩 引入全部phar

552 fetches, 282 max parallel, 824349 bytes, in 10 seconds
1493.39 mean bytes/connection
55.1999 fetches/sec, 82434.8 bytes/sec
msecs/connect: 0.141429 mean, 0.293 max, 0.08 min
msecs/first-response: 1399.32 mean, 3991.58 max, 30.834 min
HTTP response codes:
  code 200 -- 552

 

 

整体未GZ 2.6M

536 fetches, 297 max parallel, 790063 bytes, in 10.0001 seconds
1474 mean bytes/connection
53.5997 fetches/sec, 79005.8 bytes/sec
msecs/connect: 0.140284 mean, 0.277 max, 0.058 min
msecs/first-response: 1585.57 mean, 3539.12 max, 139.093 min
HTTP response codes:
  code 200 -- 536
未GZ 单独引入

530 fetches, 305 max parallel, 800659 bytes, in 10.0001 seconds
1510.68 mean bytes/connection
52.9997 fetches/sec, 80065.4 bytes/sec
msecs/connect: 0.147008 mean, 0.821 max, 0.078 min
msecs/first-response: 1737.13 mean, 5451.6 max, 43.804 min
HTTP response codes:
  code 200 -- 530

 

  每秒处理量降低 (8.5-5.5)/8.5 = 35% 

phar打包项目简单压力测试

标签:

原文地址:http://www.cnblogs.com/china8036/p/5568072.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!