Beruflich Dokumente
Kultur Dokumente
Load testing:
1) Load Testing:
The test execution with a specified user load under given conditions. Major focus will be on system
stability, response times and success and failures.
2) Stress Testing:
The test execution where we continuously increase the load on the application until it crashes. Major
focus will be on the threshold limit of users and response time is not at all considered.
3) Endurance Testing:
The test execution where we load the application continuously for longer duration's like days or
months to identify bottlenecks like memory leaks.
4) Spike Testing: The test execution where the application is loaded with varied user load suddenly
(sudden increase and decrease) to check the system behavior.
5) Volume Testing:
The test execution where we send the continuous data to the db to check whether it can handle that
much volume of data at a time.
What is a bottleneck?
Use a diagnostic tool during the load test to identify bottleneck layers/components
Use the profiler to further debug the problematic code and fix it
Monitor and analyze the resource consumption of the servers on which application being tested is deployed
8. Provides information on method executions, call traces, memory utilization, thread execution details
Process is defined as the virtual address space and the control information necessary for
the execution of a program while Threads are a way for a program to split itself into two or
more simultaneously running tasks. In general, a thread is contained inside a
process and different threads in the same process share some resources while different
processes do not.
Source
In terms of Loadrunner, when we run Vuser as a process, LoadRunner creates 1 process
called mmdrv.exe per Vuser. So if we have 10 Vusers, we will have
10 mmdrv.exe processes on our machines.
while when we run Vuser as a thread, LoadRunner creates 1 thread per Vuser. So if we have
10 Vusers, then we will have 1 process with 10 threads running inside it if the limit is 10
threads per process.
9 5 function’s in Vu-gen
LR_OUTPUT_MESSAGE()
This function is used to display the message in an output window.
Action()
{
lr_output_message("Welcome to load runner")
}
Note:-If u want to see only message without logs then go to Run Time Settings and disable logs
Note:- If u want to ignore the line numbers then use lr_message instead of lr_output_message
LR_LOG_Message():-
This function is used to display a log message .It will writes the log message in to log file.
Note: To enable logs go to Run Time Settings and enable logs and log messages will be saved into log
file during the test execution in controller.
LR_SAVE_DATETIME():
It captures and saves the system's current date and time.
below are the few keywords which are used in lr_save_datetime
Action()
{
lr_save_datetime("%c",date_now,"abc");
lr_output_message(lr_eval_string("{abc}"));
return 0;
}
LR_SAVE_STRING():
This function is used to save the string value into another string variable
Action()
{
lr_save_string("welcome to load runner","abc");
lr_output_message(lr_eval_string("{abc}"));
return 0;
}
Action()
{
char *temp="welcome to load runner";
lr_save_string(temp,"abc");
lr_output_message(lr_eval_string("{abc}"));
return 0;
}
Note:
lr_save_string canot save the int values in to string variable
LR_SAVE_INT():
This function is used to save the int value into another string variable
Action()
{
lr_save_int(1213123,"abc");
lr_output_message(lr_eval_string("{abc}"));
return 0;
}
Action()
{
int i=1213123;
lr_save_int(i,"abc");
lr_output_message(lr_eval_string("{abc}"));
return 0;
}
Note:
lr_save_string canot save the int values in to string variable
10 How do you capture a dynamic value from the header of a HTTP response in Vu-Gen
Server level
Processor – % Processor Time: This tracks the overall CPU usage of the entire server.
Memory – Available MBytes: The numbers of megabytes in memory not being used.
Note: This is where things start to get tricky. You have to know the process name of your counter. It is likely w3wp,
w3wp#1, etc. (More on this later)
Process – % Processor Time: CPU used for just your application pool.
Process – Working Set – Private: Memory being used by your IIS application pool.
ASP.NET Application
Note: For these counters, you need to know the instance name of your application. They should be something like
_LM_W3SVC_1_ROOT_AppName. (More on this later)
ASP.NET Applications – % Managed Processor Time (estimated): This allows you to get the
estimated CPU time for your specific application, and not the entire IIS application pool which could be
multiple applications.
ASP.NET Applications – Managed Memory Used (estimated): This allows you to get the estimated
memory usage for your specific application, and not the entire IIS application pool which could be multiple
applications.
ASP.NET Applications – Requests/Sec: It is a good idea to monitor how many requests are handled by
both IIS and ASP.NET. Some requests, for example, static files, may only be processed by IIS and never
touch ASP.NET.
Web Service – Bytes Received/Sec: Identify potential spikes in traffic of data coming in.
Web Service – Bytes Sent/Sec: Identify potential spikes in traffic of data going out.
Web Service – Current Connections: Track this so you know what is normal for your application to
help identify spikes.
ASP.NET Applications – Requests in Application Queue: If this number is too high, your server may
not be able to handle requests fast enough.
Exception & Error Rate Counters
It is really common for an application to have high exception rates that nobody knows about. Problems can be hidden
deep in your code. By tracking these counters, you can get visibility into these types of problems. I highly recommend
monitoring these.
.NET CLR Exceptions – # of Exceps Thrown: Track all .NET exceptions that are thrown even if they
are handled and thrown away. High rates of exceptions can cause hidden performance problems.
ASP.NET Applications – Errors Unhandled During Execution/sec: You need to know how many
exceptions were unhandled and may have been visible to your users.
ASP.NET Applications – Errors Total/Sec: Number of errors during compilations, pre-processing and
execution. This may catch some types of errors that other exception counts don’t include.
.NET CLR Memory – % Time in GC: If your app spends more than 5% of its time in garbage collection,
you may want to review how object allocations are performed.
.NET CLR Memory – # Gen 0 Collections: The number of times that garbage collection has occurred
for generation 0 objects.
.NET CLR Memory – # Gen 1 Collections: The number of times that garbage collection has occurred for
generation 1 objects.
.NET CLR Memory – # Gen 2 Collections: The number of times that garbage collection has occurred
for generation 2 objects.
13 What is the different generations of heap in .NET or Java and what is their significance
Horizontal scaling means that you scale by adding more machines into your pool of
resources whereas Vertical scaling means that you scale by adding more power (CPU,
RAM) to an existing machine.
15 What is the relationship between throughput and response time
17 What is the significance of 90th percentile. What is 90th percentile? Would you use this
measure during your performance testing
Definition: The Standard Deviation is a measure of how response time is spread out around
the Mean. Simply say, the smaller the Standard Deviation, the more consistent the
response time.
19 What is garbage collection
20 What is a JVM
22 What is IP spoofing
29 What is difference between Performance testing and Performance Engineering and explain its
importance
36 What are pros & cons using HP Performance center instead of Load runner
37 Explain Goal oriented scenarios in Load runner and when we use it.