You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Chris Berry <ch...@gmail.com> on 2005/12/19 15:57:57 UTC

[m2] issue w/ dependency mediation

Greetings,
Yesterday I saw an issue w/ m2's dependency mediation. Some transitive
dependency wanted JUnit 3.7 and I'm assuming 3.8.1. Since this one was seen
first, it won. So, of course, my build broke. (Before you ask, I don't
directly declare the JUnit dependency in my POM because I have a "dependency
set" of commonly used dependencies ;-)

I'm wondering about the status of a couple of "Mediators"
1) A fail-fast-mediator would simply stop the build when conflicts occur.
IMHO, this would make the most sense as the default mediator since it makes
debugging a lot easier. No head scratching.
2) A use-latest-mediator would be my choice.

The use-first-found-mediator seems somewhat illogical to me??
Thanks,
-- Chris

Re: [m2] issue w/ dependency mediation

Posted by Brett Porter <br...@gmail.com>.
Actually, you're right - sorry. It will use 3.8.1 only.

If someone else specifies [3.7], then it will fail, but this isn't the
case here.

The other style of failure will also be added to 2.1.

- Brett

On 12/20/05, Chris Berry <ch...@gmail.com> wrote:
> Thanks Brett!!
> So [3.8.1] says "fail if any other version than 3.8.1 is found"??
> I thought it meant, use 3.8.1 only.
> Thanks,
> -- Chris
>
> On 12/19/05, Brett Porter <br...@gmail.com> wrote:
> >
> > Hi Chris,
> >
> > It's actually "use nearest", rather than first found, which is
> > basically the principle of you know better than your dependencies do
> > what you need :)
> >
> > 1) is already possible if the place where you assume 3.8.1 is
> > specified as [3.8.1], or perhaps [3.8,)
> >
> > 2) will be enabled in 2.1. It was on in the betas and without making
> > it configurable it was a little hard to deal with and unfortauntely
> > the configurable part missed the cut for 2.0.
> >
> > Cheers,
> > Brett
> >
> > On 12/20/05, Chris Berry <ch...@gmail.com> wrote:
> > > Greetings,
> > > Yesterday I saw an issue w/ m2's dependency mediation. Some transitive
> > > dependency wanted JUnit 3.7 and I'm assuming 3.8.1. Since this one was
> > seen
> > > first, it won. So, of course, my build broke. (Before you ask, I don't
> > > directly declare the JUnit dependency in my POM because I have a
> > "dependency
> > > set" of commonly used dependencies ;-)
> > >
> > > I'm wondering about the status of a couple of "Mediators"
> > > 1) A fail-fast-mediator would simply stop the build when conflicts
> > occur.
> > > IMHO, this would make the most sense as the default mediator since it
> > makes
> > > debugging a lot easier. No head scratching.
> > > 2) A use-latest-mediator would be my choice.
> > >
> > > The use-first-found-mediator seems somewhat illogical to me??
> > > Thanks,
> > > -- Chris
> > >
> > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
> >
>
>

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


Re: [m2] issue w/ dependency mediation

Posted by Chris Berry <ch...@gmail.com>.
Thanks Brett!!
So [3.8.1] says "fail if any other version than 3.8.1 is found"??
I thought it meant, use 3.8.1 only.
Thanks,
-- Chris

On 12/19/05, Brett Porter <br...@gmail.com> wrote:
>
> Hi Chris,
>
> It's actually "use nearest", rather than first found, which is
> basically the principle of you know better than your dependencies do
> what you need :)
>
> 1) is already possible if the place where you assume 3.8.1 is
> specified as [3.8.1], or perhaps [3.8,)
>
> 2) will be enabled in 2.1. It was on in the betas and without making
> it configurable it was a little hard to deal with and unfortauntely
> the configurable part missed the cut for 2.0.
>
> Cheers,
> Brett
>
> On 12/20/05, Chris Berry <ch...@gmail.com> wrote:
> > Greetings,
> > Yesterday I saw an issue w/ m2's dependency mediation. Some transitive
> > dependency wanted JUnit 3.7 and I'm assuming 3.8.1. Since this one was
> seen
> > first, it won. So, of course, my build broke. (Before you ask, I don't
> > directly declare the JUnit dependency in my POM because I have a
> "dependency
> > set" of commonly used dependencies ;-)
> >
> > I'm wondering about the status of a couple of "Mediators"
> > 1) A fail-fast-mediator would simply stop the build when conflicts
> occur.
> > IMHO, this would make the most sense as the default mediator since it
> makes
> > debugging a lot easier. No head scratching.
> > 2) A use-latest-mediator would be my choice.
> >
> > The use-first-found-mediator seems somewhat illogical to me??
> > Thanks,
> > -- Chris
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: [m2] issue w/ dependency mediation

Posted by Brett Porter <br...@gmail.com>.
Hi Chris,

It's actually "use nearest", rather than first found, which is
basically the principle of you know better than your dependencies do
what you need :)

1) is already possible if the place where you assume 3.8.1 is
specified as [3.8.1], or perhaps [3.8,)

2) will be enabled in 2.1. It was on in the betas and without making
it configurable it was a little hard to deal with and unfortauntely
the configurable part missed the cut for 2.0.

Cheers,
Brett

On 12/20/05, Chris Berry <ch...@gmail.com> wrote:
> Greetings,
> Yesterday I saw an issue w/ m2's dependency mediation. Some transitive
> dependency wanted JUnit 3.7 and I'm assuming 3.8.1. Since this one was seen
> first, it won. So, of course, my build broke. (Before you ask, I don't
> directly declare the JUnit dependency in my POM because I have a "dependency
> set" of commonly used dependencies ;-)
>
> I'm wondering about the status of a couple of "Mediators"
> 1) A fail-fast-mediator would simply stop the build when conflicts occur.
> IMHO, this would make the most sense as the default mediator since it makes
> debugging a lot easier. No head scratching.
> 2) A use-latest-mediator would be my choice.
>
> The use-first-found-mediator seems somewhat illogical to me??
> Thanks,
> -- Chris
>
>

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