Explanation of jmeter components

1. Performance test

1.1 What is performance testing?
Based on the protocol, the user sends requests to simulate a certain load on the server to test whether the performance indicators of the server meet the requirements
. Normal, peak and abnormal load conditions to test various performance indicators of the system

2. Introduction to Jmeter

Open source, free, written based on java, can be integrated into other systems to expand various functional plug-ins
Supports interface testing, stress testing and other functions, supports recording and playback, and is
easy to get started. Compared with the frameworks written by yourself and other open source tools, there are relatively complete ui interface, easy interface debugging Multi-platform support, can run on linux, mac, support multi-protocol

Jmeter role
1. Interface test postman/jmeter
2. Performance test jmeter
3. Database test

How to use jmeter
Download address http://jmeter.apache.org/download_jmeter.cgi
insert image description here
install jdk

There is an installation process in the blog I wrote before https://blog.csdn.net/weixin_44826661/article/details/123771288?spm=1001.2014.3001.5502

After the installation is successful, unzip the downloaded Imeter file, open the /bin/jmeter.bat file jmeter.sh and
insert image description here
double-click to open the Jmeter
insert image description here
directory structure
insert image description here
/bin directory (introduction to common files)
examples: The directory contains examples of Jmeter use
ApacheJMeter.jar: JMeter source package
jmeter .bat: startup file under windows jmeter.sh: startup file
under
Linux jmeter.log: Jmeter running log file jmeter.properties:
Jmeter configuration file
jmeter-server.bat: startup load generator service file under windows
jmeter-server: under Linux Start the load generator file
/docs directory - Jmeter help documentation
/extras directory - provides support files for Ant, and can also be used for continuous integration
/lib directory - stores the jar package that Jmeter depends on, and installs plug-ins also in This directory
/licenses directory - software license files, regardless of
/printable_docs directory - Jmeter user manual

Quick Start with Jmeter Testing

Process: An executing program corresponds to a process
Thread: How many execution threads does a process have
Thread group: Threads are grouped according to the nature of the thread The
relationship between the three: how many thread groups a process has, and a thread group has multiple threads

Test plan - thread group - the number of threads in the thread group attribute
Concurrent execution: multiple threads are executed at the same time, characteristic: the order of the end of execution is inconsistent with the order of the beginning of
execution Sequential execution: execute one by one according to the starting order
of the threads By default, in the thread group The threads are executed concurrently.
Each thread must execute the http request in the group.
Set the thread group to execute sequentially: check the (independently run each thread group)
thread group in the test plan to simulate the concurrent access of the user.

Create thread group

insert image description here
The use and setting process of
insert image description here
thread group Add thread group to add http request
insert image description here
After the operation is successful, the return value is displayed successfully
insert image description here
Aggregate report
insert image description here
Response assertion
insert image description here

Guess you like

Origin blog.csdn.net/weixin_44826661/article/details/123841962