Package org.jboss.modules

Examples of org.jboss.modules.ModuleLoadException


            latch.countDown();
        }

        public ModuleSpec getModuleSpec() throws ModuleLoadException {
            if (startException != null)
                throw new ModuleLoadException(startException.getCause());
            return moduleSpec;
        }
View Full Code Here


        public ModuleSpec getModuleSpec() throws ModuleLoadException {
            if (moduleSpec != null)
                return moduleSpec;
            if (startException != null)
                throw new ModuleLoadException(startException.getCause());
            try {
                log.tracef("waiting for: %s", identifier);
                if (latch.await(2000, TimeUnit.MILLISECONDS) == false)
                    throw ServerMessages.MESSAGES.timeoutWaitingForModuleService(identifier);
            } catch (InterruptedException e) {
View Full Code Here

    @SuppressWarnings("unchecked")
    @Override
    public ModuleSpec findModule(ModuleIdentifier identifier) throws ModuleLoadException {
        ServiceController<ModuleSpec> controller = (ServiceController<ModuleSpec>) serviceContainer.getService(moduleSpecServiceName(identifier));
        if (controller == null) {
            throw new ModuleLoadException("Could not load module " + identifier + " as corresponding module spec service " + identifier + " was not found");
        }
        ModuleSpecLoadListener listener = new ModuleSpecLoadListener(identifier);
        controller.addListener(listener);
        return listener.getModuleSpec();
    }
View Full Code Here

        public ModuleSpec getModuleSpec() throws ModuleLoadException {
            if (moduleSpec != null)
                return moduleSpec;
            if (startException != null)
                throw new ModuleLoadException(startException.getCause());
            try {
                log.tracef("waiting for: %s", identifier);
                if (latch.await(2000, TimeUnit.MILLISECONDS) == false)
                    throw new ModuleLoadException("Timeout waiting for module service: " + identifier);
            } catch (InterruptedException e) {
                // ignore
            }
            return moduleSpec;
        }
View Full Code Here

        public ModuleSpec getModuleSpec() throws ModuleLoadException {
            if (moduleSpec != null)
                return moduleSpec;
            if (startException != null)
                throw new ModuleLoadException(startException.getCause());
            try {
                log.tracef("waiting for: %s", identifier);
                if (latch.await(2000, TimeUnit.MILLISECONDS) == false)
                    throw new ModuleLoadException("Timeout waiting for module service: " + identifier);
            } catch (InterruptedException e) {
                // ignore
            }
            return moduleSpec;
        }
View Full Code Here

    @Override
    protected ModuleSpec findModule(ModuleIdentifier moduleIdentifier) throws ModuleLoadException {
        ServiceController<ModuleSpec> controller = (ServiceController<ModuleSpec>) serviceContainer
                .getService(moduleSpecServiceName(moduleIdentifier));
        if (controller == null) {
            throw new ModuleLoadException("Could not load module " + moduleIdentifier
                    + " as corresponding module spec service " + moduleIdentifier + " was not found");
        }
        ModuleSpecLoadListener listener = new ModuleSpecLoadListener();
        controller.addListener(listener);
        if (listener.getModuleSpec() == null) {
            throw new ModuleLoadException("Could not load module " + moduleIdentifier
                    + " as corresponding module spec service " + moduleIdentifier + " was not up. State: "
                    + listener.getState());
        }
        return listener.getModuleSpec();
    }
View Full Code Here

                        ModuleIdentifier identifier = ModuleIdentifier.fromString(moduleSpec);
                        return loader.loadModule(identifier).getClassLoader();
                    }
                });
            } catch (PrivilegedActionException pae) {
                throw new ModuleLoadException(pae);
            }
        } else {
            ModuleLoader loader = Module.getCallerModuleLoader();
            ModuleIdentifier identifier = ModuleIdentifier.fromString(moduleSpec);
            return loader.loadModule(identifier).getClassLoader();
View Full Code Here

                        ModuleIdentifier identifier = ModuleIdentifier.fromString(moduleSpec);
                        return loader.loadModule(identifier).getClassLoader();
                    }
                });
            } catch (PrivilegedActionException pae) {
                throw new ModuleLoadException(pae);
            }
        } else {
            ModuleLoader loader = Module.getCallerModuleLoader();
            ModuleIdentifier identifier = ModuleIdentifier.fromString(moduleSpec);
            return loader.loadModule(identifier).getClassLoader();
View Full Code Here

                        ModuleIdentifier identifier = ModuleIdentifier.fromString(moduleSpec);
                        return loader.loadModule(identifier).getClassLoader();
                    }
                });
            } catch (PrivilegedActionException pae) {
                throw new ModuleLoadException(pae);
            }
        } else {
            ModuleLoader loader = Module.getCallerModuleLoader();
            ModuleIdentifier identifier = ModuleIdentifier.fromString(moduleSpec);
            return loader.loadModule(identifier).getClassLoader();
View Full Code Here

                        ModuleIdentifier identifier = ModuleIdentifier.create("org.jboss.as.security", "main");
                        return loader.loadModule(identifier).getClassLoader();
                    }
                });
            } catch (PrivilegedActionException pae) {
                throw new ModuleLoadException(pae);
            }
        } else {
            ModuleLoader loader = Module.getCallerModuleLoader();
            ModuleIdentifier identifier = ModuleIdentifier.create("org.jboss.as.security", "main");
            return loader.loadModule(identifier).getClassLoader();
View Full Code Here

TOP

Related Classes of org.jboss.modules.ModuleLoadException

Copyright © 2018 www.massapicom. 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.