Jmeter (5) Properties and variables

Source: Internet
Author: User

1. JMeter properties are uniformly defined in the Jmeter.properties file, we can add custom properties to the file

2. The JMeter property is visible anywhere in the test script (global) and is often used to define the default values used by JMeter, which can be used to pass information between threads.

3. The JMeter property can be referenced in a test plan through a function _p, but not as a variable value for a particular thread.

  

4. The JMeter property can be defined by the _setproperty function JMeter property

5. The JMeter property is case sensitive

6. Properties in Workbench View components:

Workbench Right-click--->add--->non Test Elements--->property Display

  

Second, the variables in JMeter:

1. The JMeter variable is a local variable for the test thread.

2. In different test threads, the JMeter variable can be either exactly the same or different.

3. JMeter variable reference method: ${name}

4, JMeter variables are case-sensitive

5. If a thread has updated a variable, it simply updates the value that the variable replicates in that thread

6. Where variables are defined in JMeter:

A) test plan, add user Defined to the right panel Variables

b) Thread Group, right-click configuration element (config Element)-->user Defined Variables

c) The variables generated by the predecessor or the Post processor can refer to my other article: JMeter Association

d) using CSV parameterized variables, parameterization can refer to my other article: JMeter parameterization

Note: variables defined in A and B two ways are visible to this test plan at jmeter startup. If the same variable is defined in more than one B, only the last definition will take effect. Once a thread is started, the initial value of the entire set of variables is copied to the thread. Other test elements, such as C or D, can be used to redefine variables that affect only the current thread.

Jmeter (5) Properties and variables

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.