Hi,
While writing a script to perform some SMTP with Gatling, I encountered a Stack overflow error.
I developped a custom protocol over the 2.2.0 to send eMails via SMTP.
If I run my scenario with I can run my scenario without trouble:
setUp(scn.inject(nothingFor(10 seconds), rampUsers(UserCount) over(10 seconds))).protocols(smtp)
However, if I use :
setUp(scn.inject(atOnceUsers(UserCount))) .maxDuration(3 minutes) .throttle( reachRps(UserCount) in (10 seconds), holdFor(3 minute)) .protocols(smtp)
I get a StackOverFlowException with the following stack trace after ~ 40 seconds of tests (I selected the repeated part of it) :
at org.apache.james.gatling.smtp.SmtpAction.execute(SmtpAction.scala:32) at io.gatling.core.action.Action$class.$bang(Action.scala:35) at org.apache.james.gatling.smtp.SmtpAction.io$gatling$core$action$ChainableAction$$super$$bang(SmtpAction.scala:14) at io.gatling.core.action.ChainableAction$class.$bang(Action.scala:60) at org.apache.james.gatling.smtp.SmtpAction.$bang(SmtpAction.scala:14) at io.gatling.core.action.InnerLoop.execute(Loop.scala:66) at io.gatling.core.action.Action$class.$bang(Action.scala:35) at io.gatling.core.action.InnerLoop.io$gatling$core$action$ChainableAction$$super$$bang(Loop.scala:41) at io.gatling.core.action.ChainableAction$class.$bang(Action.scala:60) at io.gatling.core.action.InnerLoop.$bang(Loop.scala:41) at io.gatling.core.action.Loop.io$gatling$core$action$Loop$$$anonfun$1(Loop.scala:38) at io.gatling.core.action.Loop.io$gatling$core$action$Loop$$$anonfun$1$adapted(Loop.scala:38) at io.gatling.core.action.ExitableAction$.exitOrElse(BlockExit.scala:125) at io.gatling.core.action.Loop.execute(Loop.scala:38) at io.gatling.core.action.Action$class.$bang(Action.scala:35) at io.gatling.core.action.Loop.$bang(Loop.scala:30) at org.apache.james.gatling.smtp.SmtpAction.execute(SmtpAction.scala:32)
I do not understand why the second secnario do not behave like the first one.
I attached SmtpAction to the post.
Regards,
Benoit Tellier
SmtpAction.scala (2.36 KB)