Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aether-dev] Plugin mechanism for the ConflictResolver?

Oh gee .. I just sent out my double posting to the Aether list ... well anyway.

Well regarding my "has been working for years" probalby relates to the time I have been using it and that's about 5-6 years now. Since this has been around for a little longer than this, I think my statement is valid :-)

An example project demonstrating this would be the project in the Flexmojos testsuite that made me aware of this problem: 
https://github.com/chrisdutz/flexmojos/tree/flexmojos-7.x/flexmojos-testing/flexmojos-test-harness/projects/concept/copy-flex-resources
This version is the fixed version, which I "fixed" by explicitly defining the scope of the transitive dependency in the dependencyManagement section. But I don't really like this option ... it's sort of a hack to me.

Chris


-----Ursprüngliche Nachricht-----
Von: aether-dev-bounces@xxxxxxxxxxx [mailto:aether-dev-bounces@xxxxxxxxxxx] Im Auftrag von Benjamin Bentmann
Gesendet: Sonntag, 19. Oktober 2014 13:05
An: Aether project developer discussions; Maven Developers List
Betreff: Re: [aether-dev] Plugin mechanism for the ConflictResolver?

Hervé BOUTEMY wrote:

> this is a question for Aether :)
> [...]
> Le samedi 18 octobre 2014 11:23:28 Christofer Dutz a écrit :
>> While looking for the answer to your question, I noticed that the 
>> ConflictResolver seems to be using the JavaScopeDeriver which is of 
>> type ScopeDeriver to implement the scope derivation. It seems the 
>> JavaScopeDerives is the only implementation of ScopeDeriver. It seems 
>> that this is all part of Aether. So let me rephrase my question:
>>
>> Would it be possible to add additional ScopeResolvers to Aether?

I don't quite understand how this is "a question for Aether". There's an extension point in Aether called ScopeDeriver and it's the responsibility/power of the application to drop in whatever implementation suits its specific needs when setting up the RepositorySystemSession.

>> Le samedi 18 octobre 2014 08:52:34 Christofer Dutz a écrit :
>>> Im currently struggling with some changes introduced with Maven 3.1 
>>> explicitly regarding the ConflictResolver in conjunction with custom 
>>> scopes. I know that these are generally not supported, but they had 
>>> been working nicely for years. With Maven 3.1 it seems the scope of 
>>> transitive dependencies of custom scope artifacts are all flattened 
>>> to runtime.

It would be nice to share a runnable and self-contained example project demonstrating the issue (like the one attached I used for investigation).

AFAICT, the behavior seen with Maven 3.0.x is due to a bug in handling dependency cycles, Maven 3.1.x+ fixed this, bringing the derived/inherited scope back in line with what Maven 2.x produces. So when custom scopes "had been working nicely for years", I'm curious to know how exactly Flexmojos worked with Maven 2.x.


Benjamin


Back to the top