I found the solution!!
I'm using spring-boot
within my application with the aim of executing it with the command java -jar <generated_file_name>
. Which means my jar needs to be spring-bootable
I missed the following plugin in my pom.xml --> spring-boot-maven-plugin
which I added as :
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<version>1.0.1.RELEASE</version>
<executions>
<execution>
<goals>
<goal>repackage</goal>
</goals>
<configuration>
<mainClass>${start.class}</mainClass>
</configuration>
</execution>
</executions>
<configuration>
<mainClass>${start.class}</mainClass>
</configuration>
</plugin>
After adding this, it worked like a charm!!