gatling-maven-plugin 2.1.0-SNAPSHOT and gatling-charts-highcharts 2.1.0-SNAPSHOT doesn't get well

Running a mavenized gatling project with gatling-maven-plugin 2.1.0-SNAPSHOT and gatling-charts-highcharts 2.1.0-SNAPSHOT throws an exception:

error: java.lang.NoSuchMethodError: scala.reflect.internal.Symbols$Symbol.accessed(Lscala/reflect/internal/Types$Type;)Lscala/reflect/internal/Symbols$Symbol;

(find full stacktrace at https://gist.github.com/witokondoria/48cd4ab81748c7b5a038)

a project to mimic this behaviour is at: https://github.com/witokondoria/gatlingELtest/tree/mvn-profiles

If instead of gatling-maven-plugin 2.1.0-SNAPSHOT we keep gatling-maven-plugin 2.0.0, no classes are build and a message

The requested class(‘tests.PrePT’) can not be found in the classpath or does not extends Simulation.
There is no simulation script. Please check that your scripts are in user-files/simulations

is outputted.

Can this be confirmed as an issue?

No. You’re mixing Scala 2.10 and Scala 2.11 components, and those are not binary compatible.

The other issue comes from a major refactoring we had to do to separate the simulation compilation process from running Gatling itself.
The Maven plugin now takes the responsibility to run the compiler before running Gatling, since Gatling doesn’t compile the simulations itself anymore.
In your case, the simulations never get compiled, since neither Gatling or the Maven plugin compile the simulations.

Ok, so right now there is no option to run a gatling-charts-highcharts 2.1.0-SNAPSHOT from maven because of this binary incompatibility?

There is one : do not mix 2.0.0 plugins with 2.1.0 snapshots :slight_smile:
If you use the 2.1.0-SNAPSHOT version of the Maven plugin (and make sure that you’re using Scala 2.11, not Scala 2.10), it’ll work fine.

So I added scala-compiler dependency (still not sure why should I explicitly force it, so I’m not the one compiling) and now I got back to https://github.com/gatling/gatling/issues/2373.

As that issue was fixed (and tested using the bundle distribution), how can be gatling-maven-plugin reintroducing it?

So I added scala-compiler dependency (still not sure why should I explicitly force it, so I’m not the one compiling) and now I got back to https://github.com/gatling/gatling/issues/2373.

I forgot to update the version of the compiler the Maven plugin uses (was 2.11.2 whereas Gatling uses 2.11.4). This may be the cause.
Fixed it, a new snapshot of the Maven plugin will be available shortly on Sonatype.

As that issue was fixed (and tested using the bundle distribution), how can be gatling-maven-plugin reintroducing it?

It’s possible that you had a previous 2.1-SNAPSHOT in your local Maven repository, and Maven didn’t automatically fetched the latest snapshot.

Please retry with the -U option (mvn -U ….) to force Maven to get the latest snapshot.

Awesome. Will test it on Monday and will came back with my results.

Thanks

Running the simulation with current gatling and gatling-maven 2.1.0-SNAPSHOT leads to an error:

Error: Unknown option -bdf
Error: Unknown argument ‘./gatlingELtest/src/test/resources/bodies’

This could be related to the maven profile configuration:

false
false
tests.PrePT

but simplifing it to leave just the simulationClass tag gives the same error

You have to upgrade your plugin snapshot.
See https://github.com/gatling/gatling-maven/commit/f7062ec9ca21325b605a6684f5c2a9191b9b8e5e

Ia am already testing with gatling-maven-plugin-2.1.0-20141116.220320-128.jar, so I guess that package was built before the commit you mentioned. How often do snapshots gets built?

Regards

Sorry, your plugin is indeed up to date, but that’s your artifacts that aren’t.
We use Travis, so snapshots are deployed on every commit.

This was driving me nuts. I just had a pluginRepository defined, but not a repository, so gatling-charts-highcharts wasnt an up-to-date version. Now everything runs perfectly, thanks.

maven tricks :slight_smile: