Package com.sun.appserv.server

Examples of com.sun.appserv.server.ServerLifecycleException


            Throwable ex = le.getThrowable();
            if (ex == null)
                ex = le;

            String msg = _rb.getString("webcontainer.stopError");
            throw new ServerLifecycleException(msg, ex);
        }
    }
View Full Code Here


            server = createServerObject();
            saveStubToFile(server.getRemoteStub());
        } catch (Exception e) {
            warn(SERVER_CREATION_ERRCODE);
            debug(e);
            throw new ServerLifecycleException(e);
        }
    }
View Full Code Here

        if (server != null) {
            server.setChannelStopping();
            try {
                UnicastRemoteObject.unexportObject(server, true);
            } catch (NoSuchObjectException nsoe) {
                throw new ServerLifecycleException(nsoe);
            }
        }
        deleteStubFile();
    }
View Full Code Here

            slcl = (LifecycleListener) cl.newInstance();
        } catch (Exception ee) {
            _logger.log(Level.SEVERE, KernelLoggerInfo.exceptionLoadingLifecycleModule,
                    new Object[] {this.name, ee}) ;
            if (isFatal) {
                throw new ServerLifecycleException(localStrings.getLocalString("lifecyclemodule.loadExceptionIsFatal", "Treating failure loading the lifecycle module as fatal", this.name));
            }
        }

        return slcl;
    }
View Full Code Here

    private void postEvent(int eventType, Object data)
                                    throws ServerLifecycleException {
        if (slcl == null) {
            if (isFatal) {
                throw new ServerLifecycleException(localStrings.getLocalString("lifecyclemodule.loadExceptionIsFatal", "Treating failure loading the lifecycle module as fatal", this.name));
            }

            return;
        }

        if (urlClassLoader != null)
            setClassLoader();

        LifecycleEvent slcEvent= new LifecycleEvent(this, eventType, data, this.leContext);
        try {
            slcl.handleEvent(slcEvent);
        } catch (ServerLifecycleException sle) {
            _logger.log(Level.WARNING, KernelLoggerInfo.serverLifecycleException,
                    new Object[] {this.name, sle});

            if (isFatal)
                throw sle;
        } catch (Exception ee) {
            _logger.log(Level.WARNING, KernelLoggerInfo.lifecycleModuleException,
                    new Object[] {this.name, ee});

            if (isFatal) {
                throw new ServerLifecycleException(localStrings.getLocalString("lifecyclemodule.event_exceptionIsFatal", "Treating the exception from lifecycle module event handler as fatal"), ee);
            }
        }
    }
View Full Code Here

            Class cl = Class.forName(className, true, classLoader);
            slcl = (LifecycleListener) cl.newInstance();
        } catch (Exception ee) {
            _logger.log(Level.SEVERE, localStrings.getLocalString("lifecyclemodule.load_exception", "Exception loading lifecycle module", this.name, ee.toString()), ee) ;
            if (isFatal) {
                throw new ServerLifecycleException(localStrings.getLocalString("lifecyclemodule.loadExceptionIsFatal", "Treating failure loading the lifecycle module as fatal", this.name));
            }
        }

        return slcl;
    }
View Full Code Here

    private void postEvent(int eventType, Object data)
                                    throws ServerLifecycleException {
        if (slcl == null) {
            if (isFatal) {
                throw new ServerLifecycleException(localStrings.getLocalString("lifecyclemodule.loadExceptionIsFatal", "Treating failure loading the lifecycle module as fatal", this.name));
            }

            return;
        }

        if (urlClassLoader != null)
            setClassLoader();

        LifecycleEvent slcEvent= new LifecycleEvent(this, eventType, data, this.leContext);
        try {
            slcl.handleEvent(slcEvent);
        } catch (ServerLifecycleException sle) {
            _logger.log(Level.WARNING, localStrings.getLocalString("lifecyclemodule.event_ServerLifecycleException", "Lifecycle module threw ServerLifecycleException", this.name), sle);

            if (isFatal)
                throw sle;
        } catch (Exception ee) {
            _logger.log(Level.WARNING, localStrings.getLocalString("lifecyclemodule.event_Exception", "Lifecycle module threw an Exception", this.name), ee);

            if (isFatal) {
                throw new ServerLifecycleException(localStrings.getLocalString("lifecyclemodule.event_exceptionIsFatal", "Treating the exception from lifecycle module event handler as fatal"), ee);
            }
        }
    }
View Full Code Here

TOP

Related Classes of com.sun.appserv.server.ServerLifecycleException

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.