/** * Invoke a pre-startup initialization. This is used to allow connectors * to bind to restricted ports under Unix operating environments. */ public void initialize() throws LifecycleException { if (initialized) { log.log(Level.INFO, LogFacade.STANDARD_SERVER_INITIALIZE_INITIALIZED); return; } // START GlassFish 2439 lifecycle.fireLifecycleEvent(INIT_EVENT, null); // END GlassFish 2439 initialized = true; if( oname==null ) { try { oname=new ObjectName( "Catalina:type=Server"); } catch (Exception e) { String msg = MessageFormat.format(rb.getString(LogFacade.ERROR_REGISTERING), e.toString()); log.log(Level.SEVERE, msg, e); } } // Initialize our defined Services for (int i = 0; i < services.length; i++) { services[i].initialize(); } }
/** * Add a new Service to the set of defined Services. * * @param service The Service to be added */ public void addService(Service service) { service.setServer(this); synchronized (services) { Service results[] = new Service[services.length + 1]; System.arraycopy(services, 0, results, 0, services.length); results[services.length] = service; services = results; if (initialized) { try { service.initialize(); } catch (LifecycleException e) { log.error(e); } } if (started && (service instanceof Lifecycle)) { try { ((Lifecycle) service).start(); } catch (LifecycleException e) { ; } } // Report this property change to interested listeners support.firePropertyChange("service", null, service); } }
/** * Add a new Service to the set of defined Services. * * @param service The Service to be added */ public void addService(Service service) { service.setServer(this); synchronized (services) { Service results[] = new Service[services.length + 1]; System.arraycopy(services, 0, results, 0, services.length); results[services.length] = service; services = results; if (initialized) { try { service.initialize(); } catch (LifecycleException e) { log.error(e); } } if (started && (service instanceof Lifecycle)) { try { ((Lifecycle) service).start(); } catch (LifecycleException e) { ; } } // Report this property change to interested listeners support.firePropertyChange("service", null, service); } }
service.initialize(); } catch (LifecycleException e) { String msg = MessageFormat.format(rb.getString(
service=new StandardService(); service.setContainer( this ); service.initialize();
/** * Add a new Service to the set of defined Services. * * @param service The Service to be added */ public void addService(Service service) { service.setServer(this); synchronized (services) { Service results[] = new Service[services.length + 1]; System.arraycopy(services, 0, results, 0, services.length); results[services.length] = service; services = results; if (initialized) { try { service.initialize(); } catch (LifecycleException e) { CatalinaLogger.CORE_LOGGER.errorInitializingService(e); } } if (started && (service instanceof Lifecycle)) { try { ((Lifecycle) service).start(); } catch (LifecycleException e) { CatalinaLogger.CORE_LOGGER.errorStartingService(e); } } // Report this property change to interested listeners support.firePropertyChange("service", null, service); } }
services[i].initialize();
services[i].initialize();
service=new StandardService(); service.setContainer( this ); service.initialize(); } catch( Throwable t ) { log.error(t);
service=new StandardService(); service.setContainer( this ); service.initialize(); } catch( Throwable t ) { log.error(t);
services[i].initialize();
service=new StandardService(); service.setContainer( this ); service.initialize(); } catch( Throwable t ) { CatalinaLogger.CORE_LOGGER.failedServiceCreation(t);