LoadRunner integration point, transaction, parameterization

Source: Internet
Author: User

1. integration point: the insertion point is used to measure the performance when the load is increased. In the plan, the system may be required to be able to submit data by 1000 people at the same time. In LoadRunner, you can add a collection point before the data submission operation, in this way, when a virtual user runs to a collection point that submits data, LoadRunner checks how many users are running to the collection point at the same time. If less than 1000 users are running, the LoadRunner command will wait for the user who has arrived at the assembly point. When the number of users waiting at the assembly point reaches 1000, the LoadRunner command will submit data by 1000 people at the same time to meet the requirements in the plan.
 
2. Transaction: To measure the performance, we need to define the transaction. For example, we have a data query operation in the script. to measure the performance of the server's query operation, we define this operation as a transaction, so that when running the test script, when LoadRunner runs to the start point of the transaction, LoadRunner starts timing until it ends at the end point of the transaction. The running time of this transaction is reflected in the result. The insert transaction operation can be performed during the recording or after the recording is completed. LoadRunner runs the script to insert an unlimited number of transactions. Q: Can start_transaction and end_transaction of a transaction be nested?
 
3. parameterized input if the user submits some data during the recording script process, such as adding database records. These operations are recorded in the script. When multiple virtual users run scripts, the same records are submitted, which does not meet the actual running conditions and may cause conflicts. Various inputs are required to simulate the actual environment more realistically. Parameterized input is a good method.

[Information from ""]

 
4. parameterization includes the following two tasks: resources from the ""

 

① Replace the constant value with parameters in the script.

Information from ""

 

② Set the parameter attributes and data source. (Note: not all functions can be parameterized .)
 
5/parameter type. [""]

Datetime: It is very simple. It can be replaced by the datetime type where the date/time needs to be input. The attribute setting is also very simple. Select a format. You can also customize the format. ""

Group Name: you do not know where to use it for the moment, but it is easy to set. In actual operation, LoadRunner replaces the virtual user group with the virtual user group. However, when running vugen, the group name will be none. ""

Load generator name: in actual operation, LoadRunner uses the machine name of the load generator where the virtual user is located.

Syue.com

 

Iteration number: in actual operation, LoadRunner uses the number of cycles of the test script to replace.
 
Random Number: random number. Very simple. You can set the range for generating random numbers in attribute settings.

[Www.syue.com]

 

Unique number: unique number. In attribute settings, you can set the first number and the increasing number. Information Source "year-month alliance"

(Note: to use this parameter type, pay attention to the acceptable maximum number. For example, a text box can accept a maximum of 99. when this parameter type is used, set the first number to 1 and the increment number to 1. When 100 virtual users run simultaneously, 100th virtual Users enter 100, in this way, an error will occur when running the script. Note: The increment here means that each user obtains the increment number of the first value, and the difference between the two adjacent cycles of each user is 1. example: If the Starting number is 1 and the increment value is 5, the first cycle of the first user is set to 1, the second cycle is set to 2, and the first cycle of the second user is set to 6, the second is 7, and so on .) [Source ""]

Vuser ID: easy to set. In actual operation, LoadRunner uses the virtual user ID instead. This ID is controlled by the Controller. However, when running vugen, The vuser ID will be-1. [information from ""]

File: You need to edit the file and add the content in the property settings. You can also retrieve the data from the existing database from ""

User Defined Function: extracts data from user-developed DLL files. At present, I think this method is unnecessary. Vugen supports the C language syntax. It is not difficult to rewrite similar functions in vugen. Question: Can I create only one connection for the parameterized file type, that is, use select * From tablename to get a table, and many columns in this table may be used in the parameterization process, for example, in the username/password column, can you use select * From usertabel to obtain all the data in the database, and then parameterize different parameters to make it easier, and the same settings are available.
 
(Note: In the parameter data display area, you can only view a maximum of 100 rows. If there are more than 100 rows of data, you can only click "edit" to go to notepad .)

[Www.syue.com]

 

Sequential: reads a row in sequence. Each virtual user reads the [Source ""] in the same order.

Random: reads a random number in each loop, but remains unchanged in the loop. [this article is from ""]

Unique: unique number. Content from ""

(Note: when using this type, you must note that there are enough data tables. For example, if 20 virtual users are set in the Controller to perform 5 cycles, the number of virtual users numbered 1 is the first 5, and the number of virtual users numbered 2 is the number of 6-10, and so on. In this way, the data table must contain at least 100 data records. Otherwise, an error is returned during the Controller operation .) Information Source "year-month alliance"

Same line as a parameter (such as name): Same as the previously defined parameter name. It is usually used on Correlated data.
6. Check whether the web page returned by the Web server is correct. vugen allows us to insert text/imag checkpoints. These checkpoints verify whether the specified text or imag exists on the web page, you can also test whether the tested Website Functions are correct in a relatively high stress testing environment. We recommend that you add text/imag checkpoints during recording. (Note: the string to be searched can use a regular expression .)
 
7. You can debug the script, such as adding a breakpoint to the script. The operation is exactly the same as that in VC. The information is from ""

8. Run scenario describes various events that occur during a test. A running scenario includes a list of load generator machines that run virtual user activities, a list of test scripts, and a large number of virtual users and virtual user groups. Use controller to create a running scenario.

"Year-month alliance"

 

9. Optimize the controller and load generators computers. If the Controller machine and load generators computers run 2000, the following two simple techniques can improve the performance. 1) on the load generators computer, choose "Control Panel"> "system"> "advanced", click "performance options", and select "background services" to improve performance, so that more virtual users can be run on each load generators. 2) on the controller computer, follow the preceding steps to go to the "performance options" window. However, here we choose to optimize the "application"
 
10. The C interpreter used to run the vuser script only supports the ansi c language. It does not support Microsoft's extensions to ansi c.
 
11. Common Methods: Set lr_set_transaction_status to enable the transaction state lr_set_transaction_status_by_name. Set the transaction state.
 
Lr_stop_transaction stop the collection of transaction data lr_stop_transaction_instance stop the collection of transaction data (specified by its handle)
 
Lr_get_host_name: returns the Host Name of the vuser script. lr_get_master_host_name: returns the name of the computer that runs LoadRunner controller.
 
Lr_save_datetime saves the current date and time to the parameter
 
Lr_eval_string_ext searches for the pointer to the buffer zone containing parameter data. lr_eval_string_ext_free releases the pointer resources allocated by lr_eval_string_ext from ""
 
Lr_debug_message: Send debugging information to the output window lr_error_message. Send the error message to the output window www.syue.com.

Lr_get_debug_message: Search for the current message class lr_log_message. send the message to the log file lr_output_message and send the message to the output window lr_set_debug_message. Set the debugging message class lr_vuser_status_message to generate output, write it to the controllervuser status region lr_message and send the message to the vuser log and output window.
 
Lr_peek_events indicates the location where the vuser script execution can be paused. lr_think_time indicates the execution of the script to simulate the thinking time (the actual user suspends the thinking time between operations) lr_continue_on_error specifies the method for error handling. lr_rendezvous sets the set point in the vuser script.

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.