Package org.apache.geronimo.kernel

Examples of org.apache.geronimo.kernel.Kernel.shutdown()


        Kernel kernel = new BasicKernel("Assembly");
        try {
            PluginInstallerGBean installer = new PluginInstallerGBean(targetRepositoryPath, targetServerPath, servers, kernel, getClass().getClassLoader());
            installer.install(pluginList, sourceRepo, true, null, null, downloadPoller);
        } finally {
            kernel.shutdown();
        }
        log.info("Installed plugins: ");
        for (Artifact artifact: downloadPoller.getInstalledConfigIDs()) {
            log.info("    " + artifact);
        }
View Full Code Here


    }

    public void stop(BundleContext bundleContext) throws Exception {
        if (configurationActivator == null) {
            Kernel kernel = (Kernel) bundleContext.getService(kernelRegistration.getReference());
            kernel.shutdown();
            kernelRegistration.unregister();
            kernelRegistration = null;
        } else {
            configurationActivator.stop(bundleContext);
        }
View Full Code Here

                    kernel,
                    bundleContext);

            installer.install(pluginList, localSourceRepository, true, null, null, downloadPoller);
        } finally {
            kernel.shutdown();
        }
        return downloadPoller;
    }

    public void mergeOverrides(String server, AttributesType overrides) throws InvalidGBeanException, IOException {
View Full Code Here

    }

    public void stop(BundleContext bundleContext) throws Exception {
        Kernel kernel = (Kernel) bundleContext.getService(kernelRegistration.getReference());
        kernel.shutdown();
        kernelRegistration.unregister();
        kernelRegistration = null;
    }
}
View Full Code Here

                }
            }
        } catch (Exception e) {
            throw new MojoExecutionException("Could not use plugin installer bean", e);
        } finally {
            kernel.shutdown();           
            try {
                bundleContext.getBundle().stop();
            } catch (BundleException e) {
                // ignore
            }
View Full Code Here

        getLog().debug("Deploying...");

        AbstractName deployer = locateDeployer(kernel);
        invokeDeployer(kernel, deployer, targetConfigStoreAName.toString());
        //use a fresh kernel for each module
        kernel.shutdown();
        kernel = null;
        Framework framework = (Framework) bundleContext.getBundle();
        framework.stop();
        getLog().debug("Waiting for shutdown (up to 5 minutes)...");
        framework.waitForStop(60 * 5 * 1000);
 
View Full Code Here

        log.debug("Deploying...");

        AbstractName deployer = locateDeployer(kernel);
        invokeDeployer(kernel, deployer, targetConfigStoreAName.toString());
        //use a fresh kernel for each module
        kernel.shutdown();
        kernel = null;
    }

    /**
     * Create a Geronimo Kernel to contain the deployment configurations.
View Full Code Here

        log.debug("Deploying...");

        AbstractName deployer = locateDeployer(kernel);
        invokeDeployer(kernel, deployer, targetConfigStoreAName.toString());
        //use a fresh kernel for each module
        kernel.shutdown();
        kernel = null;
    }

    /**
     * Create a Geronimo Kernel to contain the deployment configurations.
View Full Code Here

                System.out.println("\nCould not communicate with the server.  The server may not be running or the port number may be incorrect.");
            }
            if (kernel != null) {
                System.out.println("Server found.");
                System.out.println("Server shutdown started");
                kernel.shutdown();
                System.out.println("Server shutdown completed");
            }
        } catch (Exception e) {
            e.printStackTrace();
            return 1;
View Full Code Here

                    kernel,
                    classLoader);

            installer.install(pluginList, localSourceRepository, true, null, null, downloadPoller);
        } finally {
            kernel.shutdown();
        }
        return downloadPoller;
    }

    public void mergeOverrides(String server, AttributesType overrides) throws InvalidGBeanException, IOException {
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.