【发布时间】:2020-05-06 15:52:39
【问题描述】:
我已经阅读了许多关于createReducedDependencyPom 和maven-shade-plugin 的资料:
- Is dependency-reduced-pom.xml automatically used instead of pom.xml?
- What is the purpose of dependency-reduced-pom.xml generated by the shade plugin?
- Maven shade plugin adding dependency-reduced-pom.xml to base directory
- https://maven.apache.org/plugins/maven-shade-plugin/shade-mojo.html#createDependencyReducedPom
我知道它将创建一个 pom,其中删除了阴影的依赖项,因此阴影 jar 上的下游依赖项不会再次处理可从阴影 jar 访问的那些依赖项。
但是,我无法理解在什么情况下会将默认值 (true) 更改为 false。
谁能提供一个什么时候有用的例子?
【问题讨论】:
-
可能会通过属性覆盖值,这取决于不同的因素,例如如果是调试等的测试环境。
标签: java maven maven-shade-plugin