public boolean isServing() { return tomcat != null && tomcat.getHost().getState() == LifecycleState.STARTED; }
public boolean isServing() { return tomcat != null && tomcat.getHost().getState() == LifecycleState.STARTED; }
if (host.getState().isAvailable()) { args[0] = response.encodeURL (request.getContextPath() +
@Override public void startInternal() throws LifecycleException { setState(LifecycleState.STARTING); Engine engine = service.getContainer(); if (engine == null) { return; } findDefaultHost(); addListeners(engine); Container[] conHosts = engine.findChildren(); for (Container conHost : conHosts) { Host host = (Host) conHost; if (!LifecycleState.NEW.equals(host.getState())) { // Registering the host will register the context and wrappers registerHost(host); } } }
@Override public void startInternal() throws LifecycleException { setState(LifecycleState.STARTING); // Find any components that have already been initialized since the // MBean listener won't be notified as those components will have // already registered their MBeans findDefaultHost(); Engine engine = (Engine) service.getContainer(); addListeners(engine); Container[] conHosts = engine.findChildren(); for (Container conHost : conHosts) { Host host = (Host) conHost; if (!LifecycleState.NEW.equals(host.getState())) { // Registering the host will register the context and wrappers registerHost(host); } } }
@Override public void startInternal() throws LifecycleException { setState(LifecycleState.STARTING); Engine engine = service.getContainer(); if (engine == null) { return; } findDefaultHost(); addListeners(engine); Container[] conHosts = engine.findChildren(); for (Container conHost : conHosts) { Host host = (Host) conHost; if (!LifecycleState.NEW.equals(host.getState())) { // Registering the host will register the context and wrappers registerHost(host); } } }
@Override public void startInternal() { setState(LifecycleState.STARTING); // Find any components that have already been initialized since the // MBean listener won't be notified as those components will have // already registered their MBeans findDefaultHost(); Engine engine = (Engine) connector.getService().getContainer(); addListeners(engine); Container[] conHosts = engine.findChildren(); for (Container conHost : conHosts) { Host host = (Host) conHost; if (!LifecycleState.NEW.equals(host.getState())) { // Registering the host will register the context and wrappers registerHost(host); } } }
@Override public void startInternal() throws LifecycleException { setState(LifecycleState.STARTING); // Find any components that have already been initialized since the // MBean listener won't be notified as those components will have // already registered their MBeans findDefaultHost(); Engine engine = (Engine) connector.getService().getContainer(); addListeners(engine); Container[] conHosts = engine.findChildren(); for (Container conHost : conHosts) { Host host = (Host) conHost; if (!LifecycleState.NEW.equals(host.getState())) { // Registering the host will register the context and wrappers registerHost(host); } } }
@Override public void startInternal() throws LifecycleException { setState(LifecycleState.STARTING); // Find any components that have already been initialized since the // MBean listener won't be notified as those components will have // already registered their MBeans findDefaultHost(); Engine engine = (Engine) connector.getService().getContainer(); addListeners(engine); Container[] conHosts = engine.findChildren(); for (Container conHost : conHosts) { Host host = (Host) conHost; if (!LifecycleState.NEW.equals(host.getState())) { // Registering the host will register the context and wrappers registerHost(host); } } }
@Override public void startInternal() { setState(LifecycleState.STARTING); // Find any components that have already been initialized since the // MBean listener won't be notified as those components will have // already registered their MBeans findDefaultHost(); Engine engine = (Engine) connector.getService().getContainer(); addListeners(engine); Container[] conHosts = engine.findChildren(); for (Container conHost : conHosts) { Host host = (Host) conHost; if (!LifecycleState.NEW.equals(host.getState())) { // Registering the host will register the context and wrappers registerHost(host); } } }
@Override public void startInternal() { setState(LifecycleState.STARTING); // Find any components that have already been initialized since the // MBean listener won't be notified as those components will have // already registered their MBeans findDefaultHost(); Engine engine = (Engine) connector.getService().getContainer(); addListeners(engine); Container[] conHosts = engine.findChildren(); for (Container conHost : conHosts) { Host host = (Host) conHost; if (!LifecycleState.NEW.equals(host.getState())) { // Registering the host will register the context and wrappers registerHost(host); } } }
public static void removeVirtualHost(String hostName) { Engine engine = DataHolder.getInstance().getCarbonTomcatService().getTomcat().getEngine(); Host host = (Host) engine.findChild(hostName); Context context = (Context) host.findChild("/"); try { if (host.getState().isAvailable()) { if (context != null && context.getAvailable()) { context.setRealm(null); context.stop(); context.destroy(); log.info("Unloaded webapp from the host: " + host + " as the context of: " + context); } host.removeChild(context); host.setRealm(null); host.stop(); host.destroy(); engine.removeChild(host); } }catch (LifecycleException e) { log.error("error while removing host from tomcat", e); } URLMappingHolder.getInstance().removeUrlMappingMap( host.getName()); log.info("Unloaded host from the engine: " + host); } public static Host addHostToEngine(String hostName) {
if (host != null && host.getState().isAvailable()) { newDefaultAccessLog = host.getAccessLog();
if (host != null && host.getState().isAvailable()) { newDefaultAccessLog = host.getAccessLog();
if (host != null && host.getState().isAvailable()) { newDefaultAccessLog = host.getAccessLog();
if (host != null && host.getState().isAvailable()) { newDefaultAccessLog = host.getAccessLog();
if (host != null && host.getState().isAvailable()) { newDefaultAccessLog = host.getAccessLog();
if (host != null && host.getState().isAvailable()) { newDefaultAccessLog = host.getAccessLog();
if (host != null && host.getState().isAvailable()) { newDefaultAccessLog = host.getAccessLog();
if (host != null && host.getState().isAvailable()) { newDefaultAccessLog = host.getAccessLog();