init();
// Create a node configuration
FactoryExtensionPoint modelFactories = registry.getExtensionPoint(FactoryExtensionPoint.class);
NodeConfigurationFactory configurationFactory = modelFactories.getFactory(NodeConfigurationFactory.class);
NodeConfiguration configuration = configurationFactory.createNodeConfiguration();
URL location = bundle.getEntry("/");
String uri = bundle.getSymbolicName();
configuration.setURI(uri).addContribution(uri, location);
if (compositeContent != null) {
configuration.addDeploymentComposite(uri, new StringReader(compositeContent));
} else {
String compositeURI = (String)bundle.getHeaders().get("SCA-Composite");
if (compositeURI == null) {
compositeURI = "OSGI-INF/sca/bundle.composite";
}
if (compositeURI != null) {
configuration.addDeploymentComposite(uri, compositeURI);
}
}
// Set the bundle
// configuration.getExtensions().add(bundle);
return configuration;