I have done some performance tests on the "Cottage version" before. I have already said, is it a shanzhai? Of course it is not formal. However, the test process of how many enterprises is formal, what's more, the performance testing process. This is the status quo and an opportunity. This project requires a relatively formal performance test that is difficult to perform. B/S, C/S, and interface performance are all involved. It is also a challenge and Improvement for you.
This week, we will mainly analyze requirements and performance requirements, and then write performance test plans and test cases. Many problems are found, which are summarized as follows:
Demand Analysis problems:
1. In the beginning, it is best not to talk to the customer about the metrics required for a performance point, such as the number of simultaneous logins supported. First, the most important thing is to understand the role of the entire system, users, deployment methods, constraints, launch time, and so on, so that you can gradually view the system from the customer's perspective, through our own knowledge, we want the customer to think and worry about the customer's concerns, because our goal is to make the customer satisfied.
Note the following principles for selecting performance testing scenarios:
A, important (business ),
B. Duplicate (the most common module ),
C. heavyweight (consuming a large amount of system resources)
There are several types of performance indicators:
A. System capacity (data capacity, user volume, and concurrent user volume ),
B. System concurrency indicators (registered users, online users, and concurrent users ),
C. Response indicator (response capability under normal pressure, response capability under peak pressure, and response capability under abnormal pressure)
2. Understand the entire system and its implementation, and then list the performance requirements you have analyzed.
3. Ask the customer for specific performance requirements, co-analysis, testing, and testing priorities.
4. Write Performance Test plans and use cases, which should be recognized by the customer.
Performance testing policy:
1. Single performance point, multi-user testing. The test process can isolate test performance scenarios. First, test each performance requirement for pressurization separately. For example, if you log on to the system, you can separately simulate this requirement and create a scenario where 50 concurrent logins are performed. However, this scenario is not the actual usage of users. It is impossible to have a system where everyone is logging on, rather than doing anything else. However, if there are another 50 concurrent logins at the same time, the logon time will be greatly extended. Therefore, this scenario is designed only to check the performance of this module.
2. After isolation, a hybrid performance scenario is gradually established. For example, when logging on, someone is browsing, querying, and writing data to the system. However, only 20% of the load is loaded. This step is mainly an integration test, considering whether there is an impact between each functional module and whether there is a seizure of certain resources. Find the Top Time Transaction
3. if there is no problem in the previous step, we will apply a pressure of 100% this time to see how the system's performance indicators are under our actual requirements. At the same time, we will use this test result as the Base Line, used for comparison after performance optimization.
4. stress testing, depending on the maximum load capacity of the system.
Performance testing capability Problems
Loadrunner is a very useful and complex tool for performance testing. After such a period of study and use, it is found that the difficulties are:
1. How to write this stuff for script recording and development, for example, how to make the log output appropriate information is of great significance for later analysis, and there will be some development capability requirements.
2. How to design a test scenario and simulate user requirements to the greatest extent is a challenge for understanding the requirements and understanding the design and implementation of the entire system. If you know little about it, it is very laborious to understand, and it is not easy to grasp the focus. This effort is beyond LR.
3. How can we analyze the results after performance tests? Well, this is even more challenging. What are the challenges? I think this is not from LR itself, but from understanding the database, operating system, middle layer, and the tested system. This should be the most difficult. Which industry is not the most difficult? How long does it take DBA to optimize an Oracle database and SQL Server? What's more, we need to understand more than databases. Of course, you can ask DBA to help us analyze and solve the problem at this stage. This requirement is beyond LR.
Therefore, the performance testing tool itself is not the biggest difficulty. learning to use the tool is just a starting point. The ability to do a good job in performance testing is not mainly about how to skillfully use LoadRunner or JMeter, but mainly about understanding and control the system.
After reading: I recently encountered performance problems in a company project, so I read a lot of articles about performance testing and learned a lot from this article.