Example: return 5000
How to add ‘JSR223 Timer’?
Follow the below steps to add JSR223 Timer:
- Select the appropriate element where you want to add the timer
- Test Plan
- Thread Group
- Right-click on the element
- Hover the mouse over ‘Add’
- Hover the mouse over ‘Timers’
- Click ‘JSR223 Timer’
What are the inputs of the ‘JSR223 Timer’?
‘JSR Timer’ has the following input fields:
- Name: To provide the name of the timer
- Comments: To provide arbitrary comments (if any)
- Language: To choose a scripting language.
- Parameters: Parameters to pass to the script. This is an optional attribute.
- Script file: A file containing the script to run. The return value is used as the number of milliseconds to wait.
- Script: The manual script which contains the logic to generate think (delay) time. The return value is used as the number of milliseconds to wait.
- JSR223 timer is processed before each sampler in the scope in which it is found; if there are several timers in the same scope, all the timers will be processed before each sampler.
- Timers are only processed in conjunction with a sampler. A timer which is not in the same scope as a sampler will not be processed at all.
- To apply the timer to a single sampler, add the JSR223 Timer as a child element of the sampler.
- To apply the timer after a sampler, either add the JSR223 Timer as a child element of the next sampler or as a child element of Flow Control Action.
You may be interested:
- Performance Testing Tutorial
- Performance Engineering Tutorial
- Micro Focus LoadRunner Tutorial
- NeoLoad Tutorial