Youce cloud service platform shares the theoretical basis of performance testing

Youce cloud service platform shares the theoretical basis of performance testing

1.1 Basic theory of performance testing

Before introducing the concept and background of performance stress testing, you first need to know why performance stress testing is required. From the Taobao Double Eleven promotion in 2009, the back-office systems of a number of cooperative banks went down one after another, to the difficulty of buying tickets at 12306 during the Spring Festival travel season, to the spike in the start of Jumei Youpin’s promotional activities. According to Amazon statistics, every 100 milliseconds slow, the transaction volume drops by 1%. These events and statistical data sounded the alarm for everyone, and also objectively explained the importance of performance stress testing for enterprise applications. In terms of specific functions, performance stress testing can be used for new system launch support, technology upgrade verification, business peak stability assurance, site capacity planning, and performance bottleneck detection. Performance stress testing is accompanied by the life cycle of system development, reconfiguration, online and optimization. Therefore, effective performance stress testing has important guiding significance for the stability of the system and is an indispensable part of the system life cycle.

1.2 Basic concepts of performance testing

Software performance: The performance of the software is a non-functional characteristic of the software. It is not about whether the software can complete a specific function, but the timeliness displayed when the function is completed.

Performance testing: Refers to testing various performance indicators of the system by simulating various normal, peak and abnormal load conditions through automated testing tools.

Performance focuses on the non-functional characteristics of the software. Generally speaking, the timing of performance testing is after the functional testing is completed.

1.3 Software performance under different perspectives

For different types of systems, the focus of software performance is different. For example, web applications and mobile phone applications generally describe the performance of the system in terms of the end-to-end corresponding time experienced by the end user. For non-interactive applications, such as bank back-office processing systems or third-party payment systems, response time focuses more on the speed of event processing and the throughput of events per unit time. In addition, for the same system, different target groups have different concerns about software performance.

(1) End users: Response time is the most intuitive impression of end users on system performance. It mainly includes the system response time of the response system capability and the front-end display time of the client processing capability. The system response time includes application system processing time, database processing time, and network transmission time.

(2) Operation and maintenance personnel: In addition to focusing on the system response time for single users, they also pay attention to the load, system health, concurrent processing capacity, system capacity, system bottlenecks, long-term stability and scalability during multi-user concurrent Performance, system configuration tuning and database tuning.

(3) Software developers: The performance of serious software development includes algorithm design, architecture design, database, etc. Among them, the algorithm design includes the efficiency of the core algorithm, whether the buffer mechanism is used, whether there is memory leakage, and thread safety. In terms of architecture design, can the system capacity and performance be easily expanded? Regarding the database, consider whether the database table design is efficient, whether to introduce necessary indexes, whether the database needs to introduce a read-write separation mechanism, and whether the database is overloaded when a large number of cache misses after a cold start of the system. For the testability of software performance, focus on whether it supports full-link performance analysis, whether it supports performance management for high concurrency scenarios, and so on.

(4) Performance testers: Performance test engineers pay attention to the five aspects of algorithm design, architecture design, performance best practices, database correlation, and software performance testability. An excellent performance test engineer should have the following skills: summary and abstract ability of performance requirements; accurate performance test scenario design and calculation capabilities according to performance test goals; development and execution capabilities of performance test scripts; analysis and interpretation capabilities of test performance reports; The ability to quickly troubleshoot and locate performance bottlenecks; the ability to design and implement performance test data; in terms of Internet products, test engineers should have the ability to design and execute full-link stress testing; to have an in-depth understanding of the internal implementation principles of performance testing tools, when performance testing When the tools are limited, they can be extended and secondary development; they have a wide range of knowledge, including programming languages, computer principles and operating systems, network foundations, databases, middleware (apache, tomcat), commonly used capture tools, and performance testing tools . In addition, a lot of in-depth accumulation is required, such as database SQL tuning, multi-threaded common problems, etc.

Guess you like

Origin blog.csdn.net/weixin_46033259/article/details/110945710