[MSHADE-215] Shade plugin fails to handle "exploded" jars

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

[MSHADE-215] Shade plugin fails to handle "exploded" jars

Johno Crawford-2
Hey all,

When building the Atomix project on GitLab CI [1] we are running into the
same problem as described here

Essentially the artifacts passed into the shade plugin point to the modules
classes directory which fails [2] as the plugin expects jars.

Should the shade plugin be updated to support "exploded" jars? Can we
ignore directories [3]? Should Maven be returning files pointing to
directories in the first place?

Apache Maven 3.5.4
Java version: 1.8.0_171
OS name: "linux", version: "4.14.48-coreos-r2", arch: "amd64"


Caused by: java.io.FileNotFoundException:
/builds/atomix-io/atomix/core/target/classes (Is a directory)
    at java.util.zip.ZipFile.open (Native Method)
    at java.util.zip.ZipFile.<init> (ZipFile.java:225)
    at java.util.zip.ZipFile.<init> (ZipFile.java:155)
    at java.util.jar.JarFile.<init> (JarFile.java:166)
    at java.util.jar.JarFile.<init> (JarFile.java:130)
    at org.apache.maven.plugins.shade.DefaultShader.newJarFile
    at org.apache.maven.plugins.shade.DefaultShader.goThroughAllJarEntriesForManifestTransformer
    at org.apache.maven.plugins.shade.DefaultShader.shade
    at org.apache.maven.plugins.shade.mojo.ShadeMojo.execute
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo