Maven 2 & 3

Transitive DepMan not working (per MNG-1577) [use case attached]

Details

  • Number of attachments :
    1

Description

When working with the example use case described by Carlos on the MNG-1577 thread.
http://www.nabble.com/Re%3A--vote--MNG-1577-as-the-default-behavior-p9506667s177.html

What about this use case for transitive dependencyManagement? has been tested?

A -> B -> C -> D

C depends on D 1.0
B has D 2.0 in dependencyManagement, no D in dependencies

A should get D 2.0 

It was discovered that this does not work.
Sample Project / Use Case is attached. (655 bytes)

Issue Links

Activity

Hide
Joakim Erdfelt added a comment -

This will likely not be fixed for maven 2.0.x

Instead it will be taken as an example use case for the 2.1 artifact resolution specification.
http://docs.codehaus.org/display/MAVEN/Maven+2.1+Artifact+Resolution+Specification

Show
Joakim Erdfelt added a comment - This will likely not be fixed for maven 2.0.x Instead it will be taken as an example use case for the 2.1 artifact resolution specification. http://docs.codehaus.org/display/MAVEN/Maven+2.1+Artifact+Resolution+Specification
Hide
Joakim Erdfelt added a comment -

The integration test IT0121 demonstrates this use case.

Show
Joakim Erdfelt added a comment - The integration test IT0121 demonstrates this use case.
Hide
Joakim Erdfelt added a comment -

Another use case.

You have 4 projects. A,B,C,D

You have the following defined. (where notation is in the form [Project] -> [Dependency])

A -> B
A -> C
B -> D
C -> D

This forms a graph shaped like a diamond.

The following dependency management sections are defined in the above graph.
B has a depMan that says D version 2.0
C has a depMan that says D version 1.0

What version of D is in use at project A ?

Show
Joakim Erdfelt added a comment - Another use case. You have 4 projects. A,B,C,D You have the following defined. (where notation is in the form [Project] -> [Dependency]) A -> B A -> C B -> D C -> D This forms a graph shaped like a diamond. The following dependency management sections are defined in the above graph. B has a depMan that says D version 2.0 C has a depMan that says D version 1.0 What version of D is in use at project A ?
Hide
Patrick Schneider added a comment -

In my opinion of the diamond graph above, we should warn the user and select the latest version of the dependency.

Thoughts?

Show
Patrick Schneider added a comment - In my opinion of the diamond graph above, we should warn the user and select the latest version of the dependency. Thoughts?
Hide
Sven Ludwig added a comment -

Just thinking about it. The current documentation says at http://maven.apache.org/pom.html#Dependency_Management :

"In addition, the version and scope of artifacts which are incorporated from transitive dependencies may also be controlled by specifying them in a dependency management section."

Show
Sven Ludwig added a comment - Just thinking about it. The current documentation says at http://maven.apache.org/pom.html#Dependency_Management : "In addition, the version and scope of artifacts which are incorporated from transitive dependencies may also be controlled by specifying them in a dependency management section."

People

Vote (2)
Watch (3)

Dates

  • Created:
    Updated: