Ripped everything out
Project: http://git-wip-us.apache.org/repos/asf/tomee/repo Commit: http://git-wip-us.apache.org/repos/asf/tomee/commit/ac196ecb Tree: http://git-wip-us.apache.org/repos/asf/tomee/tree/ac196ecb Diff: http://git-wip-us.apache.org/repos/asf/tomee/diff/ac196ecb Branch: refs/heads/tomee-7.1.x Commit: ac196ecbf5b72e7592259e57fb1c16fd409c9e9b Parents: addc3ce Author: Jonathan Gallimore <[email protected]> Authored: Tue Dec 4 14:52:56 2018 +0000 Committer: Otavio Santana <[email protected]> Committed: Mon Dec 17 13:58:14 2018 -0200 ---------------------------------------------------------------------- .../tests/cmp/sample/CustomOrmXmlTest.java | 2 +- .../tests/cmp/sample/MoviesBusinessBean.java | 15 +---- .../arquillian/tests/cmp/sample/Person.java | 32 ---------- .../arquillian/tests/cmp/sample/PersonBean.java | 64 -------------------- .../tests/cmp/sample/PersonLocalHome.java | 34 ----------- .../arquillian/tests/cmp/sample/ejb-jar.xml | 39 ------------ .../arquillian/tests/cmp/sample/openejb-jar.xml | 9 +-- 7 files changed, 3 insertions(+), 192 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/tomee/blob/ac196ecb/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/CustomOrmXmlTest.java ---------------------------------------------------------------------- diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/CustomOrmXmlTest.java b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/CustomOrmXmlTest.java index 2a96925..c442bcc 100644 --- a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/CustomOrmXmlTest.java +++ b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/CustomOrmXmlTest.java @@ -43,7 +43,7 @@ public class CustomOrmXmlTest { public static WebArchive createDeployment() { WebArchive archive = ShrinkWrap.create(WebArchive.class, CustomOrmXmlTest.class.getSimpleName() + ".war") .addClasses(MovieServlet.class, MovieException.class, MoviesBusinessBean.class, - MoviesBusinessLocal.class, MoviesBusinessLocalHome.class, PersonBean.class, PersonLocalHome.class, Person.class) + MoviesBusinessLocal.class, MoviesBusinessLocalHome.class) .addAsWebInfResource(new ClassLoaderAsset("org/apache/openejb/arquillian/tests/cmp/sample/openejb-jar.xml"), "openejb-jar.xml") .addAsWebInfResource(new ClassLoaderAsset("org/apache/openejb/arquillian/tests/cmp/sample/ejb-jar.xml"), "ejb-jar.xml") .addAsWebInfResource(new ClassLoaderAsset("org/apache/openejb/arquillian/tests/cmp/sample/web.xml"), "web.xml"); http://git-wip-us.apache.org/repos/asf/tomee/blob/ac196ecb/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/MoviesBusinessBean.java ---------------------------------------------------------------------- diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/MoviesBusinessBean.java b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/MoviesBusinessBean.java index 0f6cced..e4a9b8e 100644 --- a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/MoviesBusinessBean.java +++ b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/MoviesBusinessBean.java @@ -16,13 +16,9 @@ */ package org.apache.openejb.arquillian.tests.cmp.sample; -import javax.ejb.CreateException; import javax.ejb.EJBException; import javax.ejb.SessionBean; import javax.ejb.SessionContext; -import javax.naming.InitialContext; -import javax.naming.NamingException; -import javax.rmi.PortableRemoteObject; import java.rmi.RemoteException; public class MoviesBusinessBean implements SessionBean { @@ -46,16 +42,7 @@ public class MoviesBusinessBean implements SessionBean { } public void addActor(final String name) throws MovieException { - try { - final InitialContext context = new InitialContext(); - - final PersonLocalHome personLocalHome = (PersonLocalHome) - PortableRemoteObject.narrow(context.lookup("java:comp/env/ejb/PersonBean"), PersonLocalHome.class); - - final Person person = personLocalHome.create(name); - } catch (NamingException | CreateException e) { - throw new MovieException(e); - } + // this is literally a no-op now } } http://git-wip-us.apache.org/repos/asf/tomee/blob/ac196ecb/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/Person.java ---------------------------------------------------------------------- diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/Person.java b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/Person.java deleted file mode 100644 index 31aeb87..0000000 --- a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/Person.java +++ /dev/null @@ -1,32 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * <p/> - * http://www.apache.org/licenses/LICENSE-2.0 - * <p/> - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.openejb.arquillian.tests.cmp.sample; - -/** - * @version $Revision$ $Date$ - */ -public interface Person extends javax.ejb.EJBLocalObject { - - Integer getId(); - - void setId(Integer id); - - String getName(); - - void setName(String name); - -} http://git-wip-us.apache.org/repos/asf/tomee/blob/ac196ecb/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/PersonBean.java ---------------------------------------------------------------------- diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/PersonBean.java b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/PersonBean.java deleted file mode 100644 index 39c0ef4..0000000 --- a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/PersonBean.java +++ /dev/null @@ -1,64 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * <p/> - * http://www.apache.org/licenses/LICENSE-2.0 - * <p/> - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.openejb.arquillian.tests.cmp.sample; - -import javax.ejb.CreateException; -import javax.ejb.EntityBean; -import javax.ejb.EntityContext; - -public abstract class PersonBean implements EntityBean { - - public PersonBean() { - } - - public Integer ejbCreate(final String name) { - this.setName(name); - return null; - } - - public abstract Integer getId(); - - public abstract void setId(Integer id); - - public abstract String getName(); - - public abstract void setName(String name); - - public void ejbPostCreate(String name) throws CreateException { - } - - public void setEntityContext(EntityContext ctx) { - } - - public void unsetEntityContext() { - } - - public void ejbRemove() { - } - - public void ejbLoad() { - } - - public void ejbStore() { - } - - public void ejbPassivate() { - } - - public void ejbActivate() { - } -} http://git-wip-us.apache.org/repos/asf/tomee/blob/ac196ecb/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/PersonLocalHome.java ---------------------------------------------------------------------- diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/PersonLocalHome.java b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/PersonLocalHome.java deleted file mode 100644 index c35a0ae..0000000 --- a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/java/org/apache/openejb/arquillian/tests/cmp/sample/PersonLocalHome.java +++ /dev/null @@ -1,34 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * <p/> - * http://www.apache.org/licenses/LICENSE-2.0 - * <p/> - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.openejb.arquillian.tests.cmp.sample; - -import javax.ejb.CreateException; -import javax.ejb.FinderException; -import java.util.Collection; - -/** - * @version $Revision$ $Date$ - */ -interface PersonLocalHome extends javax.ejb.EJBLocalHome { - - Person create(String name) throws CreateException; - - Person findByPrimaryKey(Integer primarykey) throws FinderException; - - Collection findAll() throws FinderException; - -} http://git-wip-us.apache.org/repos/asf/tomee/blob/ac196ecb/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/resources/org/apache/openejb/arquillian/tests/cmp/sample/ejb-jar.xml ---------------------------------------------------------------------- diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/resources/org/apache/openejb/arquillian/tests/cmp/sample/ejb-jar.xml b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/resources/org/apache/openejb/arquillian/tests/cmp/sample/ejb-jar.xml index c5af41d..cb5f047 100644 --- a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/resources/org/apache/openejb/arquillian/tests/cmp/sample/ejb-jar.xml +++ b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/resources/org/apache/openejb/arquillian/tests/cmp/sample/ejb-jar.xml @@ -32,39 +32,7 @@ <ejb-class>org.apache.openejb.arquillian.tests.cmp.sample.MoviesBusinessBean</ejb-class> <session-type>Stateless</session-type> <transaction-type>Container</transaction-type> - <ejb-local-ref> - <ejb-ref-name>ejb/PersonBean</ejb-ref-name> - <ejb-ref-type>Entity</ejb-ref-type> - <local-home>org.apache.openejb.arquillian.tests.cmp.sample.PersonLocalHome</local-home> - <local>org.apache.openejb.arquillian.tests.cmp.sample.Person</local> - <ejb-link>PersonBean</ejb-link> - </ejb-local-ref> </session> - <entity> - <ejb-name>PersonBean</ejb-name> - <local-home>org.apache.openejb.arquillian.tests.cmp.sample.PersonLocalHome</local-home> - <local>org.apache.openejb.arquillian.tests.cmp.sample.Person</local> - <ejb-class>org.apache.openejb.arquillian.tests.cmp.sample.PersonBean</ejb-class> - <persistence-type>Container</persistence-type> - <prim-key-class>java.lang.Integer</prim-key-class> - <reentrant>false</reentrant> - <cmp-version>2.x</cmp-version> - <abstract-schema-name>PersonBean</abstract-schema-name> - <cmp-field> - <field-name>id</field-name> - </cmp-field> - <cmp-field> - <field-name>name</field-name> - </cmp-field> - <primkey-field>id</primkey-field> - <query> - <query-method> - <method-name>findAll</method-name> - <method-params/> - </query-method> - <ejb-ql>SELECT p FROM PersonBean as p</ejb-ql> - </query> - </entity> </enterprise-beans> <assembly-descriptor> <container-transaction> @@ -74,12 +42,5 @@ </method> <trans-attribute>Required</trans-attribute> </container-transaction> - <container-transaction> - <method> - <ejb-name>PersonBean</ejb-name> - <method-name>*</method-name> - </method> - <trans-attribute>Supports</trans-attribute> - </container-transaction> </assembly-descriptor> </ejb-jar> http://git-wip-us.apache.org/repos/asf/tomee/blob/ac196ecb/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/resources/org/apache/openejb/arquillian/tests/cmp/sample/openejb-jar.xml ---------------------------------------------------------------------- diff --git a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/resources/org/apache/openejb/arquillian/tests/cmp/sample/openejb-jar.xml b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/resources/org/apache/openejb/arquillian/tests/cmp/sample/openejb-jar.xml index 1de720e..166128c 100644 --- a/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/resources/org/apache/openejb/arquillian/tests/cmp/sample/openejb-jar.xml +++ b/arquillian/arquillian-tomee-tests/arquillian-tomee-webprofile-tests/src/test/resources/org/apache/openejb/arquillian/tests/cmp/sample/openejb-jar.xml @@ -1,11 +1,4 @@ <?xml version="1.0" encoding="UTF-8"?> <openejb-jar xmlns="http://www.openejb.org/xml/ns/openejb-jar-2.1"> - <enterprise-beans> - <entity> - <ejb-name>PersonBean</ejb-name> - <key-generator xmlns="http://www.openejb.org/xml/ns/pkgen-2.1"> - <uuid/> - </key-generator> - </entity> - </enterprise-beans> + <enterprise-beans/> </openejb-jar> \ No newline at end of file
