Hi Bob,
So the important thing to remember is that the Maven dependency model and the Bndtools workspace Gradle dependency model are completely different.
In Maven your dependencies are specified in your pom file, and are found in the repositories that are also configured in your pom file. Often the repositories and versions of dependencies are managed in a single place (your parent pom) and inherited. Maven has an implicit repository (Maven Central) which is where you find most things, but some dependencies (for example the OSGi R7 release candidates) live in other repositories.
In a Bnd workspace build “repositories" are defined in the cnf project - there is no such thing as an implicit repository and your dependencies can only come from repositories that have been configured. There are many different types of repository:
- Local repositories such as a file repository or an indexed repository. These are folders which physically contain the jars that you’re going to use as dependencies. You can drag more bundles into these repositories as you need them
- Local/Remote OSGi repositories (such as a Fixed Indexed Repository). These repositories point at an OSGi standard index file and provide access to the bundles listed in the repository index
- Maven-style repositories - there are two main types
- Maven Repositories (for example “Central” in the https://github.com/bndtools/workspace template). These retrieve dependencies from a Maven repository (usually a nexus instance) but only those dependencies listed in the index file (for example “Central” has a central.maven file). This index file lists the GAV coordinates of the dependencies that should be in the bnd repository
- POM repositories - These repositories point at a POM file, and include all of the dependencies (including transitive dependencies) listed in the POM.
So, to come back to your problem. The reason that you could access the R7 APIs, implementations, and other dependencies in the Maven-based example is that the parent pom had been configured to provide access to those things using the OSGi snapshot repository and the enRoute indexes. The Bndtools workspace template that you have used knows nothing of these things (having been set up for OSGi R6) and provides access to a limited set of bundles via its configured repositories. This repository configuration lives in the cnf folder (you can see build.bnd in there) not in the Eclipse preferences as these repositories are used in CI as well as the IDE.
If you want to access R7 API bundles in your Bndtools workspace then you will need to set up additional repositories containing those bundles. That may take the form of an additional Maven Repository, one or more POM repositories, or a local repository where you put the bundles.
Best Regards,
Tim