public void createModule(Module module, Object plan, JarFile moduleFile, String targetPath, URL specDDUrl, Environment environment, Object moduleContextInfo, AbstractName earName, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException { EjbModule ejbModule = (EjbModule) module; GeronimoEjbJarType tmpGeronimoEjbJarType = (GeronimoEjbJarType) ejbModule.getEjbModule().getAltDDs().get("geronimo-openejb.xml"); OpenejbGeronimoEjbJarType geronimoEjbJarType = XmlUtil.convertToXmlbeans(tmpGeronimoEjbJarType); GerOpenejbClusteringWadiType clusteringWadiType = getWadiClusterConfig(geronimoEjbJarType); if (null == clusteringWadiType) { return; } EnvironmentBuilder.mergeEnvironments(environment, defaultEnvironment); ejbModule.getPreAutoConfigDeployer().add(new MapSFSBToContainerIDDeployer(defaultClusteredStatefulContainerId)); }
private AppInfo configureApplication(AppModule appModule, EjbModule ejbModule, Configuration configuration) throws OpenEJBException { OpenEjbConfiguration openEjbConfiguration = new OpenEjbConfiguration(); openEjbConfiguration.containerSystem = new ContainerSystemInfo(); openEjbConfiguration.facilities = new FacilitiesInfo(); boolean offline = true; ConfigurationFactory.Chain chain = new ConfigurationFactory.Chain(); ConfigurationFactory configurationFactory = new ConfigurationFactory(offline, chain, openEjbConfiguration); buildChain(offline, ejbModule.getPreAutoConfigDeployer(), SystemInstance.get().getOptions(), configurationFactory, chain); ClassLoader oldClassLoader = Thread.currentThread().getContextClassLoader(); Thread.currentThread().setContextClassLoader(appModule.getClassLoader()); try { addContainerInfos(configuration, openEjbConfiguration.containerSystem, configurationFactory); addResourceAdapterMDBInfos(configuration, openEjbConfiguration.containerSystem, configurationFactory); //process resource adapters return configurationFactory.configureApplication(appModule); } finally { Thread.currentThread().setContextClassLoader(oldClassLoader); } }
final Chain chain = new Chain(); chain.add(new SystemPropertiesOverride()); chain.add(new GeneratedClientModules.Add()); chain.add(new ReadDescriptors()); chain.add(appContextConfigDeployer); chain.add(new ApplicationProperties()); chain.add(new ModuleProperties()); chain.add(new LegacyProcessor()); chain.add(annotationDeployer); chain.add(beanProperties); chain.add(new ProxyBeanClassUpdate()); chain.add(new GeneratedClientModules.Prune()); chain.add(new ClearEmptyMappedName()); chain.add(new ValidateModules()); } else { DeploymentLoader.logger.info("validationDisabled", VALIDATION_SKIP_PROPERTY);
final Chain chain = new Chain(); chain.add(new SystemPropertiesOverride()); chain.add(new GeneratedClientModules.Add()); chain.add(new ApplicationComposerDeployer()); // before read descriptors and moreover AnnotationDeploer chain.add(new ReadDescriptors()); chain.add(appContextConfigDeployer); chain.add(new ApplicationProperties()); chain.add(new ModuleProperties()); chain.add(new LegacyProcessor()); chain.add(annotationDeployer); chain.add(beanProperties); chain.add(new ConfigurationDeployer()); // after annotation deployer and read descriptors are the only constraints chain.add(new ProxyBeanClassUpdate()); chain.add(new GeneratedClientModules.Prune()); chain.add(new ClearEmptyMappedName());
Chain chain = new Chain(); chain.add(new GeneratedClientModules.Add()); chain.add(new ReadDescriptors()); chain.add(new AnnotationDeployer()); chain.add(new GeneratedClientModules.Prune()); chain.add(new ClearEmptyMappedName()); chain.add(new ValidateModules()); } else { DeploymentLoader.logger.info("validationDisabled", VALIDATION_SKIP_PROPERTY); chain.add(new InitEjbDeployments()); chain.add(new DebuggableVmHackery()); chain.add(new WsDeployer()); } else { chain.add(new RemoveWebServices()); chain.add(new CmpJpaConversion()); chain.add(new OpenEjb2Conversion()); chain.add(new SunConversion());
private static ConfigurationFactory.Chain buildChain(boolean offline, DynamicDeployer preAutoConfigDeployer, Options options, ConfigurationFactory configurationFactory, ConfigurationFactory.Chain chain) { chain.add(new GeneratedClientModules.Add()); chain.add(new ReadDescriptors()); chain.add(new LegacyProcessor()); chain.add(new GeronimoAnnotationDeployer()); chain.add(new GeneratedClientModules.Prune()); chain.add(new ClearEmptyMappedName()); chain.add(new ValidateModules()); } else { log.info("validationDisabled", VALIDATION_SKIP_PROPERTY); chain.add(new InitEjbDeployments()); chain.add(new WsDeployer()); } else { chain.add(new CmpJpaConversion()); chain.add(new OpenEjb2Conversion()); chain.add(new SunConversion()); chain.add(new WlsConversion());
public EjbModule(org.apache.openejb.config.EjbModule ejbModule, boolean standAlone, AbstractName moduleName, String name, Environment environment, JarFile moduleFile, String targetPath, String originalSpecDD, EjbJar specDD, OpenejbGeronimoEjbJarType vendorDD, Map<JndiKey, Map<String, Object>> jndiContext, Module parentModule, boolean shareJndi) { super(standAlone, moduleName, name, environment, moduleFile, targetPath, specDD, vendorDD, originalSpecDD, jndiContext, parentModule); this.ejbModule = ejbModule; this.ejbModule.setStandaloneModule(standAlone); preAutoConfigDeployer = new ConfigurationFactory.Chain(); this.shareJndi = shareJndi; }