Exception in thread "main" java.lang.NoClassDefFoundError: Could not initialize class io.gatling.core.action.package$


I’m a beginner with gatling and scala… I trying to make it usable within IntelliJ (13.1.6)
I used the artifact tu get the project build as said (I had several issues to obtain a valid project, but it’s done).

It seems to work well (the recorder worked and saved me a scenario as required).

My problem comes with the engine, it runs fine, asks me to select the desired simultation, the id (leave it as default), and the optionnal run description, then it crashes with this error (I wanted to try the test file provided BasicSimulation.scala before testing a complex one) :

Simulation fr.box.bench.BasicSimulation started…
Exception in thread “main” java.lang.NoClassDefFoundError: Could not initialize class io.gatling.core.action.package$
at io.gatling.core.runner.Runner.run(Runner.scala:77)
at io.gatling.app.Gatling$$anonfun$18.apply(Gatling.scala:188)
at io.gatling.app.Gatling$$anonfun$18.apply(Gatling.scala:180)
at scala.Option.getOrElse(Option.scala:120)
at io.gatling.app.Gatling.start(Gatling.scala:180)
at io.gatling.app.Gatling$.fromMap(Gatling.scala:59)
at Engine$delayedInit$body.apply(Engine.scala:12)
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 Engine$.main(Engine.scala:4)
at Engine.main(Engine.scala)

I assume something is missing, but I really don’t know where else to seek… I’m quite desperate so if anyone could help me that would be great.

Thank you.

PS : Here is the pom.xml I use :

<?xml version="1.0" encoding="UTF-8"?>


sonatype-snapshots Sonatype snapshots https://oss.sonatype.org/content/repositories/snapshots typesafe Typesafe Repository http://repo.typesafe.com/typesafe/releases/ 1.6 1.6 2.10.2 UTF-8



io.gatling gatling-app ${gatling.version} io.gatling gatling-recorder ${gatling.version} io.gatling.highcharts gatling-charts-highcharts ${gatling-highcharts.version} org.scala-lang scala-library ${scala.version} com.typesafe.akka akka-actor_2.10 2.3.7 io.gatling.highcharts gatling-charts-highcharts io.gatling gatling-app io.gatling gatling-recorder io.gatling gatling-core 2.0.0-M3a org.scala-lang scala-library src/main/scala src/test/scala net.alchim31.maven scala-maven-plugin ${scala-maven-plugin.version} net.alchim31.maven scala-maven-plugin compile testCompile


What made you want to use 2M3a instead of a modern version (latest release is 2.0.3)?

Nothing especially… To be honnest It’s the only config I could get operationnal with maven.
As I said I had many problem to get a project fonctionnal…

Is there any detailed tutorial to set up a project with a 2.0.3 version (for the dumb… considering the difficulties I had to get this one :wink: )?

Thank you.

Have a look at this project: https://github.com/gatling/gatling-maven-plugin-demo

finally, It’s working, thank you, I had a look to the project before but not as closed as I should have.

Glad it helped.