You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by sverhagen <ve...@sander.com> on 2008/09/19 00:19:49 UTC

Why am I not the boss of my own dependency versions???????

Hi.

We've recently switched from one dependency strategy for our internal
dependencies to another:
- "Old": all modules define <dependency>'s without <version>'s and inherit
all the same parent with a <dependencyManagement> section that defines
<version>'s for all modules, e.g. as 0.0.7.
- "New": all modules define their own <dependency>'s and <version>'s as
ranges, e.g. as [0.0.7,), and do no longer inherit a dependency management
section

We're slowly releasing this into our system. (We can't release everything at
once, since a number of modules are worked on hence unstable.)

Now we have a module A with a <dependency> on B-0.1.4 (and some more on C,
D, ...). From pure anger I've defined the dependency on B as [0.1.4], which
I always thought was a very strong way of expressing a version. When I build
A, I would expect Maven to either give me a B-0.1.4 or COMPLAIN about it.
Instead I'm getting an older version, say 0.0.6 (which does not fit the
range I've defined oh-so near-by). When I look in dependency:tree, it shows
me B as direct dependency of A (correct), with version 0.0.6 (supposedly
incorrect) without giving any particulars like "managed from".

A is of the "new" regime, the others mixed. All versions of B are from the
"old" regime.

Why am I not the boss of my own dependency versions???????

Thanks.
-- 
View this message in context: http://www.nabble.com/Why-am-I-not-the-boss-of-my-own-dependency-versions--------tp19562794p19562794.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Why am I not the boss of my own dependency versions???????

Posted by Michael McCallum <gh...@apache.org>.
Is there any chance you can post a simple example... or perhaps the output of 

mvn dependency:resolve -X

I use ranges in the way you are describing and do not and have not experienced 
any problems like that...

however I have not dependencyManagement sections in any of my transitions...

On Fri, 19 Sep 2008 10:19:49 sverhagen wrote:
> Hi.
>
> We've recently switched from one dependency strategy for our internal
> dependencies to another:
> - "Old": all modules define <dependency>'s without <version>'s and inherit
> all the same parent with a <dependencyManagement> section that defines
> <version>'s for all modules, e.g. as 0.0.7.
> - "New": all modules define their own <dependency>'s and <version>'s as
> ranges, e.g. as [0.0.7,), and do no longer inherit a dependency management
> section
>
> We're slowly releasing this into our system. (We can't release everything
> at once, since a number of modules are worked on hence unstable.)
>
> Now we have a module A with a <dependency> on B-0.1.4 (and some more on C,
> D, ...). From pure anger I've defined the dependency on B as [0.1.4], which
> I always thought was a very strong way of expressing a version. When I
> build A, I would expect Maven to either give me a B-0.1.4 or COMPLAIN about
> it. Instead I'm getting an older version, say 0.0.6 (which does not fit the
> range I've defined oh-so near-by). When I look in dependency:tree, it shows
> me B as direct dependency of A (correct), with version 0.0.6 (supposedly
> incorrect) without giving any particulars like "managed from".
>
> A is of the "new" regime, the others mixed. All versions of B are from the
> "old" regime.
>
> Why am I not the boss of my own dependency versions???????
>
> Thanks.



-- 
Michael McCallum
Enterprise Engineer
mailto:gholam@apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org