The Infosys Labs research blog tracks trends in technology with a focus on applied research in Information and Communication Technology (ICT)

« Performance Extrapolation that Uses Industry Benchmarks with Performance Models | Main | BI Top Trend Analysis - Part 1 »

Performance testing 101 - Parameterization of values in load testing

Load testing simulates a real time user load on the application and testing this prior to production helps assess an application's scalability and responsiveness. It helps uncover any performance issues with the application which can then be addressed in before it moves into production. HP LoadRunner, IBM Rational Performance Tester, JMeter, WebLoad and Microsoft VSTS are some of the most common load testing tools. These tools simulate the load according to the number of concurrent users and each user can be defined with credentials as specified by the client. This process of assigning each load with user-defined values is called parameterization of values.

In load testing, we record a script and run the same script for different sets of concurrent users. When we record a script for the first time, the values as entered while recording get captured as default values. The issue here is the recorded script has only one set of values which are the default values and they remain the same during the entire schedule for the test. As such user-defined values cannot be entered and the test is not the actual simulation of the production environment. Parameterization technique helps overcome this situation in load testing.  With parameterization, we create a file which has user-defined values, import the file into the script, and replace the default values at the respective places in the script.

Let's take an example to illustrate the same: 

Consider a simple application with a login page which displays the account summary of the user. We assume we have to load test this application for 300 users. Each of these 300 users has different usernames and passwords.

Following steps are followed:

• Record the script
While recording the script for the load testing we used WebLoad 5 and the user entered the following credentials : Username - user1 and password - user1
Here is the part of the script which captures these user entered values as default values -

wlHttp.ContentType = "application/x-www-form-urlencoded"
wlHttp.FormData["j_username"] = 'user1'
wlHttp.FormData["j_password"] = 'user1'
wlHttp.FormData["Submit"] = "Login"

• Create a text file called 'login_300users.txt' with the user-defined input values in a comma-separated pattern. Like -

• Include the following code at the beginning of the script to add the file with user-defined values.
function InitAgenda() {

• Initialize an array to represent the elements which are comma separated.

• Replace the values with the variables.
wlHttp.ContentType = "application/x-www-form-urlencoded"
wlHttp.FormData["j_username"] = DataArr_Login[1]
wlHttp.FormData["j_password"] = DataArr_Login[2]
wlHttp.FormData["Submit"] = "Login"

Thus, the script is modified for load testing and the values are parameterized as per the user-defined values.


How do we accomplish this for a win form based application ?

We need to design custom VS 2010 based Tool that will look into a table and login remotely [ RDP ] into terminal server on which APPLICATION [ win form based ] is .

Once NT user is logged in to a terminal server , it will click APPLICATION's exe and login with APPLICATION Login .

Good Example for Paramterisation

Post a comment

(If you haven't left a comment here before, you may need to be approved by the site owner before your comment will appear. Until then, it won't appear on the entry. Thanks for waiting.)

Please key in the two words you see in the box to validate your identity as an authentic user and reduce spam.

Subscribe to this blog's feed

Follow us on