# How can I run the GatlingRunner.scala from maven command in my project?

**URL:** <https://community.gatling.io/t/how-can-i-run-the-gatlingrunner-scala-from-maven-command-in-my-project/5415>\
**Category:** Gatling (Open-Source)\
**Created:** [December 30, 2019, 12:03pm UTC](https://community.gatling.io/t/how-can-i-run-the-gatlingrunner-scala-from-maven-command-in-my-project/5415 "2019-12-30T12:03:09Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![vaibhav\_sharma](https://avatars.discourse-cdn.com/v4/letter/v/91b2a8/32.png) [@vaibhav\_sharma](https://community.gatling.io/u/vaibhav_sharma)\
**Post date:** [December 30, 2019, 12:03pm UTC](https://community.gatling.io/t/how-can-i-run-the-gatlingrunner-scala-from-maven-command-in-my-project/5415/1 "2019-12-30T12:03:09Z")

</div>

Hi All,

I have Gatling project and there is a runner class I have made like this (in which I can mention the desired simulation class name to run e.g. **AccountManagementSimulation.scala** )

object GatlingRunner {

def main(args: Array[String]): Unit = {

// this is where you specify the class you want to run  
val simClass = classOf[**AccountManagementSimulation**].getName

val props = new GatlingPropertiesBuilder  
props.simulationClass(simClass)

Gatling.fromMap(props.build)

}  
}

But I am unable to run this class from the maven. I tried some commands like mvn package exec:java -Dexec.mainClass=GatlingRunner but nothing happens.

Although if I specify simulation class directly like mvn gatling:test -Dgatling.simulationClass=dealflow.AccountManagementSimulation then it works.

I am using \<gatling-plugin.version\> **3.0.3** \</gatling-plugin.version\>

Please suggest.
