Questions tagged [maven-shade-plugin]

This plugin provides the capability to package the artifact in an uber-jar, including its dependencies and to shade - i.e. rename or remove - the packages of some of the dependencies.

Sources : http://maven.apache.org/plugins/maven-shade-plugin/index.html

Goals Overview

The Shade Plugin has a single goal:

shade:shade is bound to the package phase and is used to create a shaded jar.

Usage

General instructions on how to use the Shade Plugin can be found on the usage page. Some more specific use cases are described in the examples given below. Last but not least, users occasionally contribute additional examples, tips or errata to the plugin's wiki page.

In case you still have questions regarding the plugin's usage, please feel free to contact the user mailing list. The posts to the mailing list are archived and could already contain the answer to your question as part of an older thread. Hence, it is also worth browsing/searching the mail archive.

If you feel like the plugin is missing a feature or has a defect, you can fill a feature request or bug report in our issue tracker. When creating a new issue, please provide a comprehensive description of your concern. Especially for fixing bugs it is crucial that the developers can reproduce your problem. For this reason, entire debug logs, POMs or most preferably little demo projects attached to the issue are very much appreciated. Of course, patches are welcome, too. Contributors can check out the project from our source repository and will find supplementary information in the guide to helping with Maven.

Official site : http://maven.apache.org/plugins/maven-shade-plugin/

Maven Repository site : https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-shade-plugin

529 questions
2
votes
2 answers

Getting No configuration setting found for key 'akka.version' from jar-with-dependencies shaded jar

I've used the maven-shade-plugin given in the akka docs and it creates a shaded jar as evidenced by the following output from maven build: [INFO] --- maven-shade-plugin:2.4.2:shade (default) @ remoting.example --- [INFO] Including…
Dean Schulze
  • 9,633
  • 24
  • 100
  • 165
2
votes
1 answer

How do I use maven shade plugin in Eclipse

I'm a novice here in maven, I'm trying to shade my plugin to add dependencies in my project. But I can't seems to find a way to use maven shade plugin. I would ask that anyone here would show me some examples and explain for me specifically, thanks.
Woo E-Than
  • 21
  • 1
  • 2
2
votes
0 answers

How to build shaded jars for a Spark application for distributed and local execution?

I'm building a Spark application and I want to generate two separate shaded .jar files, one for each of these contexts: For master=local mode, I want a single .jar file that can be executed with java -jar shaded-for-local-mode.jar. This should…
2
votes
1 answer

Excluding artifacts with Maven Shade plugin is not working as expected

I'm trying to exclude a series of artifacts when building the uber-jar with the Maven Shade plugin. Below is the configuration I'm using for this: org.apache.maven.plugins
2
votes
1 answer

Shaded jar only with external libraries - Maven Shade Plugin

Is there a way to create a jar with classes from the current project and a shaded jar containing only external libraries? I am moving final artifacts over the network and it would be great if I would need to only copy "slim" jar if no external…
Kucera.Jan.CZ
  • 714
  • 1
  • 7
  • 19
2
votes
1 answer

Including ojdbc into .exe with launch4j

I have a REALLY simple app, that helps in repetitive tasks concerning script executions. No problem with that. App works perfectly in eclipse. I use ojdbc14.jar to work with my Oracle DB. Now, I wanted to create an exe file in order to distribute…
Manuel S.
  • 411
  • 8
  • 21
2
votes
1 answer

How to use Sesame Rio with maven-shade-plugin?

When I try to use Sesame Rio in a standalone Java application packaged with the maven-shade-plugin, I get Exception in thread "main" org.openrdf.rio.UnsupportedRDFormatException: Did not recognise RDF format object N-Triples…
thSoft
  • 21,755
  • 5
  • 88
  • 103
2
votes
2 answers

LogFactory ClassNotFoundException with Google AutoValue and spring-context-support

A Spring boot project depends on auto-value 1.1 and spring-context-support 4.2.1. When I run it with mvn spring-boot:run, I see the following error: org.springframework.beans.factory.BeanCreationException: Error creating bean with name…
Shaun
  • 68
  • 1
  • 6
2
votes
1 answer

Maven Shade - change file name and replace text

I trying to use Maven Shade and wrap ElasticSearch jar. The reason, why I doing it is because I have a conflict between Lucene version in my project. But I found problem, when I using Shade. It doesn't change name of file in META-INF/services and…
MicTech
  • 42,457
  • 14
  • 62
  • 79
2
votes
0 answers

Maven Shade plugin , main class not found (Scala, Intellij)

I tried to look around a lot to solve this problem but I can't really solve it. In my scala project i'm trying to build a fatjar with all the dependencies in it, so here is my pom: org.apache.maven.plugins
2
votes
1 answer

Using the maven jar plugin with maven shade plugin

following is the structure inside my pom.xml in a multimodule project Module A pom.xml org.apache.maven.plugins maven-shade-plugin
user_mda
  • 18,148
  • 27
  • 82
  • 145
2
votes
2 answers

Dropwizard: Failed to parse configuration at: logging.appenders

I got the error "Failed to parse configuration at: logging.appenders" when I ran a basic Dropwizard.io (v0.8.1) project using "java -jar target\helloDropwizard-1.0-SNAPSHOT.jar server". Full error message: Failed to parse configuration at:…
Rafael Leonhardt
  • 404
  • 5
  • 15
2
votes
2 answers

Can I not run shade plugin when there are no source changes?

Can I configure maven shade plugin in such a way, that when there are no source changes it will not create shaded plugin again (and leave the old one) - in scenario when I don't use "clean".
keyer
  • 53
  • 3
2
votes
2 answers

Maven assembly or shade plugin - How to exclude sources from jar?

I want to know if it is possible to exclude some resources from my maven project to be bundled within the jar file, either using the assembly or shade plugin. Note that I can do this by putting in the build DOM node:
Alex Botev
  • 1,369
  • 2
  • 19
  • 34
2
votes
0 answers

ClassNotFoundException when using Maven shade plugin to create a uber jar to write a client library to consume REST service using jersey - jackson

I'm writing a client (library) to consume a REST service in order to give users of the library simple get and set methods to work with, hiding complexities of REST APIs. I'm using jackson 2.4.0 and jersey 2.6 to consume the REST service. The goal…
Adhyatmik
  • 1,038
  • 11
  • 19