OSGi Bundle Repository

Handle latestyes
Handle publishno
since 2.3 This resolver is one of the resolver which supports OSGi™ dependencies. As part of the OSGi specification resides the OBR (OSGi Bundle Repository). The OBR defines the aggregation of the OSGi metadata of every bundle included in an repository. So contrary to the other resolvers, this resolver needs to get the descriptor of the repository (an obr.xml) before starting to resolve modules.


This resolver shares the common attributes of composite resolvers.
repoXmlURLthe URL of the obr.xml to load. Yes
repoXmlFilethe local path of the obr.xml to load. Yes
requirementStrategydefines how strict should be the OSGi resolution. Can be one of first or noambiguity No, default to noambiguity
metadataTtlthe time in milliseconds the obr.xml is considered up to date No, default to 3600000 (1 hour)
forceMetadataUpdateforce the update of the obr.xml without checking its freshness No, default to false
The requirement strategy is defining how the resolver should behave in front of several choices. In the OSGi dependency model, an Import-Package requirement can be satisfied by several different bundles. So when resolving such requirement, Ivy will first look into the already resolved bundles if one provides that package. If it fails to find one, then two behaviours can occur:
  • if the requirement strategy is first, among the bundles statifying the requirement, it will shoose the first one. A warn will be logged ahout the choice Ivy has to arbitrarily do.
  • if the requirement strategy is noambiguity, Ivy will make the resolution fail.


<obr name="felix-repo" repoXmlURL="http://felix.apache.org/obr/releases.xml" />
A simple repository configured to use the Felix OBR.

<obr name="my-osgi-repo" repoXmlFile="${ivy.settings.dir}/obr/obr.xml" requirementStrategy="first" />
A local repository which is trusted to always provide correct dependency for the Import-Package requirements.