Skip to content

Conversation

@cstamas
Copy link
Member

@cstamas cstamas commented Feb 11, 2026

To have a place to direct users asking wrong questions, but also to align "lingo" we use.

To have a place to direct users asking wrong questions,
but also to align "lingo" we use.
@cstamas cstamas added this to the 2.0.15 milestone Feb 11, 2026
@cstamas cstamas self-assigned this Feb 11, 2026
@cstamas cstamas marked this pull request as ready for review February 11, 2026 17:29
@cstamas cstamas requested a review from elharo February 11, 2026 22:34
under the License.
-->

Maven Artifact Resolver (former Aether) is central piece of Maven, and thus,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a central

-->

Maven Artifact Resolver (former Aether) is central piece of Maven, and thus,
is many times target of questions and curiosity how it actually works under the hood.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

delete ", and thus,
is many times target of questions and curiosity how it actually works under the hood."


Maven Artifact Resolver (former Aether) is central piece of Maven, and thus,
is many times target of questions and curiosity how it actually works under the hood.
This document tries to shed some light on this topic, and explain the main concepts
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shed some light on this topic --> explain how resolver works under the hood

This document tries to shed some light on this topic, and explain the main concepts
and building blocks of Resolver.

One important aspect of Resolver is that itself, alone is "incomplete". Integrating application, like Maven is
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One important aspect of Resolver is that itself, alone --> Resolver along


One important aspect of Resolver is that itself, alone is "incomplete". Integrating application, like Maven is
the one that provides the "glue" (models) and logic how to resolve versions, ranges, build effective models.
Hence, Resolver itself, alone is unusable. To make it usable, one needs to complement it with models and
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hence, Resolver itself, alone is unusable. To make it usable, one needs to complement it with models and
implementations of missing components. Historically, Maven module completing Resolver is the
org.apache.maven:maven-resolver-provider module.

-->

By itself, Resolver is unusable. One needs to complement it with models and implementations of missing components. Historically, the Maven module completing Resolver is
org.apache.maven:maven-resolver-provider.

In general, steps "dependency graph collection" and "conflict resolution" are performed together, and lingo we use for that operation is "dependency collection".
The "flattening" and "artifact resolving" are also usually done together, and we use for those the term "artifact resolving".
To have the story more confusing, when all the steps are performed together is also called "dependency resolution".
Resolver API reflects this terminology and offers methods doing collection, resolution or both.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Resolve API

To have the story more confusing, when all the steps are performed together is also called "dependency resolution".
Resolver API reflects this terminology and offers methods doing collection, resolution or both.
*
* Method `CollectResult collectDependencies(RepositorySystemSession session, CollectRequest request)` performs only the collection step,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The method

Resolver API reflects this terminology and offers methods doing collection, resolution or both.
*
* Method `CollectResult collectDependencies(RepositorySystemSession session, CollectRequest request)` performs only the collection step,
as name suggests. Hence, only steps "collection" and "conflict resolution" are performed.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

its name
the steps

* Method `DependencyResult resolveDependencies(RepositorySystemSession session, DependencyRequest request)` performs both
collection and resolution steps.

Also, each subsequent step depends on the previous one, for example a "dirty graph" cannot be flattened (due possible cycles).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one. For example,

collection and resolution steps.

Also, each subsequent step depends on the previous one, for example a "dirty graph" cannot be flattened (due possible cycles).
And many times, what you want depends on your use case. For example, to investigate dependency graph, one may
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And many times --> Many times

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants