MavenCoordinates mavenId = MavenCoordinates.parse(identifier);
Requirement req = XRequirementBuilder.create(mavenId).getRequirement();
Collection<Capability> caps = repository.findProviders(req);
if (caps.isEmpty() == false) {
XResource resource = (XResource) caps.iterator().next().getResource();
XCapability ccap = (XCapability) resource.getCapabilities(ContentNamespace.CONTENT_NAMESPACE).get(0);
URL bundleURL = new URL((String) ccap.getAttribute(ContentNamespace.CAPABILITY_URL_ATTRIBUTE));
deployment = getDeploymentFromURL(bundleURL, identifier, level);
}
}
if (deployment == null)