@Override
public void execute(CrankstartContext crankstartContext, CrankstartCommandLine commandLine) throws Exception {
// TODO this should work
// FrameworkFactory frameworkFactory = java.util.ServiceLoader.load(FrameworkFactory.class).iterator().next();
final FrameworkFactory frameworkFactory = (FrameworkFactory)getClass().getClassLoader().loadClass("org.apache.felix.framework.FrameworkFactory").newInstance();
crankstartContext.setOsgiFramework(frameworkFactory.newFramework(crankstartContext.getOsgiFrameworkProperties()));
crankstartContext.getOsgiFramework().start();
final int nBundles = crankstartContext.getOsgiFramework().getBundleContext().getBundles().length;
log.info("OSGi framework started, {} bundles installed", nBundles);
// Unless specified otherwise, stop processing the crankstart file if this is not the first