maven-shade-plugin

Maven can't compile java 1.8

纵饮孤独 提交于 2019-12-03 01:59:56
I'm trying to use maven to build a jar but I keep getting the error ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project Application: Fatal error compiling: invalid target release: 1.8 -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display

Maven Include Dependency in Shaded Jar Only

戏子无情 提交于 2019-12-02 12:56:12
问题 I'd like to use maven shade to create a shaded jar, but I'd also like to include a special dependency only in the case of the shaded jar (not in the normal compile dependencies of my project). How can I go about this? From my understanding the includes/excludes are only whitelists/blacklists so I can't explicitly force something to get included that wasn't included in the actual dependency list. For more context, I have a JAR dependency which contains a resource that I only want included in

Relocating fastxml.jackson classes to my.package.fastxml.jackson

女生的网名这么多〃 提交于 2019-12-02 08:46:15
问题 I'm trying to relocate the packages from "com.fasterxml.jackson" into my own package (ie, "mypackage.com.fasterxml.jackson") and then consume it in another JAR which I own. I've managed to run the maven-shade plugin to do it using this configuration: <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-shade-plugin</artifactId> <executions> <execution> <phase>package</phase> <goals> <goal>shade</goal> </goals> <configuration> <shadedArtifactAttached>false<

Maven shade + resteasy Could find writer for content-type

孤者浪人 提交于 2019-12-02 03:24:07
I have a project that works fine with maven managed dependencies. But I have a requirement for giving my jar files as one. For this I use maven-shade plugin ( http://maven.apache.org/plugins/maven-shade-plugin/ ). All class files are exported correctly but when I try to run my application I get an error as: Could find writer for content-type multipart/form-data type: org.jboss.reasteasy.plugins.provider.multipart.MultipartFormDataOutput Any help would be great, thanks. Note: I had a similar problem with spring whose main cause is configuration files. Many jar files contained a configuraiton

Maven shade plugin does not exclude the manifest signature files

落爺英雄遲暮 提交于 2019-12-01 15:48:05
I am using the maven shade plugin to generate a consolidate jar for my project. The jar is generated as expected and when i try to use the jar and run it, i get a java.lang.SecurityException: Invalid signature file digest for Manifest main attributes error. I googled the above error message and many people have suggested to exclude the manifest signatures from the META-INF directory. Thus i have included the step to exclude these files from the directory [i see two files by the name JARSIGN_.RSA and JARSIGN_.SF ], but for some strange reason, maven shade plugin is unable to exclude these files

Maven shade plugin does not exclude the manifest signature files

吃可爱长大的小学妹 提交于 2019-12-01 15:29:38
问题 I am using the maven shade plugin to generate a consolidate jar for my project. The jar is generated as expected and when i try to use the jar and run it, i get a java.lang.SecurityException: Invalid signature file digest for Manifest main attributes error. I googled the above error message and many people have suggested to exclude the manifest signatures from the META-INF directory. Thus i have included the step to exclude these files from the directory [i see two files by the name JARSIGN_

maven-shade like plugin for SBT

倖福魔咒の 提交于 2019-12-01 02:53:55
i'm rellatively new to the scala and sbt world and i'm trying to manage all my new projects with sbt rather than using maven. But now i'm on a point where I dont know further because I can't find any sbt counterpart for the mavnen-shade plugin. What I found only were plugins to include all dependencies, but that is not what I need. So do somebody know a plugin to include certain dependencies into the jar ? sbt-assembly 0.14.0 adds shading support. sbt-assembly can shade classes from your projects or from the library dependencies. Backed by Jar Jar Links, bytecode transformation (via ASM) is

Geotools cannot find HSQL EPSG DB, throws error: NoSuchAuthorityCodeException

安稳与你 提交于 2019-11-30 12:54:35
I am running Geotools inside of Apache Storm, and having a heck of a time with geotools dependency management. Every thing works when I run the storm cluster locally (windows 7 laptop), but when I deploy to the cluster I get this exception in my logs. EDIT: Here is the Java I use that calls this functionality GridCoverage2D image = new GeoTiffReader(f).read(new GeneralParameterValue[]{policy, gridsize, useJaiRead}); /** * reproject to WGS84 */ CoordinateReferenceSystem targetCRS = CRS.decode("EPSG:4326"); GridCoverage2D reprojectedImage = (GridCoverage2D) Operations.DEFAULT.resample(image,

Maven Shade Plugin to produce two Jars

混江龙づ霸主 提交于 2019-11-30 01:29:20
问题 Till now I was using maven assembly plugin to generate two JARs for each artifact - compiled sources and dependencies - the reason for this was simple - deploying only the compiled sources over network is significantly faster than deploying all-in-one-JAR with 40 MB of data. Because of overwriting of inner files I had to switch for maven shade plugin to be able to use the <transformers> feature. However I am unable to manage to run both of the two executions: <plugins> <plugin> <groupId>org

Maven shade plugin adding dependency-reduced-pom.xml to base directory

廉价感情. 提交于 2019-11-30 01:10:19
The maven shade plugin is creating a file called dependency-reduced-pom.xml and also artifactname-shaded.jar and placing them in the base directory. Is this a bug? Should be in the target directory. Any workaround? xverges You can avoid having it created by setting createDependencyReducedPom to false. e.g. <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-shade-plugin</artifactId> <version>${maven-shade-plugin.version}</version> <configuration> <createDependencyReducedPom>false</createDependencyReducedPom> </configuration> .... .... </plugin> See more detail from apache