You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by pi song <pi...@gmail.com> on 2009/02/16 23:54:00 UTC

will maven-dependency-tree API be replaced in Maven3?

I have just noticed that Maven3 is on the way. The new dependency resolver
really looks very interesting. Just curious how would that affect
maven-shared/maven-dependency-tree. Will this API stay the same or be
replaced?
Pi Song

Re: will maven-dependency-tree API be replaced in Maven3?

Posted by Oleg Gusakov <ol...@gmail.com>.
Additional clarifications:

Oleg Gusakov wrote:
>
>
> pi song wrote:
>> I just had a look at Mercury artifact resolver. It currently returns a list
>> of artifacts.
>>   
> Mercury has the following resolution APIs - see DependencyBuilder 
> interface:
I became so addicted to m2eclipse that completely forgot that not all 
folks may be using it. Just in that case: DependencyBuilder is in the 
mercury-md-sat project; default implementation - DependencyTreeBuilder 
is obtained from a factory DependencyBuilderFactory.
> - buildTree - creates a full metadata tree
> - resolveConflicts has two flavors
>   -- List<ArtifactMetadata> resolveConflicts( MetadataTreeNode root ) 
> to create the classpath set
>   -- MetadataTreeNode resolveConflictsAsTree( MetadataTreeNode root ) 
> for tool integration, reduces the full tree into resolved tree
There are other - combined APIs, like
List<ArtifactMetadata> resolveConflicts(
                                          ArtifactScopeEnum   scope
                                        , ArtifactQueryList artifacts
                                        , ArtifactInclusionList inclusions
                                        , ArtifactExclusionList exclusions
                                        )
This is a one call that accepts a list of artifacts and returns 
transitively resolved list ready for classpath consumption.

I think there is at least a need for:
- transitive true/false flag
- a similar tool integration TI call that would return a tree instead of 
list

Please remember - the original intent of Mercury was to create a library 
that could be consumed by Maven as well as other clients. As such - it 
does not know too much about Maven specifics. And we can write Maven 
adapters to expose it via familiar constructs. But not too many as it 
affects performance :)

