Professional Documents
Culture Documents
Bhargava
Dt:24/05/2011
www.mindteck.com
Compiles and displays test results with graphical and statistical tools
www.mindteck.com
VUGen
www.mindteck.com
Recording modes
web_url web_link
web_submit_data web_submit_form
Confidential Mindteck 2010 | 4 | www.mindteck.com
web_submit_data
web_concurrent_start web_concurrent_end
www.mindteck.com
What is Parameterization
www.mindteck.com
Parameter Types
File or Table Parameter Types XML Parameter Types Internal Data Parameter Types User-Defined Function Parameters
www.mindteck.com
Parameterization
What are parameters Defining and creating parameters Defining Parameter Properties Data Assignment Methods Data Update Methods Internal Data Parameter Types
www.mindteck.com
www.mindteck.com
Parameterization Decision-Maker
No
Is this a data dependent field?
Yes Yes
Yes Yes
Parameterize Parameterize Parameterize Parameterize
10
www.mindteck.com
11
www.mindteck.com
12
www.mindteck.com
13
www.mindteck.com
Important: If you select the Sequential method and there are not enough values in the data table, VUGen returns to the first value in the table, continuing in a loop until the end of the test.
14
www.mindteck.com
15
www.mindteck.com
If you specify update Once, the first Vuser takes Kim for all
iterations, the second Vuser takes David for all iterations, and so on.
Confidential Mindteck 2010 | 16 | www.mindteck.com
Random
Unique
Vuser 1
1 2 3 4
a a b c c d d h
a b c d
a f b e c j d g
e f g h
|
a l b m c k d n
17 |
i j k l
a i b c c e d b
m n
param1
o p
www.mindteck.com
18
www.mindteck.com
y
Y
20
www.mindteck.com
21
www.mindteck.com
22
www.mindteck.com
23
www.mindteck.com
24
www.mindteck.com
25
www.mindteck.com
26
www.mindteck.com
Execute parameterized script with update method as Sequential/Once. Execute parameterized script with update method as Random/Each
Iteration.
Execute parameterized script with update method as Random/Once. Execute parameterized script with update method as Unique/Each
Iteration.
Run-Time Settings Run Logic Pacing Log Settings Think Time Network Run-Time Settings Browser Settings Internet Preferences Miscellaneous Run-Time Setting
Confidential Mindteck 2010 | 28 | www.mindteck.com
Runtime Settings
29
www.mindteck.com
Run Logic
30
www.mindteck.com
Pacing
The Pacing Run-Time settings
let you control the time between iterations.
31
www.mindteck.com
..Pacing
As soon as the previous iteration ends:
The new iteration begins as soon as possible after the previous iteration
ends.
32
www.mindteck.com
Log
To determine how much
information should be logged to the output.
Extended Log:
Parameter Substitution Data returned by Server
Advanced Trace
33
www.mindteck.com
Think Time
Ignore think time: Ignore the recorded think time. Replay the think time: As recorded:
Example: lr_think_time(10) waits ten seconds.
Limit think time to: Limit the think times maximum value.
Confidential Mindteck 2010 | 34 | www.mindteck.com
Available Options:
Use maximum bandwidth:
Vusers run at the maximum bandwidth that is available over the network.
Browser Settings
You can set the browser
properties in the following areas:
User-Agent (browser to be
emulated)
Simulate browser cache Download non-HTML resources Simulate a new user each
iteration
36
www.mindteck.com
.. Browser Settings
37
www.mindteck.com
.. Browser Settings
38
www.mindteck.com
.. Browser Settings
39
www.mindteck.com
Internet Preferences
Image and Text Checks Generating Web Performance Graphs Advanced Web RunTime Options
Confidential Mindteck 2010 | 40 | www.mindteck.com
.. Internet Preferences
Settings button or select Vuser > Run-Time Settings to display the Run-Time Settings dialog box. Select the General: Miscellaneous node from the tree in the left pane.
Confidential Mindteck 2010 | 42 | www.mindteck.com
This setting instructs Vusers to continue script execution when an error occurs. This option is turned off by default, indicating that the Vuser will exit if an error occurs.
This option instructs VuGen to mark all transactions in which an lr_error_message function was issued, as Failed. The lr_error_message function is issued through a programmed If statement, when a certain condition is met.
This option generates a snapshot when an error occurs. You can see the snapshot by viewing the Vuser Log and double-clicking on the line at which the error occurred.
Confidential Mindteck 2010 | 43 | www.mindteck.com
If you run each Vuser as a thread, the Controller launches only one
instance of the driver program (such as mdrv.exe), for every 50 Vusers (by default). This eliminates the need for multiple re-loading of the driver program/process saves much memory space, thereby enabling more Vusers to be run on a single load generator.
44
www.mindteck.com
Automatic Transactions
You can instruct LoadRunner to handle every step or
action in a Vuser script as a transaction. This is called using automatic transactions. LoadRunner assigns the step or action name as the name of the transaction. By default, automatic transactions per action are enabled.
45
www.mindteck.com
Correlation
What is correlation
Types of Correlation Automatic Correlation Manual Correlation
47
www.mindteck.com
What is Correlation
Sometime, after creating a script, a simple playback fail even though
the recording of the same actions succeeded.
Many applications use dynamic values that change each time you use
the application. For example, some servers assign a unique session ID for every new session. When you try to replay a recorded session, the application creates a new session ID that differs from the recorded session ID.
When running the emulation, the Vuser does not use the recorded
valueinstead, it uses the new value assigned to it by the server.
48
www.mindteck.com
Automatic Correlation
You will instruct VuGen to insert a step that saves the original session
ID to a parameter. In each replay session, VuGen saves the new unique session ID to a parameter. In the subsequent steps, it uses the saved value instead of the originally recorded value.
Record a new script with the same steps that you recorded previously
and save the script as Basic_Tutorial_Cor.
Click Verify Replay in the Task Pane and click the Start Replay button
at the bottom of the instruction pane. VuGen runs the new script. You may notice several error messages in the Replay Log tab in the Output window, indicated by the red-colored text.
Click Verify Replay in the Task Pane to view the Last Replay Summary
49
www.mindteck.com
Automatic Correlation
Click the link Show and resolve dynamic server values in the
instruction pane under the heading Dynamic Server Values.
Select the first entry in the Correlation Results tab, and click
Correlate.
50
www.mindteck.com
Manual Correlation
Record a new script save the script as Manual_Cor_1. Record another script using the same steps as above and save the
script as Manual_Cor_2.
Now for script Manual_Cor_2, click on Tools > Compare with script
option and select Manual_Cor_1 script to compare with.
51
www.mindteck.com
Manual Correlation
52
www.mindteck.com
Manual Correlation
53
www.mindteck.com
Manual Correlation
54
www.mindteck.com
What is correlation and why is it done? Perform Automatic correlation on the script. Perform Manual correlation on the script.
55
www.mindteck.com
Thank You
www.mindteck.com