Examples of GeronimoEjbJarType


Examples of org.apache.openejb.jee.oejb2.GeronimoEjbJarType

                    SessionBeanType sessioBean = (SessionBeanType) bean;
                    wsBindingMap.put(bean.getEjbName(), new WebServiceBinding(sessioBean));
                }               
            }
        } else {       
            GeronimoEjbJarType geronimoEjbJarType =
                (GeronimoEjbJarType) ejbModule.getEjbModule().getAltDDs().get("geronimo-openejb.xml");
            if (geronimoEjbJarType != null) {
                for (WebServiceBindingType bt : geronimoEjbJarType.getWebServiceBinding()) {
                    wsBindingMap.put(bt.getEjbName(), new WebServiceBinding(bt));
                }
            }
        }
View Full Code Here

Examples of org.apache.openejb.jee.oejb2.GeronimoEjbJarType

        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;
        }
View Full Code Here

Examples of org.apache.openejb.jee.oejb2.GeronimoEjbJarType

        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;
        }
View Full Code Here

Examples of org.apache.openejb.jee.oejb2.GeronimoEjbJarType

        // if we have a default environment specified, we merge it in, but only if
        // this module has tss links.  The vendorDD isn't available yet, so we'll have to look at the 
        // jaxb version of this information now.
        if (this.defaultEnvironment != null) {
            EjbModule ejbModule = (EjbModule)module;
            GeronimoEjbJarType geronimoEjbJarType = (GeronimoEjbJarType) ejbModule.getEjbModule().getAltDDs().get("geronimo-openejb.xml");
           
            if (geronimoEjbJarType != null) {
                List<TssLinkType> links = geronimoEjbJarType.getTssLink();
                if (links != null && links.size() > 0) {
                    EnvironmentBuilder.mergeEnvironments(environment, this.defaultEnvironment);
                }
            }
        }       
View Full Code Here

Examples of org.apache.openejb.jee.oejb2.GeronimoEjbJarType

                throw new DeploymentException("Failed parsing descriptors for module: " + moduleFile.getName(), e);
            }

            // Get the geronimo-openejb.xml tree

            GeronimoEjbJarType geronimoEjbJarType = (GeronimoEjbJarType) ejbModule.getAltDDs().get("geronimo-openejb.xml");
            if (geronimoEjbJarType == null) {
                // create default plan
                String path = (standAlone) ? new File(moduleFile.getName()).getName() : targetPath;
                geronimoEjbJarType = XmlUtil.createDefaultPlan(path, ejbModule.getEjbJar());
                ejbModule.getAltDDs().put("geronimo-openejb.xml", geronimoEjbJarType);
            }
            OpenejbGeronimoEjbJarType geronimoOpenejb = XmlUtil.convertToXmlbeans(geronimoEjbJarType);

            // create the geronimo environment object
            Environment environment = XmlUtil.buildEnvironment(geronimoEjbJarType.getEnvironment(), defaultEnvironment);
            if (earEnvironment != null) {
                EnvironmentBuilder.mergeEnvironments(earEnvironment, environment);
                environment = earEnvironment;
                if (!environment.getConfigId().isResolved()) {
                    throw new IllegalStateException("EJB module ID should be fully resolved (not " + environment.getConfigId() + ")");
View Full Code Here

Examples of org.apache.openejb.jee.oejb2.GeronimoEjbJarType

        // update the original spec dd with the metadata complete dd
        EjbJar ejbJar = ejbModule.getEjbJar();
        ejbModule.setOriginalSpecDD(XmlUtil.marshal(ejbJar));

        // Get the geronimo-openejb plan
           GeronimoEjbJarType geronimoEjbJarType = (GeronimoEjbJarType) ejbModule.getEjbModule().getAltDDs().get("geronimo-openejb.xml");

        // We must set all mapped name references back to null or Geronimo will blow up
        // unmapReferences(ejbJar, geronimoEjbJarType);

        // create a xmlbeans version of the ejb-jar.xml file, because the jndi code is coupled based on xmlbeans objects
View Full Code Here

Examples of org.apache.openejb.jee.oejb2.GeronimoEjbJarType

        }
    }


    private void addGeronimmoOpenEJBPersistenceUnit(EjbModule ejbModule) {
        GeronimoEjbJarType geronimoEjbJarType = (GeronimoEjbJarType) ejbModule.getEjbModule().getAltDDs().get("geronimo-openejb.xml");

        // search for the cmp persistence unit
        PersistenceUnit persistenceUnit = null;
        for (Persistence persistence : geronimoEjbJarType.getPersistence()) {
            for (PersistenceUnit unit : persistence.getPersistenceUnit()) {
                if ("cmp".equals(unit.getName())) {
                    persistenceUnit = unit;
                    break;
                }
            }
        }

        // if not found create one
        if (persistenceUnit == null) {
            String jtaDataSource = null;
            // todo Persistence Unit Data Sources need to be global JNDI names
            Object altDD = ejbModule.getEjbModule().getAltDDs().get("openejb-jar.xml");
            if (altDD instanceof OpenejbJarType) {
                ResourceLocatorType cmpConnectionFactory = ((OpenejbJarType) altDD).getCmpConnectionFactory();
                if (cmpConnectionFactory != null) {
                    String datasourceName = cmpConnectionFactory.getResourceLink();
                    if (datasourceName != null) {
                        jtaDataSource = datasourceName.trim();
                    }
                }
            }

            persistenceUnit = new PersistenceUnit();
            persistenceUnit.setName("cmp");
            persistenceUnit.setTransactionType(TransactionType.JTA);
            if (jtaDataSource != null) {
                persistenceUnit.setJtaDataSource(jtaDataSource);
            } else {
                persistenceUnit.setJtaDataSource(defaultCmpJTADataSource);
            }
            persistenceUnit.setNonJtaDataSource(defaultCmpNonJTADataSource);
            persistenceUnit.setExcludeUnlistedClasses(true);

            Persistence persistence = new Persistence();
            persistence.setVersion("2.0");
            persistence.getPersistenceUnit().add(persistenceUnit);

            geronimoEjbJarType.getPersistence().add(persistence);
        }
        persistenceUnit.getMappingFile().add("META-INF/openejb-cmp-generated-orm.xml");
    }
