Source:
<code>protected static WebAppStatus getWebAppStatus(String tenantDomain, String webAppName) { WebAppStatus webAppStatus = new WebAppStatus(); ConfigurationContext tenantConfigurationContext = getTenantConfigurationContext(tenantDomain); if (tenantConfigurationContext != null) { webAppStatus.setTenantStatus(new TenantStatus(true)); log.info("Tenant " + tenantDomain + " configuration context is loaded."); WebApplicationsHolder webApplicationsHolder = (WebApplicationsHolder) ((HashMap) <START> tenantConfigurationContext.getLocalProperty("carbon.webapps.holderlist")).get("webapps"); <END> Map<String, WebApplication> startedWebAppMap = webApplicationsHolder.getStartedWebapps(); if (startedWebAppMap != null) { WebApplication webApplication = startedWebAppMap.get(webAppName); if (webApplication != null) { webAppStatus.setWebAppStarted(true); log.info("Tenant " + tenantDomain + " Web-app: " + webAppName + " is available in configuration context."); boolean isWebAppGhost = Boolean.parseBoolean((String) webApplication.getProperty("GhostWebApp")); log.info("Tenant " + tenantDomain + " Web-app: " + webAppName + " is in Ghost deployment status :" + isWebAppGhost); webAppStatus.setWebAppGhost(isWebAppGhost); } else { log.info("Given web-app:" + webAppName + " for tenant:" + tenantDomain + " not found in started state"); webAppStatus.setWebAppStarted(false); } } else { log.info("Tenant " + tenantDomain + " has no started web-apps."); webAppStatus.setWebAppStarted(false); } } else { log.info("Tenant " + tenantDomain + " configuration context is not loaded."); webAppStatus.setTenantStatus(new TenantStatus(false)); } return webAppStatus; }</code><technical_language>get this a constant "carbon.webapps.holderlist"</technical_language>

Target:
protected static WebAppStatus getWebAppStatus(String tenantDomain, String webAppName) { WebAppStatus webAppStatus = new WebAppStatus(); ConfigurationContext tenantConfigurationServerContext = getTenantConfigurationServerContext(tenantDomain); if (tenantConfigurationServerContext != null) { webAppStatus.setTenantStatus(new TenantStatus(true)); log.info("Tenant " + tenantDomain + " configuration context is loaded."); WebApplicationsHolder webApplicationsHolder = (WebApplicationsHolder) ((HashMap) tenantConfigurationServerContext.getLocalProperty(CARBON_WEBAPPS_HOLDER_LIST)).get(WEBAPPS); Map<String, WebApplication> startedWebAppMap = webApplicationsHolder.getStartedWebapps(); if (startedWebAppMap != null) { WebApplication webApplication = startedWebAppMap.get(webAppName); if (webApplication != null) { webAppStatus.setWebAppStarted(true); log.info("Tenant " + tenantDomain + " Web-app: " + webAppName + " is available in configuration context."); boolean isWebAppGhost = Boolean.parseBoolean((String) webApplication.getProperty(GHOST_WEB_APP)); log.info("Tenant " + tenantDomain + " Web-app: " + webAppName + " is in Ghost deployment status :" + isWebAppGhost); webAppStatus.setWebAppGhost(isWebAppGhost); } else { log.info("Given web-app:" + webAppName + " for tenant:" + tenantDomain + " not found in started state"); webAppStatus.setWebAppStarted(false); } } else { log.info("Tenant " + tenantDomain + " has no started web-apps."); webAppStatus.setWebAppStarted(false); } } else { log.info("Tenant " + tenantDomain + " configuration context is not loaded."); webAppStatus.setTenantStatus(new TenantStatus(false)); } return webAppStatus; }