当前位置:网站首页>Apache stress testing tool AB, with post parameter and token request
Apache stress testing tool AB, with post parameter and token request
2022-07-18 15:55:00 【qq_ twenty-seven million eight hundred and seventy-eight thousa】
One . request
post Parameters postdata.txt
name=chang&password=11111ok
PS: Remember to request links , Parameters Use double quotes , Otherwise, no parameters will be received
ab -n 1 -c 1 -p D:\phpstudy_pro\WWW\postdata.txt -T application/x-www-form-urlencoded -H "token:eyJhbGciOiJIU" "http://www.test.com/index/index/abTest"
Export the test report to html , Please add -w Format web page
ab -w -n 1 -c 1 -p D:\phpstudy_pro\WWW\postdata.txt -T application/x-www-form-urlencoded -H "token:eyJhbGciOiJIU" "http://www.test.com/index/index/abTest" >> >>D:\miss.html
Two . Receiving parameters
/** * ab Pressure test strip post,header head Parameters */
public function abTest(Request $request)
{
$fileName = __DIR__ .'/cert/abtest.txt';
$tmpArr = array();
$name = $request->post('name');
$password = $request->post('password');
$token = $request->header('token');
if($name && $password){
$tmpArr = $request->pathinfo();
$jsonStr = json_encode($tmpArr);
$newLog ='log_time:'.date('Y-m-d H:i:s ').$jsonStr." {
$name} -- {
$password} -- {
$token} ";
file_put_contents($fileName,$newLog.PHP_EOL,FILE_APPEND);
return 'ab test ';
}
}
3、 ... and . Request record
abtest.txt
log_time:2022-07-14 10:59:15 "index\/abTest" chang -- 11111ok -- token111
log_time:2022-07-14 10:59:58 "index\/abTest" chang -- 11111ok -- eyJhbGciOiJIU
This is a ApacheBench, edition 2.3 <$Revision: 1843412 $>
copyright 1996 Adam Twiss,Zeus Technology Ltd,http ://www.zeustech.net/
Authorized to Apache Software foundation ,http://www.apache.org/
.. complete
Server software : Apache /2.4.39
Server hostname : www.test.com
Server port : 80
Document path : /index/index/abTest
file length : 33197 byte
Concurrency level : 1
Test time : 0.067 second
Complete the request : 1
Failed requests : 0
Total transfer : 33420 byte
Send the whole : 221
Transmission of HTML: 33197 byte
Requests per second : 14.83
Transmission rate : received 484.11 kb/s
3.20 kb/s send out
A total of 487.31 kb/s
Connection time ( millisecond )
minute Average maximum
Connect : 1 1 1
machining : 66 66 66
All of the : 67 67 67
边栏推荐
- Implement chat room based on poll
- R language - color selection and setting
- Differences between get requests and post requests and usage examples
- AAV2/9的2/9如何理解 AAV2/2,AAV2/5,AAV2/8和AAV2/9有什么区别
- [postponed] 2022 International Conference on network and information security (nisecurity 2022)
- What are the differences between free SSL certificates and paid SSL certificates?
- 面试秘籍大放送,编测编学独家秘籍遭外泄?!
- From it R & D staff turnover thought
- 史上最全mysql!拼命整理
- What are the core technologies of okcc call center system
猜你喜欢

Build your own website (23)

okcc呼叫中心系统核心技术都有哪些

图解数组计算模块NumPy下(三角函数、四舍五入函数(around)、取整、将弧度转化为角度、统计分析函数、中位数、数组的排序、argsort()、lexsort())

AutoJs学习-TTS抢语音红包

C语言——常用字符串函数的实现

The pits encountered using arcpy (3)

高性能定時器

Principle analysis of Rex engine of osgearth (one, two, eight) Rex engine and layer projection and their relationship

R语言---颜色选择和设置

从一篇防范钓鱼邮件的通知说起
随机推荐
Class loading mechanism (how classes are loaded)
spk接口指的是什么
如何用断言思路优雅地处理代码异常
How to set up domain name resolution?
MRP的基本任务是什么
MySQL field type selection
Async function implements multiple request processing
Specify TLS 1.3 and ciphers to improve security and performance
ValueError: The number of FixedLocator locations (7), usually from a call to set_ticks, does not mat
《名侦探柯南》1049话作画大崩坏 角色频频“变脸”
A Zuo's aspiration
Notes - how to do in-depth learning in poor data
Jiulian technology development board is officially integrated into the openharmony backbone
可再生金融ReFi:提供对地球有利的技术和金融系统
Chapter 3: runtime data area - independent space
NFT交易平台竞争格局:核心竞争力是什么?
Top n% data before SQL calculation
Detailed explanation of Flink resource management
Differences between get requests and post requests and usage examples
R language - color selection and setting