jmeter common components Introduction

This paper describes the process of using jmeter most commonly used components and their role. Performance Test thread group can add the following components, as shown:

 

 

 

 

test plan: Test Plan, it is a container for other components

thread: thread group, the number of threads used to set, how to run these threads

config element: configuration information

listener: listen, view the execution results, statistics and issued a request

timer: waiting time, set point, the flow pressure in accordance with the request

pre processor: pre-processor, make preparations before issuing a formal request

post processor: after a request needs to be done, extract the contents of the various response

assertion: various assertion, and a post processor portion similar to the extracted contents as an assertion specified content.

test fregment: test sequences for other controller

Non-test element: non-test related components, such as HTTP Mirror Server (request to return what, convenient debugging), HTTP (S) Test Script Recorder (script recording), etc.

Next, we introduced one by one.

Sampler: Sampler
for initiating a request to the server, which is the most commonly used is HTTP Request, it is also possible to use Debug Sampler, TCP Sampler and so on. Each different type of sampler may emit different types of requests to the server according to the parameters set

 

 

 

 

Controller: control
logic, such as if, while, Loop, etc., is provided to request any rules

 

 

 

Pre Processor: preprocessing

Before requesting what to do preparatory work, similar to Unittest in setUp, generally use less.

 

 

 

Post Processor: after processing the request

The scenario used are more commonly used is regular, can upon request, the expression of certain data exists by positive variable, you can assert or do data association

 

 

 

Assertions: Assertion

Whether the corresponding data obtained for the inspection test in line with expectations. Assertion is generally used to set up a checkpoint to ensure that the data interactive performance testing process is consistent and expectations.

 

 

 

Timer: Timer

Two effects: one is time to sleep, is dead and the like; a speed control request is sent, such as of 5 minutes to 200 times.

 

 

 

Test Fragment: fragment

A controller may be referred to by other segments, a similar function may be used in other places

 

 

 

Config Element: element arranged
to support the static configuration data. CSV date set config local data files form a data pool (date pool), the http request sampler TCP request sampler and other types of elements may be arranged to modify the default data sampler. (For example, http cookie manager that can be used for cookie http request sampler of management, introduced in the use of proxy recording a script.)

 

 

 

Listener: Listener

It is used to test the results of a series of data processing and visualization elements shown. Graphical results, the result tree view, report the polymerization. We are frequently used elements.

 

 

 

Non-test element: non-test related to some of the components

 

 

Execution of priority components:

Configuration element - pre-processor - Timer - Sampler - postprocessor - assertions - Listener

The execution order setting thread group

If there are a plurality of test Plan Thread Group then this thread group are executed concurrently default, if you want to perform in order to add it, need to press the check shown in FIG follows:

 

 

 



Original Source: https: //blog.csdn.net/kongsuhongbaby/article/details/94830194

 

Guess you like

Origin www.cnblogs.com/sucretan2010/p/11526343.html