Thanks,
Oleg
>
> At this stage APIs are experimental (it's still alpha product) and are 
> subjected to change as we go on with Maven integration.
>
> Please feel free to register any suggestions/requirements in Mercury jira:
> http://jira.codehaus.org/browse/MERCURY
>
> Thanks,
> Oleg
>
>
>
>> I think you will need a middle man to help expose that list as simplified
>> tree anyway (for plug-in developers).
>>
>> Am I right? Just want to understand a bit more.
>>
>> Pi Song
>>
>> On Tue, Feb 17, 2009 at 8:05 PM, Mark Hobson <ma...@gmail.com> wrote:
>>
>>   
>>> 2009/2/16 pi song <pi...@gmail.com>:
>>>     
>>>> I have just noticed that Maven3 is on the way. The new dependency
>>>>       
>>> resolver
>>>     
>>>> really looks very interesting. Just curious how would that affect
>>>> maven-shared/maven-dependency-tree. Will this API stay the same or be
>>>> replaced?
>>>>       
>>> I'd personally be in favour of mercury superseding
>>> maven-dependency-tree.  It only existed to provide a tree API around
>>> the pre-existing event API, and since mercury is tree-based it should
>>> hopefully now be rather redundant.
>>>
>>> Mark
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>>> For additional commands, e-mail: dev-help@maven.apache.org
>>>
>>>
>>>     
>>
>>   

Re: will maven-dependency-tree API be replaced in Maven3?

Posted by Oleg Gusakov <ol...@gmail.com>.

pi song wrote:
> I just had a look at Mercury artifact resolver. It currently returns a list
> of artifacts.
>   
Mercury has the following resolution APIs - see DependencyBuilder interface:
- buildTree - creates a full metadata tree
- resolveConflicts has two flavors
  -- List<ArtifactMetadata> resolveConflicts( MetadataTreeNode root ) to 
create the classpath set
  -- MetadataTreeNode resolveConflictsAsTree( MetadataTreeNode root ) 
for tool integration, reduces the full tree into resolved tree

At this stage APIs are experimental (it's still alpha product) and are 
subjected to change as we go on with Maven integration.

Please feel free to register any suggestions/requirements in Mercury jira:
http://jira.codehaus.org/browse/MERCURY

Thanks,
Oleg



> I think you will need a middle man to help expose that list as simplified
> tree anyway (for plug-in developers).
>
> Am I right? Just want to understand a bit more.
>
> Pi Song
>
> On Tue, Feb 17, 2009 at 8:05 PM, Mark Hobson <ma...@gmail.com> wrote:
>
>   
>> 2009/2/16 pi song <pi...@gmail.com>:
>>     
>>> I have just noticed that Maven3 is on the way. The new dependency
>>>       
>> resolver
>>     
>>> really looks very interesting. Just curious how would that affect
>>> maven-shared/maven-dependency-tree. Will this API stay the same or be
>>> replaced?
>>>       
>> I'd personally be in favour of mercury superseding
>> maven-dependency-tree.  It only existed to provide a tree API around
>> the pre-existing event API, and since mercury is tree-based it should
>> hopefully now be rather redundant.
>>
>> Mark
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> For additional commands, e-mail: dev-help@maven.apache.org
>>
>>
>>     
>
>   

Re: will maven-dependency-tree API be replaced in Maven3?

Posted by Milos Kleint <mk...@gmail.com>.
not plugin devs only. I've started using dependency-tree component in
netbeans maven support extensively as well. It's very convenient..

Milos

On Tue, Feb 17, 2009 at 1:20 PM, pi song <pi...@gmail.com> wrote:
> I just had a look at Mercury artifact resolver. It currently returns a list
> of artifacts.
> I think you will need a middle man to help expose that list as simplified
> tree anyway (for plug-in developers).
>
> Am I right? Just want to understand a bit more.
>
> Pi Song
>
> On Tue, Feb 17, 2009 at 8:05 PM, Mark Hobson <ma...@gmail.com> wrote:
>
>> 2009/2/16 pi song <pi...@gmail.com>:
>> > I have just noticed that Maven3 is on the way. The new dependency
>> resolver
>> > really looks very interesting. Just curious how would that affect
>> > maven-shared/maven-dependency-tree. Will this API stay the same or be
>> > replaced?
>>
>> I'd personally be in favour of mercury superseding
>> maven-dependency-tree.  It only existed to provide a tree API around
>> the pre-existing event API, and since mercury is tree-based it should
>> hopefully now be rather redundant.
>>
>> Mark
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>> For additional commands, e-mail: dev-help@maven.apache.org
>>
>>
>

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


Re: will maven-dependency-tree API be replaced in Maven3?

Posted by pi song <pi...@gmail.com>.
I just had a look at Mercury artifact resolver. It currently returns a list
of artifacts.
I think you will need a middle man to help expose that list as simplified
tree anyway (for plug-in developers).

Am I right? Just want to understand a bit more.

Pi Song

On Tue, Feb 17, 2009 at 8:05 PM, Mark Hobson <ma...@gmail.com> wrote:

> 2009/2/16 pi song <pi...@gmail.com>:
> > I have just noticed that Maven3 is on the way. The new dependency
> resolver
> > really looks very interesting. Just curious how would that affect
> > maven-shared/maven-dependency-tree. Will this API stay the same or be
> > replaced?
>
> I'd personally be in favour of mercury superseding
> maven-dependency-tree.  It only existed to provide a tree API around
> the pre-existing event API, and since mercury is tree-based it should
> hopefully now be rather redundant.
>
> Mark
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>

Re: will maven-dependency-tree API be replaced in Maven3?

Posted by Jason van Zyl <jv...@sonatype.com>.
On 17-Feb-09, at 4:05 AM, Mark Hobson wrote:

> 2009/2/16 pi song <pi...@gmail.com>:
>> I have just noticed that Maven3 is on the way. The new dependency  
>> resolver
>> really looks very interesting. Just curious how would that affect
>> maven-shared/maven-dependency-tree. Will this API stay the same or be
>> replaced?
>
> I'd personally be in favour of mercury superseding
> maven-dependency-tree.  It only existed to provide a tree API around
> the pre-existing event API, and since mercury is tree-based it should
> hopefully now be rather redundant.
>

I think you could actually start a sandbox in mercury if you wanted to  
try and migrate any of your tools over. Oleg could most likely help  
you insofar as pointing out what exists in Mercury and what you have  
that's still additional.

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

Thanks,

Jason

----------------------------------------------------------
Jason van Zyl
Founder,  Apache Maven
jason at sonatype dot com
http://twitter.com/jvanzyl
----------------------------------------------------------

We know what we are, but know not what we may be.

   -- Shakespeare


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


Re: will maven-dependency-tree API be replaced in Maven3?

Posted by Mark Hobson <ma...@gmail.com>.
2009/2/16 pi song <pi...@gmail.com>:
> I have just noticed that Maven3 is on the way. The new dependency resolver
> really looks very interesting. Just curious how would that affect
> maven-shared/maven-dependency-tree. Will this API stay the same or be
> replaced?

I'd personally be in favour of mercury superseding
maven-dependency-tree.  It only existed to provide a tree API around
the pre-existing event API, and since mercury is tree-based it should
hopefully now be rather redundant.

Mark

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


Re: will maven-dependency-tree API be replaced in Maven3?

Posted by Brian Fox <br...@reply.infinity.nu>.
I have it on my todo to integrate mercury into the dependency plugin.  
Most of the shared component will be superceded by mercury. It's too  
early to say if the Interface  will change or not

--Brian (mobile)


On Feb 16, 2009, at 5:54 PM, pi song <pi...@gmail.com> wrote:

> I have just noticed that Maven3 is on the way. The new dependency  
> resolver
> really looks very interesting. Just curious how would that affect
> maven-shared/maven-dependency-tree. Will this API stay the same or be
> replaced?
> Pi Song

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