1

I am trying to run a jar file using exec-maven-plugin but it always gives a error that 'Parameters for mainClass are missing or invalid'.

<plugin>
      <groupId>org.codehaus.mojo</groupId>
        <artifactId>exec-maven-plugin</artifactId>
        <version>1.3.2</version>
        <executions>
         <execution>
         <id>DataDictinary-Check</id>
         <phase>verify</phase>
          <goals><goal>java</goal></goals>


        <configuration>
       <mainClass>com.ptc.dataDictionary.DataDictionarDescriptionChecker</mainClass>
       <arguments>
       <argument>-jar</argument>
                 <argument> C:\Users\jvarughese\.m2\repository\DataDictionaryChecker\DataDictionaryChecker\12.0-SNAPSHOT\DataDictionaryChecker-12.0-SNAPSHOT.jar</argument>

                 <argument>C:\DBUpgrader\pending</argument>
                 <argument>false </argument>
    </arguments>
      <executableDependency>
      <groupId>DataDictionaryChecker</groupId>
      <artifactId>DataDictionaryChecker</artifactId>
      </executableDependency>
    </configuration>
    </execution>
        </executions>
  • nope its not , its not a duplicate – jacinth joy Apr 11 '18 at 10:59
  • There should be no need to pass `-jar some.jar` as arguments - the exec-maven-plugin knows how to build the proper class path from its given dependencies! – Gyro Gearless Apr 11 '18 at 11:48
  • @jacinthjoy That was a flag, not a comment. I flagged it because I think it is a duplicate. It's for moderators, not you to say whether it was or was not. – Raymo111 Apr 11 '18 at 16:15

0 Answers0