serverContext, ServerXPathHelper.XPATH_APPLICATIONS);
String appLocation = null;
switch (appType)
{
case DeploymentConstants.EAR :
J2eeApplication app = applicationsConfigBean.
getJ2eeApplicationByName(appName);
AppsManager appsManager = new AppsManager(iEnv);
appLocation = appsManager.getGeneratedXMLLocation(appName);
// for upgrade scenario, we fall back to the original
// location
if (appLocation == null ||
!FileUtils.safeIsDirectory(appLocation)) {
appLocation = app.getLocation();
}
break;
case DeploymentConstants.EJB :
EjbModule module = applicationsConfigBean.
getEjbModuleByName(appName);