def workload (step: Int, pacing: Int, duration: Int) = scenario(s"Workload Step $step")
.during(duration seconds){
pace(pacing seconds)
.exitBlockOnFail {
feed(conversationIdFeeder)
.feed(requestIdFeeder)
.group("Request1") {exec(Request1)}
.feed(requestIdFeeder)
.group("Request2") {exec(Request2)}
.feed(requestIdFeeder)
.group("Request3"){exec(Request3)}
}
}
setUp(
workload(1,5,250).inject(
nothingFor(10 seconds),
rampUsers(50) over(50 seconds),
nothingFor(220 seconds)
)
).protocols(httpProtocol)
Requests Total OK KO % KO Req/s
Global Information 2464 2464 0 0% 10.855
Request1 822 822 0 0% 3.621
Request2 821 821 0 0% 3.617
Request3 820 820 0 0% 3.612
--
You received this message because you are subscribed to the Google Groups "Gatling User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gatling+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
def workload (step: Int, pacing: Int, duration: Int) = scenario(s"Workload Step $step")
.exitBlockOnFail {
feed(conversationIdFeeder)
.feed(requestIdFeeder)
.group("Request1") {exec(Request1)}
.feed(requestIdFeeder)
.group("Request2") {exec(Request2)}
.feed(requestIdFeeder)
.group("Request3"){exec(Request3)}
}
setUp(
workload.inject(
nothingFor(10 seconds),
rampUsers(10) over(10 seconds), constantUsersPerSec(10) during(200 seconds), nothingFor(10 seconds) )
).protocols(httpProtocol)
--
In second scenario which has ConstantUsersPerSec with 10 users should have fired 10 req/s for each req regardless of server response. All i see
Is 2 req/s.
Is 2 req/s.a lot
--
Thanks. The external jar was doing heavy encryption.
One question: In the following scenario, I was intending to inject the load in steps of 2tps (2tps->4tps->6tps and so on) but didn't happen accurately. 4/8/12 tps got injected correctly whereas 2/6/10 tps shows hiccups. If gatling uses asynchttpclient why would this happen?
The scenario had following type of setup
def workload (step: Int, pacing: Int, duration: Int) = scenario(s"Workload Step $step")
To unsubscribe from this group and stop receiving emails from it, send an email to gatling+u...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to gatling+unsubscribe@googlegroups.com.
def pVusers: Int = Integer.getInteger("vusers", 20) def pPacing: Int = Integer.getInteger("pacing", 10) // in seconds def pTps: Int = Integer.getInteger("tps", 2) // pVusers/pPacing``
def pRampTime: Int = Integer.getInteger("rampUpTime", 5) // in seconds def pStepTime: Int = Integer.getInteger("stepTime", 60) //in seconds 1200 def pNumSteps: Int = Integer.getInteger("numSteps", 20) //number of steps of incremental load //scenario def workload (step: Int, pacing: Int, duration: Int) = scenario(s"STEP NO $step").during(duration seconds){ pace(pacing seconds) .exec( exitBlockOnFail { feed(requestIdFeeder) //.group("ION PRVS GF") { .exec(session => { session.set("url", spBrokerURL) }) .group("RequestGroup1"){exec(request1)} .feed(requestIdFeeder) .group("RequestGroup2"){exec(request2)} .feed(requestIdFeeder) .group("RequestGroup3"){exec(request3)} })}
val stepsParams = 1 to pNumSteps map { i => { workload(i, pPacing, ((pNumSteps - i + 3) * (pRampTime+pStepTime))) .inject( nothingFor((i-1) * (pRampTime+pStepTime) seconds), rampUsers(pVusers) over (pRampTime seconds), nothingFor(pStepTime seconds)) } } println("Load Pattern:" + stepsParams + "\n")
setUp(stepsParams:_*) .protocols(httpProtocol) .assertions( global.responseTime.max.lessThan(10000) )