Inject load with a soak phase

I need to have a test which has a linear ramp up phase for a few minutes, then hold at the specified level(number of users) for a specific duration. Should I inject the load in this fashion to perform this kind of soak test -

setUp(
  scn.inject(
    rampUsers(10) over (5 seconds), // 3
    constantUsersPerSec(10) during (15 minutes), // 4
  ).protocols(httpConf)
)

I use gatling closed model for this (https://gatling.io/docs/current/general/simulation_setup/#simulation-inject-closed) which is available in 3.0

Hi Pujitha,

I tried using your code on a simple RESTFUL api testcase, with Gatling 2.3.1 and 3.0.2.

While the code you gave behaves properly in v2.3.1 (around 10 vusers constantly), the vusers account is too high in v3.0.2. If I just run the rampup, it goes up to 400 vusers (this is a fast api written in go).

Did you run successfully the code you gave in v3.0.2?

Rgds
Christian

Hi Christian,

Sorry for the late reply.

Isn’t that what is expected? You have good set of vusers ready in the queue, but only 10 are concurrent. If your app is responding pretty fast you’ll notice the number of vusers is going up to keep up with the concurrency.

In my test I have seen the number of vusers gone up, but when I monitor from the app end, I could see the concurrency was same as to what I set in the test.

Best regards,

-Pujitha.