Gatling scripts in LoadRunner Cloud

LoadRunner Cloud supports Gatling, an open-source load testing framework based on Scala, Akka, and Netty.

General requirements

The following guidelines apply to Gatling scripts:

  • LoadRunner Cloud supports Gatling scripts (in Scala) that use HTTP requests.
  • If there are multiple Gatling scenarios in a simulation, only the first scenario is run.

For details about the supported Gatling versions, see Support Matrix.

Back to top

Prepare a Gatling script for upload

This section describes how to prepare your Gatling script for its upload to the LoadRunner Cloud repository.

  1. Create a file that defines a simulation and transactions.

    The file is a standard Java properties file (key/value pairs). For example:


    The simulation key specifies the class name for your simulation. This is identical to the ‘-s’ / ‘--simulation’ option when using the Gatling command line.

    The transactions key specifies the list of transaction names, separated by commas, which are displayed on the Load tests > SLA page.

  2. Create a .zip file that contains the file, your .scala files, and all other dependencies.

    Although you may organize your files in sub-folders, the file must be located in the root folder of the .zip file.

After you are have prepared your archive file, you can upload it to LoadRunner Cloud as you would any script. For details, see Scripts.

Back to top

Transaction definitions

Transactions defined in the file appear in the Load tests > SLA page. In addition, all HTTP requests and groups in your script are reported as transactions.

HTTP request example

Transactions are: “list users” and “display user 1”

val scn0 = scenario("gatling1").exec(http("list users").get(" "))
.pause(2 seconds)
.exec(http("display user 1").get(" ")

Group example

Transactions are: "test", “test / list users” and “test / display user 1”

val scn1 = scenario("gatling1").group("test") {
exec(http("list users").get(" "))
.pause(2 seconds)
.exec(http("display user 1").get(" ")

Back to top

Vuser scheduling

Vuser scheduling is determined by the configuration you set on the Load tests > Load profile page.

This means that commands such as ‘atOnceUsers’, ‘rampUsers’, ‘rampUsersPerSec’, ‘rendezVous’, ‘throttle’ and ‘maxDuration’ are ignored.

Assertions APIs, used to verify global statistics for a whole simulation, and global pause configurations are also ignored.

Back to top


The completion of one Gatling scenario corresponds to one iteration.

The pacing configured on the Load tests > Load profile page is applied between iterations.

Do not use scenarios that run endlessly, such as loop statements, which never exit, using forever or repeat with a large times parameter.

Back to top