How to loop simulations? (Feature request?)

Hi,

I want to repeat a simulation over and over, but Gatling is missing a method for doing so. Is there a way of doing this? Or could it be implemented for a new version?

What I have is this:

`

class LoginEpTest extends Simulation {
  setUp(LoginEpScenarios.loginScenario.inject(
      rampUsers(100).over(10 seconds),
      nothingFor(2 minutes)
  ).protocols(Http.httpProtocol)
}

`

I want to reiterate this several times.

I know there is a repeat() method for scenarios, but that would make a same user to repeat the same actions over again. What I want is to have different users doing this simulation over and over until it satisfies the conditions I’ve established for the loop.
I would like to do something like the following:

`

class LoginEpTest extends Simulation {
  setUp(LoginEpScenarios.loginScenario.inject(
    repeat(7, counterName) {
      rampUsers(100).over(10 seconds),
      nothingFor(2 minutes)
    }
  ).protocols(Http.httpProtocol)
}

`

I rather don’t copy&paste the same injections several times.

Thanks in advance.

Read this issue for closed workload model support: https://github.com/gatling/gatling/issues/1647

Then, the “until it satisfies the conditions I’ve established for the loop” is probably not something we’ll have in Gatling OSS but in FrontLine someday.

Got it! Thanks again, Stéphane!

Just one more question: