What is the difference between load testing and stress testing? Summary of senior test veterans, one article is done...


foreword

Load and Stress Testing

1. Load test: It is a test to test the change of system performance by gradually increasing the system load, and finally determine the maximum load that the system can withstand under the condition of meeting the performance indicators;

2. Stress test: by gradually increasing the system load, testing the changes in system performance, and finally determining under what load conditions the system performance is in a failure state, and using this to obtain the maximum service level that the system can provide.

Example analysis 1:
The login interface, we first 10 users access, then 100 users access, and then 1000 users access, pay attention to the response time of the program, the resources consumed, until the timeout or the exhaustion of key resources.

Stress test: refers to the stability of the program running for a long time.

Example analysis 2:
When the program is running for 1 day, 1 month, and 1 year, pay attention to whether their various indicators are within the normal indicators, whether there will be memory overflow, whether there is a functional failure, and so on.

Stress testing is divided into stability testing and destructive testing.

Load/Pressure Difference

Load testing is not concerned with stability, stress testing is concerned with stability.
What is the difference between load testing and stress testing in performance testing?

Regarding the difference between performance testing, load testing, and stress testing, I always thought it was clear before, but when I was asked about it, I realized that it was still far behind. Here I picked some content from the Internet, plus my own understanding, so I can figure it out. Make a note here, so as not to forget. If there are mistakes, I hope to correct them.

Performance testing (or multi-user concurrent performance testing), load testing, strength testing, and capacity testing are several aspects in the field of performance testing, but the concepts are easily confused.

Performance Test (Performance Test): It usually collects all the performance related to the test and is used by different people on different occasions. The focus is: how much and how fast.

1. Load Test: Load test is a kind of performance test, which refers to whether the program can bear the burden of data running in an overloaded environment. Focus: how much.

2. Stress Test: Stress test (also called strength test) is also a kind of performance test. It is used to find out where and how the system fails when the system resources are extremely low.

3. Extreme testing: Load testing under excessive users Hammer testing: Continuously perform all operations that can be done.

4. Volume Test: Determine the maximum number of simultaneous online users that the system can handle capacity without concern for actual performance in use.

You may think that performance testing, load testing and strength testing are confusing.
Yes, these three concepts are relatively easy to confuse people. Both load testing and stress testing are subsets of performance testing.

A performance test expresses the best-case performance on a given benchmark.
Load testing is also performance testing, but it is under different loads.
Stress test is a performance test under relatively high intensity conditions.

The performance test is power, the load test load, and the stress test intensity.

Stress test stress test: It is the impact of long-term continuous operation of the system on system performance under certain "load conditions".
Load test Load test: under a certain "work load", the load on the system and the system response time.

Here I added brackets to emphasize the difference between stress testing and load testing.

Load testing usually describes a specific type of stress testing—stressing a system (program) by gradually increasing the number of users or user requests. For example, if there is a system that provides online query services in reality, then we start with a relatively small load and gradually increase the number of simulated query requests or the number of users until the system response time times out, which is called load testing. The type of pressure here must be the type of service provided by the application, that is, the workload.

The goal of load testing is to test the system performance under certain load conditions (do not pay attention to stability, that is to say, do not pay attention to long-term running, just get relevant performance indicators under different loads);

In practice, we often start with a relatively small load, gradually increase the number of simulated users (increase the load), and observe the application response time and resource consumption under different loads until timeout or key resources are exhausted. This is the so-called load test , which is the performance index under different load cases of the test system.

The goal of stress testing is to test the stability of the system running for a long time under a certain load, but this load is not necessarily caused by the application system itself. For example, we often use scripts or tools to consume part of the CPU, memory or bandwidth of the server in advance to create a certain load environment and test the transaction processing capability and response time of the application system under test under this environment.

The stress test pays special attention to the long-term running system performance changes under the condition of large business volume (such as whether the response is slow, whether the system will gradually crash due to memory leaks, and whether it can be recovered);

Stress testing is to test the limitations and failure recovery capabilities of the system, which includes two situations:

1. Stability stress test: Under the selected pressure value, it will run continuously for a long time. Through this type of stress test, you can check whether various performance indicators are within the specified range, whether there are memory leaks, whether there are functional failures, etc.;

2. Destructive stress test: Some problems may occur in the stability stress test, such as the system performance is obviously reduced, but it is difficult to expose the real reason. Through destructive and continuous pressurization, it is often possible to quickly cause a system crash or make the problem obvious.

A clear explanation:
There is a waiter here, corresponding to our application system.
The stress test is to put external pressure on the server, such as not letting him rest for a long time, not paying wages, etc., to see if the server will desert (failure to respond to requests in time), or go on strike (downtime) and the like.

Load testing is to gradually increase the workload of the waiter within a unit time, to see the speed and quality of the service completed by the waiter under different workloads, so as to understand the working ability of the waiter.

Stress testing and load testing can help us understand the stress resistance and working ability of a server, and of course help us evaluate the performance bottleneck and quality of a system or software.

The following is the most complete software test engineer learning knowledge architecture system diagram in 2023 that I compiled

1. From entry to mastery of Python programming

Please add a picture description

2. Interface automation project actual combat

Please add a picture description

3. Actual Combat of Web Automation Project

Please add a picture description

4. Actual Combat of App Automation Project

Please add a picture description

5. Resume of first-tier manufacturers

Please add a picture description

6. Test and develop DevOps system

Please add a picture description

7. Commonly used automated testing tools

Please add a picture description

Eight, JMeter performance test

Please add a picture description

9. Summary (little surprise at the end)

Dreams can only be realized with strong determination and unremitting efforts. The road is long and long, and I will search up and down. Let failure be the stepping stone for you to move forward, let struggle be the wings for you to soar. Don’t forget your original intention, you will always be there, believe in yourself, and may you reap the fruits of success in your struggle.

Only by going forward bravely can life be more exciting. Persistence will pay off. Don't give up on your dreams because you can be better than you think. Every step is a milestone of success, work hard to achieve future goals!

Every attempt is a kind of growth, and every failure is a kind of experience. As long as you persevere and move forward bravely, you will surely be able to usher in the joy and glory of success. So let us work hard together and make unremitting efforts to realize our dreams!

Guess you like

Origin blog.csdn.net/m0_70102063/article/details/131329340