final ApplicationInfo appInfo = getApplicationInfo(ejbUtil); final List<String> tempLibNames = new LinkedList<>(); for (ModuleInfo moduleInfo : appInfo.getModuleInfos()) { final String jarName = moduleInfo.getName(); if (jarName.endsWith(".jar") || jarName.endsWith(".war")) {
public void stop(ExtendedDeploymentContext context, Logger logger) { ClassLoader currentClassLoader = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader(appClassLoader); context.setClassLoader(appClassLoader); super.stop(context, logger); for (ModuleInfo module : getModuleInfos()) { module.stop(getSubContext(module, context), logger); } if (events!=null) { events.send(new Event<ApplicationInfo>(Deployment.APPLICATION_STOPPED, this), false); } } finally { Thread.currentThread().setContextClassLoader(currentClassLoader); } }
private void registerIfBatchJobsDirExists(ApplicationInfo applicationInfo) { if (applicationInfo != null && applicationInfo.isLoaded()) { ClassLoader appClassLoader = applicationInfo.getAppClassLoader(); if (appClassLoader != null && appClassLoader.getResource("META-INF/batch-jobs") != null) { tagNamesRequiringCleanup.add(config.getName() + ":" + applicationInfo.getName()); return; } for (ModuleInfo moduleInfo : applicationInfo.getModuleInfos()) { ClassLoader moduleClassLoader = moduleInfo.getModuleClassLoader(); if (moduleClassLoader != null && moduleClassLoader.getResource("META-INF/batch-jobs") != null) { tagNamesRequiringCleanup.add(config.getName() + ":" + applicationInfo.getName()); } } } }
context.setClassLoader(appClassLoader); super.unload(context); for (ModuleInfo module : getModuleInfos()) { module.unload(getSubContext(module, context)); for (ModuleInfo module : getModuleInfos()) { if (module.getClassLoaders() != null) { for (ClassLoader cloader : module.getClassLoaders()) {
for (ModuleInfo module : appInfo.getModuleInfos()) { info.map.put(module.getName(), module.getModuleProps()); deploymentContext.getModuleProps().putAll(module.getModuleProps());
for (ModuleInfo module : getModuleInfos()) { if (module.getClassLoaders() != null) { for (ClassLoader cloader : module.getClassLoaders()) {
for (ModuleInfo moduleInfo : appInfo.getModuleInfos())
public void start( ExtendedDeploymentContext context, ProgressTracker tracker) throws Exception { DeploymentTracing tracing = context.getModuleMetaData(DeploymentTracing.class); if (tracing!=null) { tracing.addMark(DeploymentTracing.Mark.START); } super.start(context, tracker); // registers all deployed items. for (ModuleInfo module : getModuleInfos()) { if (tracing!=null) { tracing.addModuleMark(DeploymentTracing.ModuleMark.START, module.getName()); } module.start(getSubContext(module, context), tracker); if (tracing!=null) { tracing.addModuleMark( DeploymentTracing.ModuleMark.STARTED, module.getName()); } } if (tracing!=null) { tracing.addMark(DeploymentTracing.Mark.START_EVENTS); } if (events!=null) { events.send(new Event<ApplicationInfo>(Deployment.APPLICATION_STARTED, this), false); } if (tracing!=null) { tracing.addMark(DeploymentTracing.Mark.STARTED); } }
public void start( ExtendedDeploymentContext context, ProgressTracker tracker) throws Exception { DeploymentTracing tracing = context.getModuleMetaData(DeploymentTracing.class); if (tracing!=null) { tracing.addMark(DeploymentTracing.Mark.START); } super.start(context, tracker); // registers all deployed items. for (ModuleInfo module : getModuleInfos()) { if (tracing!=null) { tracing.addModuleMark(DeploymentTracing.ModuleMark.START, module.getName()); } module.start(getSubContext(module, context), tracker); if (tracing!=null) { tracing.addModuleMark( DeploymentTracing.ModuleMark.STARTED, module.getName()); } } if (tracing!=null) { tracing.addMark(DeploymentTracing.Mark.START_EVENTS); } if (events!=null) { events.send(new Event<ApplicationInfo>(Deployment.APPLICATION_STARTED, this), false); } if (tracing!=null) { tracing.addMark(DeploymentTracing.Mark.STARTED); } }