Can't choose my scenario

Hi all,
I am discovering Gatling.
yesterday I did as usually some load test with the old 1.5.6 version. I had rouble with long post strings.
On a diffrent laptop I try the last version 2.1.4. I migrate the scala code (thanks the migration documents !)
Running gatling I had some compilation issues; fix the code and run again gatling.bat
I don’t have any issue, but the simulation is not there.
never mind. I save my simluation. and record a fake one with the same name and package. I see it running gatling.bat. I revert my code. No compilation error, and it disappears :frowning:
any idea of what I am missing in the documention when creating a simulation on a machine and moving it to other ?
thanks for your help
Arnaud

there is no class file in target\test-classes folder.

No write permission on filesystem, maybe?

Sorry, crystal ball broken.

thanks for you answer. good hint for my client laptop.
but on mine on my new gatling has evryone : full control.

I activate DEBUG on logbackxml.conf. I saw a message talking about 4 source files

Initial source changes:
removed:Set()
added: Set(C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\orange\ScenarioFibre.scala, C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\orange\Scenario1.scala)
modified: Set(C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\orange\ScenarioCaraibes.scala, C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\esrifrance\Geoprocessing.scala)
Removed products: Set(C:\bin\gatling-charts-highcharts-bundle-2.1.4\target\test-classes\orange\ScenarioCaraibes.class, C:\bin\gatling-charts-highcharts-bundle-2.1.4\target\test-classes\esrifrance\Geoprocessing.class)
External API changes: API Changes: Set()
Modified binary dependencies: Set()
Initial directly invalidated sources: Set(C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\orange\ScenarioCaraibes.scala, C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\orange\ScenarioFibre.scala, C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\esrifrance\Geoprocessing.scala, C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\orange\Scenario1.scala)

Sources indirectly invalidated by:
product: Set(C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\orange\ScenarioCaraibes.scala, C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\esrifrance\Geoprocessing.scala)
binary dep: Set()
external source: Set()
17:10:57.292 [DEBUG] i.g.c.ZincCompiler$ - All initially invalidated sources: Set(C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\orange\ScenarioCaraibes.scala, C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\orange\ScenarioFibre.scala, C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\esrifrance\Geoprocessing.scala, C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\orange\Scenario1.scala)

17:10:57.315 [INFO ] i.g.c.ZincCompiler$ - Compiling 4 Scala sources to C:\bin\gatling-charts-highcharts-bundle-2.1.4\target\test-cl
asses…
17:10:57.891 [DEBUG] i.g.c.ZincCompiler$ - Running cached compiler 27e4203e, interfacing (CompilerInterface) with Scala compiler ver
sion 2.11.5

there is no error and then the available simulations are:

Choose a simulation number:
[0] computerdatabase.BasicSimulation
[1] computerdatabase.advanced.AdvancedSimulationStep01
[2] computerdatabase.advanced.AdvancedSimulationStep02
[3] computerdatabase.advanced.AdvancedSimulationStep03
[4] computerdatabase.advanced.AdvancedSimulationStep04
[5] computerdatabase.advanced.AdvancedSimulationStep05
[6] esrifrance.Geoprocessing

Scenario1.scala
ScenarioFibre.scala
ScenrarioCaraibes.scala are not compiled.

The esrifrance.Geoprocessing was not modifed and work fine.

the scala file are long scenario. I check the faq hint about that

This is a size issue:

17:53:22.466 [ERROR] i.g.c.ZincCompiler$ - C:\bin\gatling-charts-highcharts-bundle-2.1.4\user-files\simulations\orange\ScenarioFibre
.scala:7: Could not write class orange/ScenarioFibre because it exceeds JVM code size limits. Method scala/concurrent/duration/packa
ge$DurationInt’s code too large!
17:53:22.467 [ERROR] i.g.c.ZincCompiler$ - class ScenarioFibre extends Simulation {
17:53:22.468 [ERROR] i.g.c.ZincCompiler$ - ^
17:53:22.474 [ERROR] i.g.c.ZincCompiler$ - one error found
17:53:22.475 [DEBUG] i.g.c.ZincCompiler$ - Compilation failed (CompilerInterface)

I keep only the smallest scenario. and got this error.

The FAQ reports “Can’t compile long scenarios” :
Since 2M3, Gatling forks a new process for running so compiler, so that one can tune JVM differently for compiler and running. The compiler JVM can be tuned with a parameter named gatling.core.zinc in gatling.conf.

but the gatling-defaults.conf does not expose the zinc {} allowed structure to tune the spawned JVM .

I solve my problem using singleton object for each chain and a singleton object for all headers. Each small scala compilation unit is now compiled and the simulation is available !

Yep, you managed to create a class so big that it was exceeding the maximum Java class size.
Could you please open an issue? We could probably directly generate the Simulation the way you modified it.

OK I will do this