[英]LoadRunner - Manual Correlation - Unable to get the value using web_reg_save_param
我正在使用LoadRunner來測試基於Siebel CRM的應用程序的性能。 我面臨的問題是我無法獲得每個會話唯一的SRN號。
我用來捕獲SRN的代碼如下
//HELLO YOUR CODE STARTS HERE.....FOR MANUAL CORRELATION
web_reg_save_param("Siebel_SRN",
"NOTFOUND=ERROR",
"LB=SRN`",
"RB=`",
"Ord=All",
"Search=All",
"IgnoreRedirections=Yes",
"RelFrameId=All",
LAST);
lr_output_message( "Siebel_SRN value is %s", lr_eval_string( "{Siebel_SRN}" ) );
//HELLO YOUR CODE ENDS HERE.....FOR MANUAL CORRELATION
如果我按SRN`搜索,則可以看到SRN值。
以下是我從服務器獲得的響應。 我正確設置了邊界(我相信是這樣),但無法獲得SRN值。
vuser_init.c(161): 7/23048/scripts/HICalendarUI.htm`sui`false`vfn`_sweclient._swecontent._sweview`IsWebSocket
vuser_init.c(161): BSReady`false`WebSocketServerPort``SweBusyTimer`30`lt`1471312453347`MR1`Y`cqt`-1`ui`L17LOA
vuser_init.c(161): D`IsAutoOn`false`ect`Link`SRN`ABrcHGKVMlEGktXB3ekmRUEOy6rYzkMmy7OicIW0yHMb`ec`<span class=
vuser_init.c(161): \\"siebui-icon-icon_select\\"><img src=\\"images/icon_select.gif\\" border=\\"0\\" align=\\
vuser_init.c(161): "absmiddle\\" alt=\\"Pick Applet\\" title=\\"Pick Applet\\" >\\<\\/span>`cks`1-14TA9_DHHS
vuser_init.c(161): +L17_43%7c1470288710%7c1471223560_0_23048__L`vs`15.9.0.0 SIA [23048] ENU`USC`1`IsMsgBarEna
vuser_init.c(161): bled`true`lodc`0`IsMobileApplication`false`iri`<span class=\\"siebui-icon-icon_required\\"
vuser_init.c(161): ><img src=\\"images/icon_req.gif\\" border=\\"0\\" space=\\"0\\" hspace=\\"0\\" alt=\\"Req
重播時收到以下消息
No match found for the requested parameter "Siebel_SRN". Either the specified boundaries
were not found in the response or the matched text is longer than current max html parameter size of 999999 bytes.
The total length of the response is 15062 bytes. You can use
"web_set_max_html_param_len" to increase the max parameter size. [MsgId: MERR-26377] [Time:2016-08-16 11:54:27]
Siebel_SRN的輸出是
user_init.c(296): Registering web_reg_save_param was successful [MsgId: MMSG-26390]
vuser_init.c(307): Warning: The string 'Siebel_SRN' with parameter delimiters is not a parameter.
vuser_init.c(307): Siebel_SRN value is {Siebel_SRN} [Time:2016-08-16 11:54:21]
我在做傻事。 但無法解決。請幫助我解決此問題。 提前謝謝
首先,請確保將web_reg_save_param
放置在目標請求步驟( web_url
, web_custom_request
, web_submit_form
等)之前,因為應始終預先注冊相關性。
另外,您不應傳遞Ord=All
參數:它會在Siebel_SRN_1
, Siebel_SRN_2
等參數上創建一個數組。 在您的情況下,響應中只有一個SRN值實例。 IgnoreRedirections=Yes
看起來也很奇怪:一般情況下不需要忽略HTTP重定向。 查看官方文檔以獲取更多信息。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.