51Testing软件测试论坛
标题:
loadrunner 关联求助
[打印本页]
作者:
zhaojing1226
时间:
2011-1-25 10:24
标题:
loadrunner 关联求助
先贴一段script吧
Action()
{
web_set_proxy("192.168.100.213:3128");
web_add_cookie("HJ5107VISITSNID=SNA779; DOMAIN=210.73.207.4");
web_add_cookie("HJ5107ONCEVISITID1=SNA7792011011557367810.9928747344990907; DOMAIN=210.73.207.4");
web_add_auto_header("Accept-Encoding",
"gzip, deflate");
web_add_auto_header("Accept-Language",
"zh-cn");
web_add_cookie("HJLiveChatNccWebUserNickName=zhaojing; DOMAIN=210.73.207.4");
web_add_cookie("HJ5107VISITSNID=SNA779; DOMAIN=210.73.207.4");
web_add_cookie("HJ5107ONCEVISITID1=SNA7792011011555335310.8940009574831269; DOMAIN=210.73.207.4");
web_url("test.jsp",
"URL=http://210.73.207.4/web/icc/chat/test.jsp",
"TargetFrame=",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Snapshot=t1.inf",
"Mode=HTML",
EXTRARES,
"Url=http://210.73.207.4/web/code/css/hj5107-invite-14.css", ENDITEM,
"Url=http://210.73.207.4/web/icc/flash/SNcenter.swf?debug=0&companyId=1", ENDITEM,
"Url=http://210.73.207.4/web/code/css/hj5107-icon.css", ENDITEM,
"Url=http://210.73.207.4/web/code/images/icon/off-0-0-zh-cn.gif", ENDITEM,
"Url=http://210.73.207.4/web/code/images/icon/close.gif", ENDITEM,
"Url=http://210.73.207.4/web/icc/js/ufProxy.js", ENDITEM,
"Url=http://210.73.207.4/web/icc/flash/Monitor.swf?companyId=1&pageUrl=http%3A%2F%2F210.73.207.4%2Fweb%2Ficc%2Fchat%2Ftest.jsp&pageName=%E7%94%A8%E5%8F%8BICCv4.1%E6%B5%8B%E8%AF%95%E9%A1%B5%E9%9D%A2&ie=Microsoft%20Internet%20Explorer&referedUrl=&searchEngine=50&keyWord=&fsIp=210.73.207.4&fsPort=8000&fsCheckCode=&signId=&orderId=&useProxy=1&grade=&", ENDITEM,
LAST);
web_url("icc.js.jsp",
"URL=http://210.73.207.4/web/code/javascript/icc.js.jsp?c=1",
"TargetFrame=",
"Resource=0",
"RecContentType=text/html",
"Referer=http://210.73.207.4/web/icc/chat/test.jsp",
"Snapshot=t2.inf",
"Mode=HTML",
LAST);
web_url("counter.jsp",
"URL=http://210.73.207.4/web/code/counter.jsp?type=pv&url=http%3A%2F%2F210.73.207.4%2Fweb%2Ficc%2Fchat%2Ftest.jsp&referer=&company=1&sn=SNA779&ovi=SNA7792011011557367810.9928747344990907&browser=Microsoft%20Internet%20Explorer&os=Mozilla%2F4.0%20(compatible%3B%20MSIE%206.0%3B%20Windows%20NT%205.1%3B%20SV1%3B%20.NET%20CLR%202.0.50727%3B%20.NET%20CLR%201.1.4322)&lang=zh-cn&fls=0&res=1280x1024&searchEngine=50&keyWord=",
"TargetFrame=",
"Resource=0",
"RecContentType=text/html",
"Referer=http://210.73.207.4/web/icc/chat/test.jsp",
"Snapshot=t3.inf",
"Mode=HTML",
LAST);
lr_start_transaction("vistorchat");
lr_think_time(17);
web_url("chat",
"URL=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E7%2594%25A8%25E5%258F%258BICCv4.1%25E6%25B5%258B%25E8%25AF%2595%25E9%25A1%25B5%25E9%259D%25A2&referedUrl=&searchEngine=50&keyWord=&ie=Microsoft%2520Internet%2520Explorer&",
"TargetFrame=",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Snapshot=t4.inf",
"Mode=HTML",
EXTRARES,
"Url=../flash/SNcenter.swf?companyId=1", "Referer=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E", ENDITEM,
"Url=../images/chat-1-0/images/chatbg.gif", "Referer=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E7%2594%25A8%25E5%258F%258BICCv4.1%25E6%25B5%258B%25E8%25AF%2595%25E9%25A1%25B5%25E9%259D%25A2&referedUrl=&searchEngine=50&keyWord=&ie=Microsoft%2520Internet%2520Explorer&", ENDITEM,
"Url=../flash/Chat.swf?&companyId=1&referrer=&searchEngine=50&keyWord=&ie=Microsoft%20Internet%20Explorer&type=1&pageUrl=http%3A%2F%2F210.73.207.4%2Fweb%2Ficc%2Fchat%2Ftest.jsp&useProxy=1&ip=192.168.100.213&fsIp=210.73.207.4&fsPort=8000&fmsIp=210.73.207.4&pageName=%E7%94%A8%E5%8F%8BICCv4.1%E6%B5%8B%E8%AF%95%E9%A1%B5%E9%9D%A2&dp=2", "Referer=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E", ENDITEM,
"Url=../images/chat-1-0/images/viewbg.gif", "Referer=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E7%2594%25A8%25E5%258F%258BICCv4.1%25E6%25B5%258B%25E8%25AF%2595%25E9%25A1%25B5%25E9%259D%25A2&referedUrl=&searchEngine=50&keyWord=&ie=Microsoft%2520Internet%2520Explorer&", ENDITEM,
"Url=../images/common/ico/icons.gif", "Referer=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E7%2594%25A8%25E5%258F%258BICCv4.1%25E6%25B5%258B%25E8%25AF%2595%25E9%25A1%25B5%25E9%259D%25A2&referedUrl=&searchEngine=50&keyWord=&ie=Microsoft%2520Internet%2520Explorer&", ENDITEM,
"Url=../js/ufProxy.js", "Referer=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E7%2594%25A8%25E5%258F%258BICCv4.1%25E6%25B5%258B%25E8%25AF%2595%25E9%25A1%25B5%25E9%259D%25A2&referedUrl=&searchEngine=50&keyWord=&ie=Microsoft%2520Internet%2520Explorer&", ENDITEM,
"Url=../js/chat-minor.js", "Referer=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E7%2594%25A8%25E5%258F%258BICCv4.1%25E6%25B5%258B%25E8%25AF%2595%25E9%25A1%25B5%25E9%259D%25A2&referedUrl=&searchEngine=50&keyWord=&ie=Microsoft%2520Internet%2520Explorer&", ENDITEM,
"Url=../images/chat-1-0/zh-cn/sendmessage_disable.gif", "Referer=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E7%2594%25A8%25E5%258F%258BICCv4.1%25E6%25B5%258B%25E8%25AF%2595%25E9%25A1%25B5%25E9%259D%25A2&referedUrl=&searchEngine=50&keyWord=&ie=Microsoft%2520Internet%2520Explorer&", ENDITEM,
"Url=../images/chat-1-0/zh-cn/sel_disable.gif", "Referer=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E7%2594%25A8%25E5%258F%258BICCv4.1%25E6%25B5%258B%25E8%25AF%2595%25E9%25A1%25B5%25E9%259D%25A2&referedUrl=&searchEngine=50&keyWord=&ie=Microsoft%2520Internet%2520Explorer&", ENDITEM,
LAST);
//web_reg_save_param("Usersession", "LB=1295","RB= ",LAST);
web_custom_request("chat!ajax",
"URL=http://210.73.207.4/web/icc/chat/chat!ajax?ajaxId=filterWords&langCnt=zh-cn&c=1&rndVar=
1295856
109156",
"Method=GET",
"TargetFrame=",
"Resource=0",
"RecContentType=text/html",
"Referer=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E7%2594%25A8%25E5%258F%258BICCv4.1%25E6%25B5%258B%25E8%25AF%2595%25E9%25A1%25B5%25E9%259D%25A2&referedUrl=&searchEngine=50&keyWord=&ie=Microsoft%2520Internet%2520Explorer&",
"Snapshot=t5.inf",
"Mode=HTML",
"EncType=application/x-www-form-urlencoded",
"Body=ajaxId=filterWords&langCnt=zh-cn&c=1&rndVar=
1295856
109156",
EXTRARES,
"Url=../images/chat-1-0/zh-cn/sysinfo.gif", "Referer=http://210.73.207.4/web/icc/chat/chat?c=1&s=1&pageUrl=http%253A%252F%252F210.73.207.4%252Fweb%252Ficc%252Fchat%252Ftest.jsp&pageName=%25E7%2594%25A8%25E5%258F%258BICCv4.1%25E6%25B5%258B%25E8%25AF%2595%25E9%25A1%25B5%25E9%259D%25A2&referedUrl=&searchEngine=50&keyWord=&ie=Microsoft%2520Internet%2520Explorer&", ENDITEM,
LAST);
lr_end_transaction("vistorchat",LR_AUTO);
return 0;
}
就是脚本中标记颜色的部分需要关联,我尝试着用同样的操作,录了几次,用windiff工具作了对比,该处数据如下所示
1295856109156
1295856863718
1295857718718
1295857947890
1295858221890
1295858492593
.。。。。。。。
简单描述了下,希望大家能够帮忙啊,能回答的详细点,多谢了!
作者:
云层
时间:
2011-1-25 14:38
你不告诉我这个数据哪个是哪个请求的应答来的,也不告诉我应答的数据包是什么样子,帮不了你。。
欢迎光临 51Testing软件测试论坛 (http://bbs.51testing.com/)
Powered by Discuz! X3.2