Clone
Adam Murdoch
committed
on 21 Aug 16
Changed resolution of dependencies of Maven modules to attempt to select the fewest configurations of the target module as possible to give … Show more
Changed resolution of dependencies of Maven modules to attempt to select the fewest configurations of the target module as possible to give the correct result. Previously, every dependency of a Maven module would select the `compile`, `runtime` and `master` configurations of the target. Now, it will usually select only the `compile` configuration of the target when resolving the Maven module's `compile` configuration, and the `runtime` configuration of the target when resolving any others.

This changes means there are far fewer nodes and edges in the dependency graph in the case of resolving external dependencies from Maven repositories, which has an impact on resolution time. There is a breaking change here, in that the 'resolved configuration' resolution result will contain fewer configuration nodes. It will still contain the same modules and artifacts, in the same order.

This change also changes the way that configurations are selected when a Maven module consumes an Ivy module or a Gradle project (through project substitution). Previously, _all_ of the public configurations of the target would be selected when _any_ of the `compile`, `runtime` or `master` configuration were not defined by the target. Given that the core plugins do not define a `master` configuration, this means that all public configurations, such as custom configurations defined in a build script, would be selected and their dependencies and artifacts included in the result. Now, when `compile` or `runtime` are missing, the `default` configuration is selected instead. A missing or empty `master` configuration is ignored.

Show less

master + 471 more