How to Execute particular simulations using maven goals

Hi folks,

i am using gatling version 2.2.3, i have a bunch of Simulation class’s in one package

below is my gatling maven plugin configuration

    <!-- configuration -->
        <!--    <noReports>false</noReports> -->
        <!--   <reportsOnly>directoryName</reportsOnly> -->
        <!--   <simulationClass>foo.Bar</simulationClass> -->
        <!--   <jvmArgs> -->
        <!--     <jvmArg>-DmyExtraParam=foo</jvmArg> -->
        <!--   </jvmArgs> -->
        <!--    <fork>true</fork> -->
        <!--    <propagateSystemProperties>true</propagateSystemProperties> -->
        <!--   <failOnError>true</failOnError> -->
  1. if i use maven goal as
    $mvn gatling:integration-test

    i got the below error

  2. `
    Gatling failed. More than 1 simulation to run, need to specify one, or enable runMultipleSimulations → [Help 1]


  3. i need to execute those class on CI env so please guide me how to Run single Simulation class with Maven plugin?

  4. How to execute multiple Simulation class’s at same time ?
    Thank you

ad 2) mvn -Dgatling.simulationClass=com/company/name/loadtest/${Your Simulation Class Without Extension} will do the trick executing a single test on the command line

ad 3) Never did it but it is described here: - you need to decide it you rely on the Maven life cycle or trigger the tests using 2)

Thanks for the reply Siegfried,

yes i have tried that as well
$ mvn clean gatling:integration-test -Dgatling.simulationClass={myClassName}


when i run this maven goal still asking me Choose a simulation number: again

  • all my simulation class’s in one folder including one Page Object Class (com.companyname.loadtest)
  • in my pom here is the plugin configuration

I have following plugin in pom.xml

io.gatling gatling-maven-plugin 2.1.6

Use following command to execute a single simulation :

mvn gatling:execute

If using com/company/name/Loadtests it asks to Choose a simulation number

Hi folks,

it is hard to know what’s wrong with your given setup (different Gatling & Maven plugin versions) - you can have a look at one of my pet project where selecting the tests using system properties does work :

Thanks in advance,

Siegfried Goeschl