Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MSHADE-36] Use reduced dependencies #25

wants to merge 1 commit into
base: master


Copy link

commented Aug 27, 2019

This is a proposed fix for the issue which has been open for over 11 years.

The implementation is activated when the setting "useDependencyReducedPomInJar" is set to true.
It then essentially injects two ResourceTransformers from code

  1. Remove the original "META-INF/maven/${project.groupId}/${project.artifactId}/pom.xml".
  2. Include the dependency-reduced-pom.xml under the name of the original pom.xml into the final jar file.

This includes an integration test to verify this actually happens.

Following this checklist to help us incorporate your
contribution quickly and easily:

  • Make sure there is a JIRA issue filed
    for the change (usually before you start working on it).
  • Each commit in the pull request should have a meaningful subject line and body.
  • Format the pull request title like [MSHADE-XXX] - Fixes bug in ApproximateQuantiles,
    where you replace MSHADE-XXX with the appropriate JIRA issue. Best practice
    is to use the JIRA issue title in the pull request title and in the first line of the
    commit message.
  • Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
  • Run mvn clean verify to make sure basic checks pass. A more thorough check will
    be performed on your pull request automatically.
  • You have run the integration tests successfully (mvn -Prun-its clean verify).

If your pull request is about ~20 lines of code you don't need to sign an
Individual Contributor License Agreement if you are unsure please ask on the developers list.

To make clear that you license your contribution under
the Apache License Version 2.0, January 2004
you have to acknowledge this by using the following check-box.

@nielsbasjes nielsbasjes changed the title [MSHADE 36] Use reduced dependencies [MSHADE-36] Use reduced dependencies Aug 27, 2019


This comment has been minimized.

Copy link

commented Aug 27, 2019

I noticed that there will be a conflict with #22 because I moved the creation of the dpr to a slightly different place (more forward instead of more backward).

throw new IllegalStateException( "The pom.xml still contains a reference to the org.codehaus.plexus dependency");


This comment has been minimized.

Copy link

Tibor17 Aug 30, 2019


Pls call this in finally {} block.
It gives at least some guarantee that we do not have open streams when deleting workspace on Jenkins, thx.

This comment has been minimized.

Copy link

nielsbasjes Aug 30, 2019


I've updated the script. Please check if this is what you meant.

@nielsbasjes nielsbasjes force-pushed the nielsbasjes:MSHADE-36-Use-Reduced-Dependencies branch from 6fd4581 to 08d08a6 Aug 30, 2019

@nielsbasjes nielsbasjes force-pushed the nielsbasjes:MSHADE-36-Use-Reduced-Dependencies branch from 08d08a6 to 6c25ac7 Aug 30, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
2 participants
You can’t perform that action at this time.