View Full Code Here

Examples of org.apache.openejb.jee.oejb2.GeronimoEjbJarType

        artifactType.setArtifactId(id);

        EnvironmentType environmentType = new EnvironmentType();
        environmentType.setModuleId(artifactType);

        GeronimoEjbJarType geronimoEjbJarType = new GeronimoEjbJarType();
        geronimoEjbJarType.setEnvironment(environmentType);

        return geronimoEjbJarType;
    }
View Full Code Here

Examples of org.apache.openejb.jee.oejb2.GeronimoEjbJarType

                    SessionBeanType sessioBean = (SessionBeanType) bean;
                    wsBindingMap.put(bean.getEjbName(), new WebServiceBinding(sessioBean));
                }
            }
        } else {
            GeronimoEjbJarType geronimoEjbJarType =
                (GeronimoEjbJarType) ejbModule.getEjbModule().getAltDDs().get("geronimo-openejb.xml");
            if (geronimoEjbJarType != null) {
                for (WebServiceBindingType bt : geronimoEjbJarType.getWebServiceBinding()) {
                    wsBindingMap.put(bt.getEjbName(), new WebServiceBinding(bt));
                }
            }
        }
View Full Code Here

Examples of org.apache.openejb.jee.oejb2.GeronimoEjbJarType

                    SessionBeanType sessioBean = (SessionBeanType) bean;
                    wsBindingMap.put(bean.getEjbName(), new WebServiceBinding(sessioBean));
                }
            }
        } else {
            GeronimoEjbJarType geronimoEjbJarType =
                (GeronimoEjbJarType) ejbModule.getEjbModule().getAltDDs().get("geronimo-openejb.xml");
            if (geronimoEjbJarType != null) {
                for (WebServiceBindingType bt : geronimoEjbJarType.getWebServiceBinding()) {
                    wsBindingMap.put(bt.getEjbName(), new WebServiceBinding(bt));
                }
            }
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.