zoukankan      html  css  js  c++  java
  • 深刻剖析VuGen脚本录制原理

    扩展:深刻剖析VuGen脚本录制原理 
    LR中的VuGen组件,主要扮演一个proxy server的角色,在录制脚本时,记录下用户和服务器交互,然后自动生成脚本语言。在接下来的重放,或者大批量地加压时,模拟真实的front end user向网站发送请求,并根据服务器返回的结果,作为判断是否正确执行用户操作的依据。
    
    难道今天能静下心来,对recording log进行了一番分析,为方便以后进行更进一步的发掘,特在此草草地作个记号,以后有机会再回头进行更新与追踪。
    
    此部分是后续进行Web component breakdown性能分析的理论基础。
    扩展:深刻剖析VuGen脚本录制原理
    对上述截图的三处注释
    
    注1:此处是用户发出唯一一条明确的请求,也可以理解为点击,只是此点击会引发后台很多见不到的点击(hits) 
    注2: 向服务提交一个请求,主要是借助welcome.pl对当前用户当前所处的状态进行判断,并返回不同的页面。2.1 输入:signOff = True 未登陆用户;返回:登陆界面导航栏+欢迎页面(welcome to sign up);2.2 输入:signOff = False 用户已登陆; 返回:Flight/Itinerary/Home/Log off四个导航按钮 + 欢迎页面 (welcome username);2.3 输入:signOff = False 用户已登陆 + Flight/Itinerary/Home/Log off某一子页面; 返回: Flight/Itinerary/Home/Log off对应的页面 
    注3:导航栏的判断,是对welcome.pl延续,在前面的基础上进行更具体的判断 
    
    此index.html由三个主要的framesets组成
    
    header.html: 作为一个subframeset引入,主要内容为下面的二个images,hp_logo.png和webtours.png; 
    nav.pl?in=home: 即Navigate menu。由nav.pl脚本中定义的函数进行控制,用户未登陆之前显示username, password, login; 登陆之后则显示订票选项,包括Flight/Itinerary/Home/Log off四个导航按钮; 
    home.html: 具体的文字描述(包含admin.html的链接)。 
    
    WebTour的网站文件存放路径
    
    网站图片:C:Program FilesHPLoadRunnerWebToursMercuryWebToursimages 
    网站HTML页面(如上面所提到的index.html, header.html,home.html):C:Program FilesHPLoadRunnerWebToursMercuryWebTours 
    
    几个主要的perl文件
    
    welcome.pl - # The welcome page.  It handles the bottom frame.  Generally, it splits the bottom frame into two more frames - the left (navigation) and right (info)frames.It also is used to reset the cookies on the client side when the user logs out. 
    nav.pl - # Handle the navigation bar... Basically, only two different modes - login and menus. 
    login.pl -  # Handle the user registration, account autherication etc 
    admin.pl - # The Server Administration pages 
    
    Replay log
    -----------------------
    Web Turbo Replay of LoadRunner 9.10.0 for WIN2003; WebReplay85 build 5896      [MsgId: MMSG-27143]
    Run Mode: HTML      [MsgId: MMSG-26000]
    Run-Time Settings file: "C:Program FilesHPLoadRunnerscriptsWebFlightorder_10num\default.cfg"      [MsgId: MMSG-27141]
    vuser_init.c(12): Registering web_reg_find was successful      [MsgId: MMSG-26390]
    vuser_init.c(15): Detected non-resource "http://127.0.0.1:1080/WebTours/header.html" in "http://127.0.0.1:1080/WebTours/"      [MsgId: MMSG-26574]
    vuser_init.c(15): Detected non-resource "http://127.0.0.1:1080/WebTours/welcome.pl?signOff=true" in "http://127.0.0.1:1080/WebTours/"      [MsgId: MMSG-26574]
    vuser_init.c(15): Found resource "http://127.0.0.1:1080/WebTours/images/hp_logo.png" in HTML "http://127.0.0.1:1080/WebTours/header.html"      [MsgId: MMSG-26659]
    vuser_init.c(15): Found resource "http://127.0.0.1:1080/WebTours/images/webtours.png" in HTML "http://127.0.0.1:1080/WebTours/header.html"      [MsgId: MMSG-26659]
    vuser_init.c(15): Detected non-resource "http://127.0.0.1:1080/WebTours/nav.pl?in=home" in "http://127.0.0.1:1080/WebTours/welcome.pl?signOff=true"      [MsgId: MMSG-26574]
    vuser_init.c(15): Detected non-resource "http://127.0.0.1:1080/WebTours/home.html" in "http://127.0.0.1:1080/WebTours/welcome.pl?signOff=true"      [MsgId: MMSG-26574]
    vuser_init.c(15): Found resource "http://127.0.0.1:1080/WebTours/images/mer_login.gif" in HTML "http://127.0.0.1:1080/WebTours/nav.pl?in=home"      [MsgId: MMSG-26659]
    vuser_init.c(15): Registered web_reg_find successful for "Text=Web Tours" (count=6)      [MsgId: MMSG-26364]
    vuser_init.c(15): web_url("WebTours") was successful, 6453 body bytes, 1562 header bytes      [MsgId: MMSG-26386]
    vuser_init.c(24): Notify: Transaction "Login" started.
    

  • 相关阅读:
    网站首页蒙灰CSS样式
    MATLAB数值计算编程题
    通过P/Invoke控制继电器
    Java实习生入职测试
    navicat for mongodb12破解
    用svg绘制圣诞帽
    Excel条件格式
    10道算法题
    从事软件开发工作10年后的总结
    ASP.NET Core MVC+EF Core从开发到部署
  • 原文地址:https://www.cnblogs.com/qmfsun/p/4523135.html
Copyright © 2011-2022 走看看