- Created by SS Doc Editor on Jul 13, 2022
It is desirable to maintain cloud load agents only during the test execution to minimize their usage cost.
It means that load agents have to be automatically created before a test starts and terminated after the test ends.
This option is implemented using Azure Cloud Templates that store parameters of load agents created on-demand dynamically.
Microsoft Azure Template Wizard
Temporary Microsoft Azure agents are created via Azure cloud templates. Inside the Load Agents section, click the Create AWS Load Agent Template button to bring up the Create AWS Template wizard.

Note: StresStimulus creates On-Demand Windows instances. These instances are provided by Microsoft Azure at pricing described here. While StresStimulus attempts to terminate instances that are no longer needed, users are responsible for confirming that the instance was terminated by Azure. StresStimulus is not liable for any Azure charges.
Azure Credentials
To create Microsoft Azure Load Agents, you will need to have an active Azure account with a configured service principal user. Then enter your Client ID, Secret, Tenant, and subscription id in the text boxes and click Next. For more on finding your credentials, key click here.
Region Selection
Next, select the region in which to create your instance. A list of available regions is located here.

Select the operating system
Select the operating system the temporary instance will run on. You can choose Windows or Linux. Windows will have more UI options. Linux will be more cost-effective and require fewer resources.

Instance Type
Next, select the type of instance you wish to create. The instance type determines the performance of the instance, which includes the number of CPUs and memory size. For a list of available instance types, click here. To filter the grid by a type, enter its name in the textbox (a).

Agent Name
If you wish to create an agent from this instance for your current test, add an agent name in this step. Otherwise, skip it.

Click Finish on the confirmation screen to add the agent template to your test.

The newly added template can be treated as a regular agent. Set the mix weight to distribute VUs as described here.
Note
After the test is over, the agent machine will be terminated, and all data stored on the agent will be lost. Do not use templates if you wish to retrieve request/response data from VUs that executed on the agent.
Note
In the unlikely event that StresStimulus crashes, then the temporary agents will be terminated when StresStimulus is restarted.
Cloning the template
After completing the wizard, a single template will be created. The template can be cloned to create one or more additional templates of the same type and location. To clone the template, right-click > select Clone Template option > in the appeared dialog enter the number of clones to create, and click OK.

Keep load agent after the test
By default, the load agent that is created from a template before the test starts will be terminated after the test ends. However, in some situations, it may be beneficial to keep the load agent after the test is over to review some test data.
In order to keep the load agent after the test ends, set the Keep the load agent after the test? property to Yes.

On subsequent test runs, if a load agent from the template already exists, then it will be reused for the test run.
Terminating
To terminate the template load agent you can do one of the following:
- Open the Cloud load manager and terminate from there
- Set the property Keep the load agent after the test? to No, the cloud load agent will terminate at the end of the next test run
- No labels





