private boolean isWebAppStarting() { if (!isWebAppStarting) { return false; } isWebAppStarting = !webAppContext.isAvailable(); return isWebAppStarting; }
private void webAppHasStarted() { when(webAppContext.isAvailable()).thenReturn(true); }
private void webAppIsStarting() { when(webAppContext.isAvailable()).thenReturn(false); }
GoServerLoadingIndicationHandler(WebAppContext webAppContext, SystemEnvironment systemEnvironment) { setContextPath("/"); setHandler(new LoadingHandler()); this.webAppContext = webAppContext; this.isWebAppStarting = !webAppContext.isAvailable(); this.systemEnvironment = systemEnvironment; }
public boolean isAllWebAppsAvailable(){ if(contexts.isEmpty()){ return false; } for(WebAppContext context : contexts.values()){ if(!context.isAvailable()){ return false; } } return true; }
@Override @ManagementOperation(description = "If web app is available") public boolean isAvailable() { return super.isAvailable(); }
@Override @ManagementOperation(description = "If web app is available") public boolean isAvailable() { return super.isAvailable(); }
private synchronized void internalActivateArchive( Topology topology, File warDir ) throws IOException, ZipException, ParserConfigurationException, TransformerException, SAXException { log.activatingTopologyArchive( topology.getName(), warDir.getName() ); try { WebAppContext newContext = createWebAppContext( topology, warDir, Urls.decode( warDir.getName() ) ); WebAppContext oldContext = deployments.get( newContext.getContextPath() ); deployments.put( newContext.getContextPath(), newContext ); if( oldContext != null ) { contexts.removeHandler( oldContext ); } contexts.addHandler( newContext ); if( contexts.isRunning() && !newContext.isRunning() ) { newContext.start(); if(!newContext.isAvailable()) { throw newContext.getUnavailableException(); } } } catch( Throwable e ) { auditor.audit( Action.DEPLOY, topology.getName(), ResourceType.TOPOLOGY, ActionOutcome.FAILURE ); log.failedToDeployTopology( topology.getName(), e ); } }
private synchronized void internalActivateArchive( Topology topology, File warDir ) { log.activatingTopologyArchive( topology.getName(), warDir.getName() ); try { WebAppContext newContext = createWebAppContext( topology, warDir, Urls.decode( warDir.getName() ) ); WebAppContext oldContext = deployments.get( newContext.getContextPath() ); deployments.put( newContext.getContextPath(), newContext ); if( oldContext != null ) { contexts.removeHandler( oldContext ); } contexts.addHandler( newContext ); if( contexts.isRunning() && !newContext.isRunning() ) { newContext.start(); if(!newContext.isAvailable()) { throw newContext.getUnavailableException(); } } } catch( Throwable e ) { auditor.audit( Action.DEPLOY, topology.getName(), ResourceType.TOPOLOGY, ActionOutcome.FAILURE ); log.failedToDeployTopology( topology.getName(), e ); } }
if (!webAppContext.isAvailable() || webAppContext.isFailed() || !webAppContext.isRunning() || !webAppContext.isStarted() || server.isFailed() || server.isFailed() || !server.isRunning() || !server.isStarted()) {