Gatling standalone application crash

Hello.

I was trying to create a standalone Gatling application. Here is the source code:
https://gist.github.com/ivanmushketyk/7121b38472c00d5b9473

I runs but crashes with the following stacktrace:

Exception in thread “main” java.lang.ExceptionInInitializerError
at my.test.TestApp$delayedInit$body.apply(GatlingTest.scala:20)
at scala.Function0$class.apply$mcV$sp(Function0.scala:40)
at scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:12)
at scala.App$$anonfun$main$1.apply(App.scala:71)
at scala.App$$anonfun$main$1.apply(App.scala:71)
at scala.collection.immutable.List.foreach(List.scala:318)
at scala.collection.generic.TraversableForwarder$class.foreach(TraversableForwarder.scala:32)
at scala.App$class.main(App.scala:71)
at my.test.TestApp$.main(GatlingTest.scala:18)
at my.test.TestApp.main(GatlingTest.scala)
Caused by: java.lang.NullPointerException
at io.gatling.core.akka.AkkaDefaults$class.$init$(AkkaDefaults.scala:28)
at io.gatling.http.action.HttpActionBuilder.(HttpActionBuilder.scala:23)
at io.gatling.http.action.HttpRequestActionBuilder.(HttpRequestActionBuilder.scala:42)
at io.gatling.http.request.builder.AbstractHttpRequestBuilder$.toActionBuilder(HttpRequestBuilder.scala:41)
at my.test.GatlingTest$.(GatlingTest.scala:14)
at my.test.GatlingTest$.(GatlingTest.scala)
… 10 more

What am I doing wrong?

Best regards,
Ivan.

Probably many things, one being that you didn’t initialized GatlingConfiguration

You are right. I didn’t initialized GatlingConfiguration.

Thank you for your help.

Hi

Im also getting the java.lang. exceptionInInitializerError.
Could you please guide me to setup the gatling configuration.

Im new to the gatling

Thanks,
Rajeev