Package org.apache.hivemind

Examples of org.apache.hivemind.ApplicationRuntimeException


            return result;
        }
        catch (Exception ex)
        {
            throw new ApplicationRuntimeException(ex);
        }

    }
View Full Code Here


        ServiceImplementationConstructor constructor = _servicePoint.getServiceConstructor();
        Object result = constructor.constructCoreServiceImplementation();

        if (result == null)
            throw new ApplicationRuntimeException(ServiceModelMessages
                    .factoryReturnedNull(_servicePoint), constructor.getLocation(), null);

        // The factory should provice something that either implements the service interface
        // or the declared interface. Again, they are normally the same, but with services
        // defined in terms of a class (not an interface), the service interface is
        // synthetic, and the declared interface is the actual class.

        if (!(serviceInterface.isInstance(result) || declaredInterface.isInstance(result)))
            throw new ApplicationRuntimeException(ServiceModelMessages.factoryWrongInterface(
                    _servicePoint,
                    result,
                    serviceInterface), constructor.getLocation(), null);

        HiveMind.setLocation(result, constructor.getLocation());
View Full Code Here

            return intercepted;
        }
        catch (Exception ex)
        {
            throw new ApplicationRuntimeException(ServiceModelMessages.unableToConstructService(
                    _servicePoint,
                    ex), ex);
        }

    }
View Full Code Here

            }
            return new PooledService(core);
        }
        catch (Exception ex)
        {
            throw new ApplicationRuntimeException(ServiceModelMessages.unableToConstructService(
                    getServicePoint(),
                    ex), ex);
        }
    }
View Full Code Here

        MockControl c = newControl(Module.class);
        Module m = (Module) c.getMock();

        m.resolveType("bad.class.Name");
        ApplicationRuntimeException cause = new ApplicationRuntimeException("failure");
        c.setThrowable(cause);

        replayControls();

        try
View Full Code Here

            // just warn
            log.warn("MBean for Logger " + log.getName() + " already exists");
        }
        catch (JMException exception)
        {
            throw new ApplicationRuntimeException(exception);
        }
        return objectname;
    }
View Full Code Here

        {
            compiled = compiler.compile(realLoggerPattern);
        }
        catch (MalformedPatternException e)
        {
            throw new ApplicationRuntimeException("Malformed Logger Pattern:" + realLoggerPattern);
        }
        return matcher.matches(loggerName, compiled);

    }
View Full Code Here

                setError(ex.getMessage());
                return;
            }
            catch (CreateException ex)
            {
                throw new ApplicationRuntimeException(ex);
            }
            catch (RemoteException ex)
            {
                vengine.rmiFailure("Remote exception registering new user.", ex, i++);
            }
View Full Code Here

                break;
            }
            catch (FinderException ex)
            {
                throw new ApplicationRuntimeException(ex);
            }
            catch (RemoveException ex)
            {
                throw new ApplicationRuntimeException(ex);
            }
            catch (RemoteException ex)
            {
                vengine.rmiFailure(updateFailure(), ex, i++);
            }
View Full Code Here

                break;
            }
            catch (FinderException ex)
            {
                throw new ApplicationRuntimeException(ex);
            }
            catch (RemoteException ex)
            {
                vengine.rmiFailure("Remote exception reading user.", ex, i++);
            }
View Full Code Here

TOP

Related Classes of org.apache.hivemind.ApplicationRuntimeException

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.