Jmeter performance pressure test - high concurrency ideas

Test scenario: Simulate Double 11, millions of orders, and a query interface for logistics information.

Condition: The interface response time is less than 150ms. 100,000 concurrency per second.

Design performance test plan

1. Production environment

①10W/S--concurrency (provided by the architect/technical leader)

②20 machines (4G*4 core configuration)

2. Performance test environment

① Due to cost considerations, most companies cannot configure the same configuration as the production environment. Some production environments have hundreds or even thousands of machines, which cannot be done in the test environment.

② Benchmark test--a small number of requests, a small number of servers--performance test--Deduce the performance of the production environment through theory.

(4G*4 core configuration) 1 machine --> performance index -- derivation -- only one machine with the same configuration as the server can complete 5000/s concurrency (similar to the same reason in mathematics, so analogy)

Precautions:

The performance test project deploys the server hardware model -- consistent with the production environment

3. Performance test case design

①The production environment is faced with a concurrency of 100,000, 20 servers, and an average of 5,000/s per server. When the concurrent demand = 5,000/s, the concurrency must be greater than or equal to 5,000/s.

Performance:

Throughput (accept and send): >=5000/S (QueryPS -- query data scenario (number of query requests processed within one second) -- TransactionPS -- multiple operations/requests for design data modification)

Unit time (s) -- the number of processing requests

Concurrency: 5000/s (relative concurrency: a certain period of time) (absolute concurrency: the same time)

Response time: the complete time from the beginning to the end of the interface request -- 150ms

Performance test case--execution steps + execution result verification

Load test--the limit concurrency carried by the system

Continuously increase concurrency -- until the system does not meet the performance requirements [performance bottleneck] [inflection point]

Stress test (stability test) -- under extreme concurrency, can the system be stable for a specified time (generally, the stress test time is greater than 12 hours)

The order of the two tests: do the stress test first and then the load test, mainly because to do the stress test, you first need to know the limit concurrency, and the load test can know the limit concurrency.

Thread purpose: to execute interface calls

Simulate a total of 500 threads --> increase slowly -- and finally reach

The reason for only pressing 500 threads instead of 5000 threads is that the average access return time of the interface is 100ms, and one thread per second can cause 10 concurrent pressures.

So only 500 users are needed, and the pressure of 5000 concurrency can be reached in 1 second.

4. The plug-ins used by Jmeter are

①Stepping Thread Group is the same as loadrunner, gradient pressure test, you can fill in the parameters in Next and add for each increment.

②Jmeter pressure measurement real-time dashboard is in the back-end listener. Grafana (I haven't studied this dashboard yet, I will continue to fill in the pit after the interface framework is written)

③The advantage of the performance test dashboard is that it has cluster monitoring, which can be used for Linux cluster monitoring.

The following are supporting learning materials. For friends who do [software testing], it should be the most comprehensive and complete preparation warehouse. This warehouse also accompanied me through the most difficult journey. I hope it can help you too!

Software testing interview applet

The software test question bank maxed out by millions of people! ! ! Who is who knows! ! ! The most comprehensive quiz mini program on the whole network, you can use your mobile phone to do the quizzes, on the subway or on the bus, roll it up!

The following interview question sections are covered:

1. Basic theory of software testing, 2. web, app, interface function testing, 3. network, 4. database, 5. linux

6. web, app, interface automation, 7. performance testing, 8. programming basics, 9. hr interview questions, 10. open test questions, 11. security testing, 12. computer basics

Information acquisition method:

Guess you like

Origin blog.csdn.net/jiangjunsss/article/details/132368885