Examples of installBundle()


Examples of io.fabric8.utils.BundleUtils.installBundle()

    public void installBundles() throws BundleException {
        BundleUtils bundleUtils = new BundleUtils(bundleContext);
        Bundle bundleFabricCommands = bundleUtils.findBundle("io.fabric8.fabric-commands");
        if (bundleFabricCommands == null) {
            bundleFabricCommands = bundleUtils.installBundle("mvn:io.fabric8/fabric-commands/" + FabricConstants.FABRIC_VERSION);
        }
        bundleFabricCommands.start();
        Bundle bundleFabricAgent = bundleUtils.findBundle("io.fabric8.fabric-agent");

        if (nonManaged && bundleFabricAgent == null) {
View Full Code Here

Examples of org.apache.sling.ide.osgi.OsgiClient.installBundle()

                            monitor);
                    if (remoteVersion == null || remoteVersion.compareTo(embeddedVersion) < 0) {
                        InputStream contents = null;
                        try {
                            contents = supportBundle.openInputStream();
                            client.installBundle(contents, supportBundle.getName());
                        } finally {
                            IOUtils.closeQuietly(contents);
                        }
                        remoteVersion = embeddedVersion;
View Full Code Here

Examples of org.apache.sling.ide.osgi.OsgiClient.installBundle()

        EmbeddedArtifact toolingBundle = locator.loadToolingSupportBundle();

        OsgiClientFactory clientFactory = Activator.getDefault().getOsgiClientFactory();
        OsgiClient osgiClient = clientFactory.createOsgiClient(new RepositoryInfo(config.getUsername(), config
                .getPassword(), config.getUrl()));
        osgiClient.installBundle(toolingBundle.openInputStream(), toolingBundle.getName());
    }
}
View Full Code Here

Examples of org.apache.sling.ide.osgi.OsgiClient.installBundle()

                                } else {
                                    monitor.setTaskName("Installing bundle");
                                    InputStream contents = null;
                                    try {
                                        contents = supportBundle.openInputStream();
                                        client.installBundle(contents, supportBundle.getName());
                                    } finally {
                                        IOUtils.closeQuietly(contents);
                                    }
                                    deployedVersion = embeddedVersion;
                                    message = "Bundle version " + embeddedVersion + " installed";
View Full Code Here

Examples of org.iosgi.IsolatedFramework.installBundle()

        File f = new File(URI.create(location));
        ByteArrayOutputStream baos = new ByteArrayOutputStream();
        Streams.drain(new FileInputStream(f), baos).get();
        data = baos.toByteArray();
      }
      fw.installBundle(location, data);
      break;
    }
    case UNINSTALL: {
      Bundle b = admin.getBundle(location);
      if (b == null) {
View Full Code Here

Examples of org.jboss.osgi.framework.BundleManagement.installBundle()

                if (bundleFile != null) {
                    URL url = bundleFile.toURI().toURL();
                    BundleInfo info = BundleInfo.createBundleInfo(url);
                    Deployment dep = DeploymentFactory.createDeployment(info);
                    dep.setAutoStart(moduleMetaData.isStart());
                    serviceName = bundleManager.installBundle(serviceTarget, dep);
                }
                else {
                    ModuleLoader moduleLoader = Module.getBootModuleLoader();
                    Module module = moduleLoader.loadModule(identifier);
                    OSGiMetaData metadata = getModuleMetadata(module);
View Full Code Here

Examples of org.jboss.osgi.framework.BundleManagement.installBundle()

                }
                else {
                    ModuleLoader moduleLoader = Module.getBootModuleLoader();
                    Module module = moduleLoader.loadModule(identifier);
                    OSGiMetaData metadata = getModuleMetadata(module);
                    serviceName = bundleManager.installBundle(serviceTarget, module, metadata);
                }
                pendingServices.put(serviceName, moduleMetaData);
            }

            // Install a service that has a dependency on all pending bundle INSTALLED services
View Full Code Here

Examples of org.jboss.osgi.framework.BundleManagement.installBundle()

    public synchronized void start(StartContext context) throws StartException {
        log.infof("Installing deployment: %s", deployment);
        try {
            ServiceTarget serviceTarget = context.getChildTarget();
            BundleManagement bundleManager = injectedBundleManager.getValue();
            installedBundleName = bundleManager.installBundle(serviceTarget, deployment);
            injectedStartTracker.getValue().addInstalledBundle(installedBundleName, deployment);
        } catch (Throwable t) {
            throw new StartException("Failed to install deployment: " + deployment, t);
        }
    }
View Full Code Here

Examples of org.jboss.osgi.framework.BundleManager.installBundle()

            ServiceName serviceName;
            try {
                final BundleManager bundleManager = depUnit.getAttachment(OSGiConstants.BUNDLE_MANAGER_KEY);
                if (!deploymentTracker.isClosed() && deploymentTracker.hasDeploymentName(depUnit.getName())) {
                    restoreStorageState(phaseContext, deployment);
                    serviceName = bundleManager.installBundle(deployment, deploymentTracker.getBundleInstallListener());
                    deploymentTracker.registerBundleInstallService(serviceName);
                } else {
                    serviceName = bundleManager.installBundle(deployment, null);
                }
            } catch (BundleException ex) {
View Full Code Here

Examples of org.jboss.osgi.framework.BundleManagerService.installBundle()

        ServiceController<?> controller = context.getController();
        ROOT_LOGGER.debugf("Starting: %s in mode %s", controller.getName(), controller.getMode());
        try {
            ServiceTarget serviceTarget = context.getChildTarget();
            BundleManagerService bundleManager = injectedBundleManager.getValue();
            installedBundleName = bundleManager.installBundle(serviceTarget, deployment);
            injectedStartTracker.getValue().addInstalledBundle(installedBundleName, deployment);
        } catch (Throwable t) {
            throw new StartException(MESSAGES.failedToInstallDeployment(deployment), t);
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.