Package org.apache.geronimo.kernel.config

Examples of org.apache.geronimo.kernel.config.ConfigurationManager.unload()


        } catch (InstanceNotFoundException e) {
            throw new NoSuchConfigException(e);
        } catch (InvalidConfigException e) {
            throw (IllegalStateException) new IllegalStateException().initCause(e);
        }
        configurationManager.unload(configID);
    }

    public int getConfigurationState(URI configID) throws NoSuchConfigException {
        ConfigurationManager configurationManager = getConfigurationManager();
         try {
View Full Code Here


            } catch (Exception e) {
                throw new DeploymentException("Unable to copy domain and server from parent configuration", e);
            } finally {
                if (loaded) {
//                    we need to unload again so the loadedAncestors list will be in the correct order to start configs.
                    configurationManager.unload(parent);
                }
            }
        } catch (Exception e) {
            throw new DeploymentException("Unable to load first parent of configuration " + configurationData.getId(), e);
        } finally {
View Full Code Here

                                inherited.add(nonOverridableClasses[i]);
                            }
                        }
                    } finally {
                        if (loaded) {
                            configurationManager.unload(uri);
                        }
                    }
                }
            } catch (DeploymentException e) {
                throw e;
View Full Code Here

                Collections.reverse(loadedAncestors);
                for (Iterator iterator = loadedAncestors.iterator(); iterator.hasNext();) {
                    URI configID = (URI) iterator.next();
                    if(configurationManager.isLoaded(configID)) {
                        try {
                            configurationManager.unload(configID);
                        } catch (NoSuchConfigException e) {
                            throw new DeploymentException("Could not find a configuration we previously loaded! " + configID, e);
                        }
                    }
                }
View Full Code Here

                                } else {
                                    throw gnf;
                                }
                            }
                        }
                        configurationManager.unload(moduleID);
                        updateStatus("Module "+moduleID+" unloaded.");
                    } catch (InternalKernelException e) {
                        // this is cause by the kernel being already shutdown
                    } catch (NoSuchConfigException e) {
                        // module was already undeployed - just continue
View Full Code Here

                        configurationManager.stop(moduleID);
                    } catch (InvalidConfigException e) {
                        updateStatus("Module "+moduleID+" is not running.");
                        continue;
                    }
                    configurationManager.unload(moduleID);
                    addModule(module);
                }
            } finally {
                ConfigurationUtil.releaseConfigurationManager(kernel, configurationManager);
            }
View Full Code Here

                        if(e.getGBeanName().equals(configName)) {
                            // The module isn't running -- that's OK
                        } else throw e;
                    }
                    try {
                        configurationManager.unload(configID);
                        updateStatus("Unloaded "+configID);
                    } catch(InternalKernelException e) {
                        Exception cause = (Exception)e.getCause();
                        if(cause instanceof NoSuchConfigException) {
                            // The modules isn't loaded -- that's OK
View Full Code Here

                    configurationManager.start(uri);
                }
                messageStatus = "Started application<br /><br />";
            } else if (STOP_ACTION.equals(action)) {
                configurationManager.stop(configID);
                configurationManager.unload(configID);
                messageStatus = "Stopped application<br /><br />";
            } else if (UNINSTALL_ACTION.equals(action)) {
                uninstallConfig(actionRequest);
                messageStatus = "Uninstalled application<br /><br />";
            } else {
View Full Code Here

                if (configManager.isLoaded(configURI)) {
                    int state = kernel.getGBeanState(Configuration.getConfigurationObjectName(configURI));
                    if (state == State.RUNNING.toInt()) {

                        configManager.stop(configURI);
                        configManager.unload(configURI);
                    }
                }
                kernel.invoke(configStore, UNINSTALL_METHOD, new Object[]{configURI}, UNINSTALL_SIG);
            }
        }
View Full Code Here

            fail();
        } catch (InstanceNotFoundException e) {
            // ok
        }
        assertEquals(new Integer(State.STOPPED.toInt()), mbServer.getAttribute(configName, "state"));
        configurationManager.unload(configName);
        assertFalse(mbServer.isRegistered(configName));
    }

    protected void setUp() throws Exception {
        kernel = new Kernel("test.kernel", "geronimo");
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.