Author: alessio.soldano(a)jboss.com
Date: 2011-03-02 16:33:18 -0500 (Wed, 02 Mar 2011)
New Revision: 13833
Added:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060EJB3TestCase.java
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060ServletTestCase.java
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060Tests.java
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/gzip/
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/gzip/WEB-INF/
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/gzip/WEB-INF/web.xml
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3060/
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3060/WEB-INF/
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3060/WEB-INF/web.xml
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3098/
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3098/WEB-INF/
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3098/WEB-INF/web.xml
Removed:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060TestCase.java
Modified:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/gzip/GZIPTestCase.java
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/gzip/HelloWorldImpl.java
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3098/ClientServerLifeCycleTestCase.java
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3098/EndpointOneImpl.java
stack/cxf/branches/JBWS-3236/modules/testsuite/pom.xml
Log:
- Converting jbws3098 and gzip cxf testcases to using pojo endpoints instead of ejb3 ones,
to start having test coverage on AS7 (it does not really matter what kind of endpoint is
used here, but the tests are pretty much significant from a CXF integration point of
view)
- Added a pojo endpoint version of the jbws3060 testcase, which should have been done in
any case since the beginning (the test acts as load tests too)
Modified:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml 2011-03-02
18:42:59 UTC (rev 13832)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml 2011-03-02
21:33:18 UTC (rev 13833)
@@ -71,11 +71,11 @@
</war>
<!-- jaxws-cxf-gzip -->
- <jar destfile="${tests.output.dir}/test-libs/jaxws-cxf-gzip.jar">
- <fileset dir="${tests.output.dir}/test-classes">
+ <war warfile="${tests.output.dir}/test-libs/jaxws-cxf-gzip.war"
webxml="${tests.output.dir}/test-resources/jaxws/cxf/gzip/WEB-INF/web.xml">
+ <classes dir="${tests.output.dir}/test-classes">
<include
name="org/jboss/test/ws/jaxws/cxf/gzip/HelloWorld*.class"/>
- </fileset>
- </jar>
+ </classes>
+ </war>
<!-- jaxws-cxf-jaxbintros -->
<jar
destfile="${tests.output.dir}/test-libs/jaxws-cxf-jaxbintros.jar">
@@ -96,13 +96,19 @@
<include
name="org/jboss/test/ws/jaxws/cxf/jbws3060/EndpointTwoImpl.class"/>
</fileset>
</jar>
+ <war warfile="${tests.output.dir}/test-libs/jaxws-cxf-jbws3060.war"
webxml="${tests.output.dir}/test-resources/jaxws/cxf/jbws3060/WEB-INF/web.xml">
+ <classes dir="${tests.output.dir}/test-classes">
+ <include
name="org/jboss/test/ws/jaxws/cxf/jbws3060/EndpointOneImpl.class"/>
+ <include
name="org/jboss/test/ws/jaxws/cxf/jbws3060/EndpointTwoImpl.class"/>
+ </classes>
+ </war>
<!-- jaxws-cxf-jbws3098 -->
- <jar
destfile="${tests.output.dir}/test-libs/jaxws-cxf-jbws3098.jar">
- <fileset dir="${tests.output.dir}/test-classes">
+ <war warfile="${tests.output.dir}/test-libs/jaxws-cxf-jbws3098.war"
webxml="${tests.output.dir}/test-resources/jaxws/cxf/jbws3098/WEB-INF/web.xml">
+ <classes dir="${tests.output.dir}/test-classes">
<include
name="org/jboss/test/ws/jaxws/cxf/jbws3098/EndpointOneImpl.class"/>
- </fileset>
- </jar>
+ </classes>
+ </war>
<!-- jaxws-cxf-logging -->
<jar destfile="${tests.output.dir}/test-libs/jaxws-cxf-logging.jar">
Modified:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/gzip/GZIPTestCase.java
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/gzip/GZIPTestCase.java 2011-03-02
18:42:59 UTC (rev 13832)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/gzip/GZIPTestCase.java 2011-03-02
21:33:18 UTC (rev 13833)
@@ -61,7 +61,7 @@
public static Test suite()
{
- return new JBossWSCXFTestSetup(GZIPTestCase.class,
"jaxws-cxf-gzip.jar");
+ return new JBossWSCXFTestSetup(GZIPTestCase.class,
"jaxws-cxf-gzip.war");
}
public void testGZIPUsingFeatureOnBus() throws Exception
Modified:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/gzip/HelloWorldImpl.java
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/gzip/HelloWorldImpl.java 2011-03-02
18:42:59 UTC (rev 13832)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/gzip/HelloWorldImpl.java 2011-03-02
21:33:18 UTC (rev 13833)
@@ -21,7 +21,6 @@
*/
package org.jboss.test.ws.jaxws.cxf.gzip;
-import javax.ejb.Stateless;
import javax.jws.WebService;
import org.apache.cxf.annotations.GZIP;
@@ -33,7 +32,6 @@
targetNamespace = "http://org.jboss.ws/jaxws/cxf/gzip"
)
@GZIP(threshold = 0)
-@Stateless
public class HelloWorldImpl implements HelloWorld
{
public String echo(String input)
Added:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060EJB3TestCase.java
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060EJB3TestCase.java
(rev 0)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060EJB3TestCase.java 2011-03-02
21:33:18 UTC (rev 13833)
@@ -0,0 +1,39 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2010, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.cxf.jbws3060;
+
+import junit.framework.Test;
+
+import org.jboss.wsf.test.JBossWSCXFTestSetup;
+
+/**
+ *
+ * @author alessio.soldano(a)jboss.com
+ * @since 11-Jun-2010
+ */
+public class JBWS3060EJB3TestCase extends JBWS3060Tests
+{
+ public static Test suite()
+ {
+ return new JBossWSCXFTestSetup(JBWS3060EJB3TestCase.class,
"jaxws-cxf-jbws3060.jar");
+ }
+}
Added:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060ServletTestCase.java
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060ServletTestCase.java
(rev 0)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060ServletTestCase.java 2011-03-02
21:33:18 UTC (rev 13833)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2010, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.cxf.jbws3060;
+
+import junit.framework.Test;
+
+import org.jboss.wsf.test.JBossWSCXFTestSetup;
+
+/**
+ *
+ * @author alessio.soldano(a)jboss.com
+ * @since 11-Jun-2010
+ */
+public class JBWS3060ServletTestCase extends JBWS3060Tests
+{
+ public static Test suite()
+ {
+ return new JBossWSCXFTestSetup(JBWS3060ServletTestCase.class,
"jaxws-cxf-jbws3060.war");
+ }
+
+ @Override
+ protected void setUp() throws Exception {
+ System.out.println("FIXME: JBWS3060ServletTestCase temporarly running with
limited concurrency, investigate load issue.");
+ this.defaultSize = 10;
+ }
+
+}
Deleted:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060TestCase.java
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060TestCase.java 2011-03-02
18:42:59 UTC (rev 13832)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060TestCase.java 2011-03-02
21:33:18 UTC (rev 13833)
@@ -1,171 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2010, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file in the
- * distribution for a full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
- */
-package org.jboss.test.ws.jaxws.cxf.jbws3060;
-
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.concurrent.Callable;
-import java.util.concurrent.ExecutorService;
-import java.util.concurrent.Executors;
-import java.util.concurrent.Future;
-
-import javax.xml.namespace.QName;
-import javax.xml.ws.Service;
-
-import junit.framework.Test;
-
-import org.jboss.wsf.test.JBossWSCXFTestSetup;
-import org.jboss.wsf.test.JBossWSTest;
-
-/**
- *
- * @author alessio.soldano(a)jboss.com
- * @since 11-Jun-2010
- */
-public class JBWS3060TestCase extends JBossWSTest
-{
- private String endpointOneURL = "http://" + getServerHost() +
":8080/jaxws-cxf-jbws3060/ServiceOne/EndpointOne";
- private String endpointTwoURL = "http://" + getServerHost() +
":8080/jaxws-cxf-jbws3060/ServiceTwo/EndpointTwo";
- private String targetNS = "http://org.jboss.ws.jaxws.cxf/jbws3060";
-
- private EndpointOne portOne;
- private EndpointTwo portTwo;
-
- public static Test suite()
- {
- return new JBossWSCXFTestSetup(JBWS3060TestCase.class,
"jaxws-cxf-jbws3060.jar");
- }
-
- public void testAccess() throws Exception
- {
- initPorts();
- int count1 = portOne.getCount();
- int count2 = portTwo.getCount();
- Object retObj = portOne.echo("Hello");
- assertEquals("Hello", retObj);
- retObj = portTwo.sayHello("John");
- assertEquals("Hi John", retObj);
- assertEquals(1, portOne.getCount() - count1);
- assertEquals(1, portTwo.getCount() - count2);
- }
-
- public void testConcurrentInvocations() throws Exception
- {
- runConcurrentTests(false);
- }
-
- public void testConcurrentOneWayInvocations() throws Exception
- {
- runConcurrentTests(true);
- }
-
- private void runConcurrentTests(boolean oneway) throws Exception
- {
- initPorts();
- final int size = 30;
- int count1 = portOne.getCount();
- int count2 = portTwo.getCount();
- ExecutorService es = Executors.newFixedThreadPool(size*2);
- List<Callable<Boolean>> callables = new
ArrayList<Callable<Boolean>>(size*2);
- for (int i = 0; i < size; i++)
- {
- callables.add(new CallableOne(portOne, oneway));
- callables.add(new CallableTwo(portTwo, oneway));
- }
- List<Future<Boolean>> futures = es.invokeAll(callables);
- for (Future<Boolean> f : futures)
- {
- assertTrue(f.get());
- }
- assertEquals(size, portOne.getCount() - count1);
- assertEquals(size, portTwo.getCount() - count2);
- }
-
- private void initPorts() throws MalformedURLException
- {
- URL wsdlOneURL = new URL(endpointOneURL + "?wsdl");
- QName serviceOneName = new QName(targetNS, "ServiceOne");
- Service serviceOne = Service.create(wsdlOneURL, serviceOneName);
- portOne = (EndpointOne)serviceOne.getPort(EndpointOne.class);
-
- URL wsdlTwoURL = new URL(endpointTwoURL + "?wsdl");
- QName serviceTwoName = new QName(targetNS, "ServiceTwo");
- Service serviceTwo = Service.create(wsdlTwoURL, serviceTwoName);
- portTwo = (EndpointTwo)serviceTwo.getPort(EndpointTwo.class);
- }
-
- private static class CallableOne implements Callable<Boolean>
- {
- private EndpointOne port;
- private boolean oneway;
-
- public CallableOne(EndpointOne port, boolean oneway)
- {
- this.port = port;
- this.oneway = oneway;
- }
-
- public Boolean call() throws Exception
- {
- String arg = "Foo";
- if (oneway)
- {
- port.echoOneWay(arg);
- return true;
- }
- else
- {
- String result = port.echo(arg);
- return arg.equals(result);
- }
- }
- }
-
- private static class CallableTwo implements Callable<Boolean>
- {
- private EndpointTwo port;
- private boolean oneway;
-
- public CallableTwo(EndpointTwo port, boolean oneway)
- {
- this.port = port;
- this.oneway = oneway;
- }
-
- public Boolean call() throws Exception
- {
- String arg = "John";
- if (oneway)
- {
- port.sayHelloOneWay(arg);
- return true;
- }
- else
- {
- String result = port.sayHello(arg);
- return ("Hi " + arg).equals(result);
- }
- }
- }
-}
Added:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060Tests.java
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060Tests.java
(rev 0)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3060/JBWS3060Tests.java 2011-03-02
21:33:18 UTC (rev 13833)
@@ -0,0 +1,165 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2010, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.cxf.jbws3060;
+
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.concurrent.Callable;
+import java.util.concurrent.ExecutorService;
+import java.util.concurrent.Executors;
+import java.util.concurrent.Future;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+
+import org.jboss.wsf.test.JBossWSTest;
+
+/**
+ *
+ * @author alessio.soldano(a)jboss.com
+ * @since 11-Jun-2010
+ */
+public abstract class JBWS3060Tests extends JBossWSTest //*Tests does not match the
configured surefire filter on test classes' names
+{
+ private String endpointOneURL = "http://" + getServerHost() +
":8080/jaxws-cxf-jbws3060/ServiceOne/EndpointOne";
+ private String endpointTwoURL = "http://" + getServerHost() +
":8080/jaxws-cxf-jbws3060/ServiceTwo/EndpointTwo";
+ private String targetNS = "http://org.jboss.ws.jaxws.cxf/jbws3060";
+
+ private EndpointOne portOne;
+ private EndpointTwo portTwo;
+
+ protected int defaultSize = 30;
+
+ public void testAccess() throws Exception
+ {
+ initPorts();
+ int count1 = portOne.getCount();
+ int count2 = portTwo.getCount();
+ Object retObj = portOne.echo("Hello");
+ assertEquals("Hello", retObj);
+ retObj = portTwo.sayHello("John");
+ assertEquals("Hi John", retObj);
+ assertEquals(1, portOne.getCount() - count1);
+ assertEquals(1, portTwo.getCount() - count2);
+ }
+
+ public void testConcurrentInvocations() throws Exception
+ {
+ runConcurrentTests(false);
+ }
+
+ public void testConcurrentOneWayInvocations() throws Exception
+ {
+ runConcurrentTests(true);
+ }
+
+ private void runConcurrentTests(boolean oneway) throws Exception
+ {
+ initPorts();
+ final int size = defaultSize;
+ int count1 = portOne.getCount();
+ int count2 = portTwo.getCount();
+ ExecutorService es = Executors.newFixedThreadPool(size*2);
+ List<Callable<Boolean>> callables = new
ArrayList<Callable<Boolean>>(size*2);
+ for (int i = 0; i < size; i++)
+ {
+ callables.add(new CallableOne(portOne, oneway));
+ callables.add(new CallableTwo(portTwo, oneway));
+ }
+ List<Future<Boolean>> futures = es.invokeAll(callables);
+ for (Future<Boolean> f : futures)
+ {
+ assertTrue(f.get());
+ }
+ assertEquals(size, portOne.getCount() - count1);
+ assertEquals(size, portTwo.getCount() - count2);
+ }
+
+ private void initPorts() throws MalformedURLException
+ {
+ URL wsdlOneURL = new URL(endpointOneURL + "?wsdl");
+ QName serviceOneName = new QName(targetNS, "ServiceOne");
+ Service serviceOne = Service.create(wsdlOneURL, serviceOneName);
+ portOne = (EndpointOne)serviceOne.getPort(EndpointOne.class);
+
+ URL wsdlTwoURL = new URL(endpointTwoURL + "?wsdl");
+ QName serviceTwoName = new QName(targetNS, "ServiceTwo");
+ Service serviceTwo = Service.create(wsdlTwoURL, serviceTwoName);
+ portTwo = (EndpointTwo)serviceTwo.getPort(EndpointTwo.class);
+ }
+
+ private static class CallableOne implements Callable<Boolean>
+ {
+ private EndpointOne port;
+ private boolean oneway;
+
+ public CallableOne(EndpointOne port, boolean oneway)
+ {
+ this.port = port;
+ this.oneway = oneway;
+ }
+
+ public Boolean call() throws Exception
+ {
+ String arg = "Foo";
+ if (oneway)
+ {
+ port.echoOneWay(arg);
+ return true;
+ }
+ else
+ {
+ String result = port.echo(arg);
+ return arg.equals(result);
+ }
+ }
+ }
+
+ private static class CallableTwo implements Callable<Boolean>
+ {
+ private EndpointTwo port;
+ private boolean oneway;
+
+ public CallableTwo(EndpointTwo port, boolean oneway)
+ {
+ this.port = port;
+ this.oneway = oneway;
+ }
+
+ public Boolean call() throws Exception
+ {
+ String arg = "John";
+ if (oneway)
+ {
+ port.sayHelloOneWay(arg);
+ return true;
+ }
+ else
+ {
+ String result = port.sayHello(arg);
+ return ("Hi " + arg).equals(result);
+ }
+ }
+ }
+}
Modified:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3098/ClientServerLifeCycleTestCase.java
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3098/ClientServerLifeCycleTestCase.java 2011-03-02
18:42:59 UTC (rev 13832)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3098/ClientServerLifeCycleTestCase.java 2011-03-02
21:33:18 UTC (rev 13833)
@@ -50,7 +50,7 @@
public static Test suite()
{
- return new JBossWSCXFTestSetup(ClientServerLifeCycleTestCase.class,
"jaxws-cxf-jbws3098.jar");
+ return new JBossWSCXFTestSetup(ClientServerLifeCycleTestCase.class,
"jaxws-cxf-jbws3098.war");
}
public void testClientLifeCycleManager()
Modified:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3098/EndpointOneImpl.java
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3098/EndpointOneImpl.java 2011-03-02
18:42:59 UTC (rev 13832)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3098/EndpointOneImpl.java 2011-03-02
21:33:18 UTC (rev 13833)
@@ -21,7 +21,6 @@
*/
package org.jboss.test.ws.jaxws.cxf.jbws3098;
-import javax.ejb.Stateless;
import javax.jws.WebMethod;
import javax.jws.WebService;
import javax.jws.soap.SOAPBinding;
@@ -30,7 +29,6 @@
@WebService(name = "EndpointOne", targetNamespace =
"http://org.jboss.ws.jaxws.cxf/jbws3098", serviceName = "ServiceOne")
@SOAPBinding(style = SOAPBinding.Style.RPC)
-@Stateless
public class EndpointOneImpl
{
@WebMethod
Added:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/gzip/WEB-INF/web.xml
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/gzip/WEB-INF/web.xml
(rev 0)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/gzip/WEB-INF/web.xml 2011-03-02
21:33:18 UTC (rev 13833)
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app version="2.5"
xmlns="http://java.sun.com/xml/ns/javaee"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/j2ee/web-app_2_5.xsd">
+
+ <servlet>
+ <servlet-name>TestServlet</servlet-name>
+
<servlet-class>org.jboss.test.ws.jaxws.cxf.gzip.HelloWorldImpl</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>TestServlet</servlet-name>
+ <url-pattern>/HelloWorldService/HelloWorldImpl</url-pattern>
+ </servlet-mapping>
+</web-app>
\ No newline at end of file
Added:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3060/WEB-INF/web.xml
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3060/WEB-INF/web.xml
(rev 0)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3060/WEB-INF/web.xml 2011-03-02
21:33:18 UTC (rev 13833)
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app version="2.5"
xmlns="http://java.sun.com/xml/ns/javaee"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/j2ee/web-app_2_5.xsd">
+
+ <servlet>
+ <servlet-name>Ep1Servlet</servlet-name>
+
<servlet-class>org.jboss.test.ws.jaxws.cxf.jbws3060.EndpointOneImpl</servlet-class>
+ </servlet>
+ <servlet>
+ <servlet-name>Ep2Servlet</servlet-name>
+
<servlet-class>org.jboss.test.ws.jaxws.cxf.jbws3060.EndpointTwoImpl</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>Ep1Servlet</servlet-name>
+ <url-pattern>/ServiceOne/EndpointOne</url-pattern>
+ </servlet-mapping>
+ <servlet-mapping>
+ <servlet-name>Ep2Servlet</servlet-name>
+ <url-pattern>/ServiceTwo/EndpointTwo</url-pattern>
+ </servlet-mapping>
+</web-app>
\ No newline at end of file
Added:
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3098/WEB-INF/web.xml
===================================================================
---
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3098/WEB-INF/web.xml
(rev 0)
+++
stack/cxf/branches/JBWS-3236/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3098/WEB-INF/web.xml 2011-03-02
21:33:18 UTC (rev 13833)
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app version="2.5"
xmlns="http://java.sun.com/xml/ns/javaee"
+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/j2ee/web-app_2_5.xsd">
+
+ <servlet>
+ <servlet-name>EpServlet</servlet-name>
+
<servlet-class>org.jboss.test.ws.jaxws.cxf.jbws3098.EndpointOneImpl</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>EpServlet</servlet-name>
+ <url-pattern>/ServiceOne/EndpointOne</url-pattern>
+ </servlet-mapping>
+</web-app>
\ No newline at end of file
Modified: stack/cxf/branches/JBWS-3236/modules/testsuite/pom.xml
===================================================================
--- stack/cxf/branches/JBWS-3236/modules/testsuite/pom.xml 2011-03-02 18:42:59 UTC (rev
13832)
+++ stack/cxf/branches/JBWS-3236/modules/testsuite/pom.xml 2011-03-02 21:33:18 UTC (rev
13833)
@@ -876,10 +876,8 @@
<exclude>org/jboss/test/ws/jaxws/samples/webserviceref/**/*EJB3TestCase*</exclude>
<exclude>org/jboss/test/ws/management/recording/**</exclude>
<exclude>org/jboss/test/ws/jaxws/cxf/bus/*EJB3*</exclude>
- <exclude>org/jboss/test/ws/jaxws/cxf/gzip/**</exclude>
<exclude>org/jboss/test/ws/jaxws/cxf/jaxbintros/**</exclude>
- <exclude>org/jboss/test/ws/jaxws/cxf/jbws3060/**</exclude>
-
<exclude>org/jboss/test/ws/jaxws/cxf/jbws3098/ClientServerLifeCycleTestCase*</exclude>
+
<exclude>org/jboss/test/ws/jaxws/cxf/jbws3060/*EJB3*</exclude>
<exclude>org/jboss/test/ws/jaxws/cxf/logging/**</exclude>
<!-- # [JBWS-3219] unexpected element 'security-domain'
encountered -->