bnd icon indicating copy to clipboard operation
bnd copied to clipboard

Track the evolution of the maven ecosystem cleanup effort

Open rotty3000 opened this issue 3 years ago • 1 comments

There is an effort to clean significant parts of the maven ecosystem in order to streamline dependencies, improve APIs and harden best practices.

https://cwiki.apache.org/confluence/display/MAVEN/Maven+Ecosystem+Cleanup

They've requested feedback about how the APIs might be improved (particularly w.r.t. the resolver) https://cwiki.apache.org/confluence/display/MAVEN/Maven+Missing+APIs.

Since bnd makes good use of maven and implements a deep set of functionality through it's maven plugins there is need to track the activity so that we can react as needed.

Usage

bnd builds on the OSGi resolver and repository specifications the notion of "assembly resolution"; where a collection of bundles capable of satisfying the initial input requirements (creating a closed set) with the goal of running the application fully assembled.

In order to greatly simplify this task for developers, reducing the overhead of manually creating OSGi repositories, bnd leverages the maven resolver to collect maven project (as well as optionally dependencyManagement) dependencies to implicitly create an OSGi repository on their behalf.

Use cases

With the above bnd can perform several operations such as:

  • producing an OSGi repository index for scenarios where such is still useful
  • validating the metadata of any bundle by confirming that within a given set of dependencies the bundle is itself resolvable
  • assembling a minimal set of dependencies capable of running integration tests (without the need for mocks)
  • creating an executable jar for an application, fully assemble and guaranteed to be a closed set of requirements

rotty3000 avatar Jan 28 '22 16:01 rotty3000

Bnd uses the maven resolver "API" here https://github.com/bndtools/bnd/blob/master/biz.aQute.bnd.maven/src/aQute/bnd/maven/lib/resolve/DependencyResolver.java#L188-L246 in biz.aQute.bnd.maven which is an upstream dependency of most bnd maven plugins all of which use resolution functions in some way (except the bnd-maven-plugin itself).

rotty3000 avatar Jan 28 '22 16:01 rotty3000