Modifying an Exported Project File
Parameter |
Description |
---|---|
name |
Can be modified. |
t |
*Duration (ms) Think Time refers to the waiting time between two consecutive operations performed by a user, such as the interval between login and search. Suppose that the response time for each running of a transaction is 0.5s.
|
Parameter |
Description |
---|---|
name |
Can be modified. |
http_version |
Indicates the protocol type. HTTP, HTTPS, TCP, and UDP protocols are supported. |
When Protocol Type is HTTP or HTTPS, set the following parameters. |
|
method |
GET, POST, PATCH, PUT, and DELETE are supported. |
return_timeout |
Indicates the timeout interval for waiting for a response from the server when a request is sent. If this parameter is not set, the default response timeout interval (5,000 ms) is used. |
URL |
URL for sending a request, for example, http://domain name/path, or http://domain name/path?key1=value1&key2=value2. |
headers |
Headers consist of keywords and values and are used to notify servers of clients' requests. For details about headers, see Header Description. |
Packet content |
The body of an entity contains a data block consisting of random data. Not all packets contain the body of an entity. If global variables have been set or local variables have been set for response extraction, variables can be used in the packet content. During a pressure test, variables in the packet content will be replaced with specified values. |
When Protocol Type is TCP, set the following parameters.
NOTE:
TCP packets do not support the response extraction and checkpoint functions. |
|
IP |
IP address of the tested server to which requests are sent. |
port |
Port number of the tested server to which requests are sent. |
connect_timeout |
Timeout duration for the server's response after a connection is initiated. |
return_timeout |
Timeout duration for waiting for the server's response after a connection is established. |
Connection Settings |
|
check_end_type |
Used to judge whether a request response has been received.
NOTE:
It is recommended that a unique end-of-text character be set. If there are multiple such characters in a response, when the first character is received, the response is considered to have been received. As a result, the received response data is incomplete. |
body |
The body of an entity contains a data block consisting of random data. Not all packets contain the body of an entity. Content format: Select character strings or a hexadecimal code stream based on the service request content of the tested server.
NOTE:
A hexadecimal code stream can contain only numbers 0–9 and letters a–f. The total number of characters must be an even number. If global variables have been set or local variables have been set for response extraction, variables can be used in the packet content. During a pressure test, variables in the packet content will be replaced with specified values. |
Parameter |
Description |
---|---|
name |
Must be unique. The value of the response extraction is assigned to this variable. |
range |
Range of the content to be extracted.
The packet content, header, and URL can be extracted using regular expressions. |
regexp |
A regular expression specifies a type of logical expressions performed on strings. In a regular expression, you use certain predefined strings and a combination of these strings to form a rule string that is used to specify a specific filtering logic. A complete regular expression consists of two types of characters: special characters (also called meta characters) and literal or common text characters (such as letters, numbers, and underscores). For details about meta characters, see Regular Expression Metacharacters.
NOTE:
() indicates extraction. Enclose the content to be extracted in parentheses. The content between each () indicates a sub-expression. |
match_index |
This parameter indicates the sequence number of the matched content extracted through a regular expression. Value: a positive integer
NOTE:
This parameter cannot be set to 0. |
exp_index |
This parameter indicates the sequence number of the parsed sub-expression. Value range: natural numbers
NOTE:
Value 0 indicates that the entire regular expression is matched. Value 1 indicates that the first sub-expression of the regular expression is matched, that is, the content extracted by the first "()". After extracting content through Regular Expression and Sequence Number of Matching Item, use Expression Value to obtain the final content. |
JSON Key Name |
Enter the key name to be obtained. For example, {key:{"key1":"v1","key2":["v2","v3"]}}. If you want to obtain v2, enter key.key2[0]. |
default |
Indicates the value returned when a regular expression match fails. |
Parameter |
Description |
---|---|
name |
Can be modified. |
value |
This parameter is used to respond to HTTP, HTTPS, TCP and UDP response status codes carried in a packet, including 1XX, 2XX, 3XX, 4XX, and 5XX. |
header_checks |
Headers of the HTTP, HTTPS, TCP, and UDP. |
body_checks |
Body parts of HTTP, HTTPS, TCP, MQTT, and UDP, namely the load parts of the requests and responses. |
Parameter |
Description |
---|---|
name |
Indicates the test project name. |
description |
Indicates description of the test project. |
Parameter |
Description |
---|---|
name |
Indicates the transaction name. |
contents |
Request content. You can add transaction requests under a transaction based on service requirements. |
Parameter |
Description |
---|---|
issue_num |
Number of concurrent users. The number of concurrent users refers to the number of users performing operations on the system at the same time. In CodeArts PerfTest, it is the number of virtual users set when you define test task phases. |
name |
Indicates the phase name. Set a name for the service scenario, for example, homepage test. |
time |
Duration (second). The maximum time for performing a pressure test in the current phase. |
count |
Total number of transmissions. During the running of a task, the transaction is calculated based on the number of running times. When the specified value is met, the performance test of the transaction under the task is terminated. |
Parameter |
Description |
---|---|
name |
Global variable name. |
variable |
Global variable value. |
variable_type
NOTE:
Variable content is transmitted in plain text during the pressure test. Exercise caution when entering the content. |
Global variable type. When the variable type is Integer, enter the value range of the variable. A pressure test task reads the value range of the corresponding global variable when it is running. For each virtual user, the variable value is polled. That is, the first virtual user obtains the first value of the variable, and the second virtual user obtains the second value. If the values are exhausted, the next virtual user obtains the first value again. Add multiple variables as required. A pressure test task reads the value range of the corresponding global variable when it is running. For each virtual user, the variable value is polled. That is, the first virtual user obtains the first value of the variable, and the second virtual user obtains the second value. If the values are exhausted, the next virtual user obtains the first value again. |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot