I want to compile all my .jars into a final .jar with Maven shade plugin. This works partially, but Maven is not including all the dependencies in the uberjar. (These questions didn't help me: here and here).
From the output I can see that it is including all the maven dependencies, but not my custom packages(someCustomPackage.jar e.g.), for example:
....
[INFO] Including xpp3:xpp3:jar:1.1.3.3 in the shaded jar.
[INFO] Including org.json:json:jar:20140107 in the shaded jar.
[INFO] Including net.sf.saxon:Saxon-HE:jar:9.7.0-7 in the shaded jar.
....
But it doesn't say anything about the someCustomPackage. This is how the dependencies start (I try to summarize the important parts of the pom.xml):
...
<someCustomPackage.path>${basedir}/lib/someCustomPackage-1.0.jar</someCustomPackage.path>
...
<dependencies>
<dependency>
<groupId>someCustomPackage</groupId>
<artifactId>myArtifact</artifactId>
<version>1.0</version>
<scope>system</scope>
<systemPath>${someCustomPackage.path}</systemPath>
</dependency>
<!--Maven dependencies-->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>${junit.version}</version>
<scope>compile</scope>
</dependency>
<dependency>
etc...
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>2.3</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<filters>
<filter>
<artifact>*:*</artifact>
<excludes>
<exclude>META-INF/*.SF</exclude>
<exclude>META-INF/*.DSA</exclude>
<exclude>META-INF/*.RSA</exclude>
</excludes>
</filter>
</filters>
<transformers>
<transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
<mainClass>myArtifact</mainClass>
</transformer>
</transformers>
</configuration>
</execution>
</executions>
</plugin>
What am I missing in the pom.xml? Should I mention the someCustomPackage explicitly? Or is it something different...
Thanks in advance!