Using Jmeter for Performance Testing
Posted By : Richa Sharma | 12-Jan-2021
Jmeter helps in testing both static and dynamic methods. With Jmeter, you can discover coexisting users on a website and acquire a variety of graphical analysis for performance testing.
JMeter Performance Testing includes:
- Load Testing: Mould the expected usage by assuming multiple users access the Web services simultaneously.
- Stress Testing: In Stress testing, we check the maximum load the servers can handle. Since every web server has its maximum capacity.
Preparing a Performance Test Plan
Prior to testing the performance of the target web-based application, we must identify the following points:-
- Normal Load: Average number of users coming by the website.
- Heavy Load: When the maximum number of users are accessing the website.
Step 1) Adding a Thread Group
- Start JMeter
- Select Test Plan on the tree
- Add the Thread Group
Right-click on the "Test Plan" and add a new thread group: click on Add > select Threads (Users) > click on Thread Group
In the Thread Group control panel, we enter Thread Properties as follows:
- Number of Threads: 100 (Number of users connecting to the target website: 100)
- Loop Count is kept: 10 (Number of time to perform the test)
- Ramp-Up Period: 100
We have distinctive Thread Count and Loop Counts.
Step 2) Add JMeter elements
The elements are as follows:-
- HTTP request Default
We add this element by right-clicking on the Thread Group and selecting: click on Add > select Config Element >click on HTTP Request Default.
- HTTP Request
We add this element by right-clicking on Thread Group and select: click on Add > select Sampler > click on HTTP Request.
In the HTTP Request Control Panel, the Path field displays which URL request we want to send to the application server.
Step 3) Adding Graph result
JMeter can show the test result in Graph format.
Right-click Test Plan, Click on Add > select Listener > click on graph Results
Step 4) Running the Test and getting the test result
Press the Run button (Ctrl + R) on the Toolbar to start the testing process. We will see the test result displayed on a Graph in real-time.
At the bottom of the picture, there are the following stats, represented in a few colors:
- Black: It represents the total number of current samples sent.
- Blue: It represents the current average of all samples sent.
- Red: It represents the current standard deviation.
- Green: It represents that Throughput rate which marks the number of requests per minute the server has handled
Hence To analyze the performance of the AUT, need to focus on 2 parameters
The Throughput represents the capacity of the server to handle a heavy load. The higher it is, the better is the server performance.
The deviation is represented in red - it depicts the deviation from the average. The smaller the better.
Why Choose Oodles Technologies For DevOps Solutions?
We are seasoned DevOps solutions and service providers with vast experience in providing full-scale DevOps solutions for varied business requirements. Our team of DevOps professionals formulates effective strategies to strengthen your enterprise IT infrastructure and enhance operational efficiency. Our 360-degree DevOps solutions and services accelerate the software development lifecycle and ensure faster delivery with continuous deployment. For project related queries, reach us out at email@example.com