JBossWS SVN: r3882 - trunk/jbossws-core/src/main/java/org/jboss/ws/core/client.
by jbossws-commits@lists.jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2007-07-13 09:48:43 -0400 (Fri, 13 Jul 2007)
New Revision: 3882
Modified:
trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java
Log:
[JBWS-1704] The Use Of Remoting Causes An Additional 'datatype' Parameter To Be Sent On All Requests
Modified: trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java 2007-07-13 13:42:05 UTC (rev 3881)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java 2007-07-13 13:48:43 UTC (rev 3882)
@@ -24,8 +24,10 @@
// $Id$
import java.io.IOException;
+import java.lang.reflect.Field;
import java.net.MalformedURLException;
import java.net.SocketTimeoutException;
+import java.net.URL;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Map;
@@ -40,6 +42,8 @@
import org.jboss.logging.Logger;
import org.jboss.remoting.Client;
import org.jboss.remoting.InvokerLocator;
+import org.jboss.remoting.Version;
+import org.jboss.remoting.marshal.MarshalFactory;
import org.jboss.remoting.marshal.Marshaller;
import org.jboss.remoting.marshal.UnMarshaller;
import org.jboss.ws.core.CommonMessageContext;
@@ -217,13 +221,31 @@
{
// Get the invoker from Remoting for a given endpoint address
log.debug("Get locator for: " + endpoint);
-
+
Marshaller marshaller = getMarshaller();
UnMarshaller unmarshaller = getUnmarshaller();
+
+ /**
+ * [JBWS-1704] The Use Of Remoting Causes An Additional 'datatype' Parameter To Be Sent On All Requests
+ *
+ * An HTTPClientInvoker may disconnect from the server and recreated by the remoting layer.
+ * In that case the new invoker does not inherit the marshaller/unmarshaller from the disconnected invoker.
+ * We therefore explicitly specify the invoker locator datatype and register the SOAP marshaller/unmarshaller
+ * with the MarshalFactory.
+ *
+ * This applies to remoting-1.4.5 and less
+ */
+ String version = getRemotingVersion();
+ if (version.startsWith("1.4"))
+ {
+ targetAddress = addURLParameter(targetAddress, InvokerLocator.DATATYPE, "JBossWSMessage");
+ MarshalFactory.addMarshaller("JBossWSMessage", marshaller, unmarshaller);
+ }
InvokerLocator locator = new InvokerLocator(targetAddress);
client = new Client(locator, "jbossws", clientConfig);
client.connect();
+
client.setMarshaller(marshaller);
if (oneway == false)
@@ -240,6 +262,28 @@
return client;
}
+ private String getRemotingVersion()
+ {
+ String version = null;
+ try
+ {
+ // Access the constant dynamically, otherwise it will be the compile time value
+ Field field = Version.class.getDeclaredField("VERSION");
+ version = (String)field.get(null);
+ }
+ catch (Exception ex)
+ {
+ throw new RuntimeException("Cannot obtain remoting version", ex);
+ }
+
+ if (version == null)
+ {
+ URL codeURL = Version.class.getProtectionDomain().getCodeSource().getLocation();
+ throw new RuntimeException("Cannot obtain remoting version from: " + codeURL);
+ }
+ return version;
+ }
+
protected abstract UnMarshaller getUnmarshaller();
protected abstract Marshaller getMarshaller();
17 years, 6 months
JBossWS SVN: r3881 - in branches/tdiesler/trunk: integration/native and 1 other directories.
by jbossws-commits@lists.jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2007-07-13 09:42:05 -0400 (Fri, 13 Jul 2007)
New Revision: 3881
Modified:
branches/tdiesler/trunk/build/ant-import/build-testsuite.xml
branches/tdiesler/trunk/integration/native/build.xml
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java
Log:
partial commit
Modified: branches/tdiesler/trunk/build/ant-import/build-testsuite.xml
===================================================================
--- branches/tdiesler/trunk/build/ant-import/build-testsuite.xml 2007-07-13 12:40:49 UTC (rev 3880)
+++ branches/tdiesler/trunk/build/ant-import/build-testsuite.xml 2007-07-13 13:42:05 UTC (rev 3881)
@@ -202,8 +202,10 @@
<pathelement location="${jboss.client}/jaxb-xjc.jar"/>
<pathelement location="${jboss.client}/jboss-aop-jdk50-client.jar"/>
<pathelement location="${jboss.client}/jboss-aspect-jdk50-client.jar"/>
+ <pathelement location="${jboss.client}/jboss-ejb3x.jar"/>
+ <pathelement location="${jboss.client}/jboss-ejb3-client.jar"/>
+ <pathelement location="${jboss.client}/jboss-saaj.jar"/>
<pathelement location="${jboss.client}/jbossws-jboss40.jar"/>
- <pathelement location="${jboss.client}/jboss-saaj.jar"/>
<pathelement location="${jboss.client}/jbossall-client.jar"/>
<pathelement location="${jboss.client}/log4j.jar"/>
<pathelement location="${jboss.client}/wsdl4j.jar"/>
Modified: branches/tdiesler/trunk/integration/native/build.xml
===================================================================
--- branches/tdiesler/trunk/integration/native/build.xml 2007-07-13 12:40:49 UTC (rev 3880)
+++ branches/tdiesler/trunk/integration/native/build.xml 2007-07-13 13:42:05 UTC (rev 3881)
@@ -259,7 +259,6 @@
<metainf dir="${core.dir}/src/main/resources/standard-config">
<include name="standard-*-config.xml"/>
</metainf>
- <metainf dir="${native.resources.dir}/jbossws-native40.sar/META-INF"/>
</jar>
</target>
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java 2007-07-13 12:40:49 UTC (rev 3880)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java 2007-07-13 13:42:05 UTC (rev 3881)
@@ -24,6 +24,7 @@
// $Id$
import java.io.IOException;
+import java.lang.reflect.Field;
import java.net.MalformedURLException;
import java.net.SocketTimeoutException;
import java.net.URL;
@@ -224,7 +225,7 @@
Marshaller marshaller = getMarshaller();
UnMarshaller unmarshaller = getUnmarshaller();
- /*
+ /**
* [JBWS-1704] The Use Of Remoting Causes An Additional 'datatype' Parameter To Be Sent On All Requests
*
* An HTTPClientInvoker may disconnect from the server and recreated by the remoting layer.
@@ -234,9 +235,8 @@
*
* This applies to remoting-1.4.5 and less
*/
- URL location = Version.class.getProtectionDomain().getCodeSource().getLocation();
- System.out.println(Version.VERSION + " - " + location);
- if (Version.VERSION.startsWith("1.4"))
+ String version = getRemotingVersion();
+ if (version.startsWith("1.4"))
{
targetAddress = addURLParameter(targetAddress, InvokerLocator.DATATYPE, "JBossWSMessage");
MarshalFactory.addMarshaller("JBossWSMessage", marshaller, unmarshaller);
@@ -262,6 +262,28 @@
return client;
}
+ private String getRemotingVersion()
+ {
+ String version = null;
+ try
+ {
+ // Access the constant dynamically, otherwise it will be the compile time value
+ Field field = Version.class.getDeclaredField("VERSION");
+ version = (String)field.get(null);
+ }
+ catch (Exception ex)
+ {
+ throw new RuntimeException("Cannot obtain remoting version", ex);
+ }
+
+ if (version == null)
+ {
+ URL codeURL = Version.class.getProtectionDomain().getCodeSource().getLocation();
+ throw new RuntimeException("Cannot obtain remoting version from: " + codeURL);
+ }
+ return version;
+ }
+
protected abstract UnMarshaller getUnmarshaller();
protected abstract Marshaller getMarshaller();
17 years, 6 months
JBossWS SVN: r3880 - in branches/tdiesler/trunk: integration/jboss40/src/main and 9 other directories.
by jbossws-commits@lists.jboss.org
Author: thomas.diesler(a)jboss.com
Date: 2007-07-13 08:40:49 -0400 (Fri, 13 Jul 2007)
New Revision: 3880
Added:
branches/tdiesler/trunk/integration/jboss40/src/main/resources/
branches/tdiesler/trunk/integration/jboss40/src/main/resources/jbossws-jboss40-config.xml
branches/tdiesler/trunk/integration/jboss40/src/main/resources/jbossws-jboss40.sar/
branches/tdiesler/trunk/integration/jboss40/src/main/resources/jbossws-jboss40.sar/META-INF/
branches/tdiesler/trunk/integration/jboss42/src/main/resources/jbossws-jboss42-config.xml
branches/tdiesler/trunk/integration/native/src/main/resources/jbossws-native-config.xml
Removed:
branches/tdiesler/trunk/integration/jboss42/src/main/resources/jbossws-jboss42.sar/jbossws.beans/
branches/tdiesler/trunk/integration/native/src/main/resources/jbossws-native40.sar/
branches/tdiesler/trunk/integration/native/src/main/resources/jbossws.beans/
Modified:
branches/tdiesler/trunk/build/ant-import/build-testsuite.xml
branches/tdiesler/trunk/integration/native/build.xml
branches/tdiesler/trunk/jbossws-core/.classpath
branches/tdiesler/trunk/jbossws-core/ant-import-tests/build-testsuite.xml
branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java
Log:
partial commit
Modified: branches/tdiesler/trunk/build/ant-import/build-testsuite.xml
===================================================================
--- branches/tdiesler/trunk/build/ant-import/build-testsuite.xml 2007-07-13 11:55:00 UTC (rev 3879)
+++ branches/tdiesler/trunk/build/ant-import/build-testsuite.xml 2007-07-13 12:40:49 UTC (rev 3880)
@@ -106,14 +106,18 @@
<pathelement location="${jboss.client}/jboss-common-core.jar"/>
<pathelement location="${jboss.client}/jboss-ejb3-client.jar"/>
<pathelement location="${jboss.client}/jboss-logging-spi.jar"/>
+ <pathelement location="${jboss.client}/jboss-remoting.jar"/>
<pathelement location="${jboss.client}/jboss-xml-binding.jar"/>
<pathelement location="${jboss.client}/mail.jar"/>
- <pathelement location="${jboss.client}/wsdl4j.jar"/>
- <pathelement location="${jboss.server.lib}/jboss-javaee.jar"/>
+ <pathelement location="${jboss.client}/wsdl4j.jar"/>
+ <pathelement location="${jboss.server.lib}/jboss-javaee.jar"/>
<pathelement location="${jboss.server.lib}/jbosssx.jar"/>
<pathelement location="${jboss.server.lib}/servlet-api.jar"/>
</path>
+
+ <!-- This classpath MUST NOT contain any local jars from thirdparty -->
<path id="tests.client.classpath">
+ <path refid="ws.stack.classpath"/>
<pathelement location="${jboss.client}/javassist.jar"/>
<pathelement location="${jboss.client}/jaxb-xjc.jar"/>
<pathelement location="${jboss.client}/jboss-jboss50.jar"/>
@@ -129,7 +133,6 @@
<pathelement location="${jboss.server.deploy}/juddi-service.sar/juddi.jar"/>
<pathelement location="${jboss.server.deploy}/juddi-service.sar/juddi-saaj.jar"/>
<pathelement location="${jboss.server.deploy}/juddi-service.sar/scout.jar"/>
- <path refid="tests.javac.classpath"/>
</path>
</target>
@@ -148,23 +151,25 @@
<pathelement location="${jboss.client}/jboss-xml-binding.jar"/>
<pathelement location="${jboss.client}/jbosssx-client.jar"/>
<pathelement location="${jboss.client}/mail.jar"/>
- <pathelement location="${jboss.client}/stax-api.jar"/>
+ <pathelement location="${jboss.client}/stax-api.jar"/>
<pathelement location="${jboss.client}/wsdl4j.jar"/>
<pathelement location="${jboss.server.lib}/servlet-api.jar"/>
</path>
+
+ <!-- This classpath MUST NOT contain any local jars from thirdparty -->
<path id="tests.client.classpath">
+ <path refid="ws.stack.classpath"/>
<pathelement location="${jboss.client}/commons-logging.jar"/>
<pathelement location="${jboss.client}/javassist.jar"/>
<pathelement location="${jboss.client}/jaxb-xjc.jar"/>
<pathelement location="${jboss.client}/jboss-annotations-ejb3.jar"/>
- <pathelement location="${jboss.client}/wsdl4j.jar"/>
- <pathelement location="${jboss.client}/log4j.jar"/>
<pathelement location="${jboss.client}/jbossws-jboss42.jar"/>
<pathelement location="${jboss.client}/jbossall-client.jar"/>
+ <pathelement location="${jboss.client}/log4j.jar"/>
+ <pathelement location="${jboss.client}/wsdl4j.jar"/>
<pathelement location="${jboss.server.deploy}/juddi-service.sar/juddi.jar"/>
<pathelement location="${jboss.server.deploy}/juddi-service.sar/juddi-saaj.jar"/>
<pathelement location="${jboss.server.deploy}/juddi-service.sar/scout.jar"/>
- <path refid="tests.javac.classpath"/>
</path>
</target>
@@ -180,28 +185,31 @@
<pathelement location="${jboss.client}/jboss-ejb3x.jar"/>
<pathelement location="${jboss.client}/jboss-ejb3-client.jar"/>
<pathelement location="${jboss.client}/jboss-j2ee.jar"/>
+ <pathelement location="${jboss.client}/jboss-remoting.jar"/>
<pathelement location="${jboss.client}/jboss-xml-binding.jar"/>
<pathelement location="${jboss.client}/mail.jar"/>
- <pathelement location="${jboss.client}/wsdl4j.jar"/>
- <pathelement location="${jboss.client}/stax-api.jar"/>
+ <pathelement location="${jboss.client}/wsdl4j.jar"/>
+ <pathelement location="${jboss.client}/stax-api.jar"/>
<pathelement location="${jboss.client}/jbosssx-client.jar"/>
<pathelement location="${jboss.server.lib}/javax.servlet.jar"/>
</path>
+
+ <!-- This classpath MUST NOT contain any local jars from thirdparty -->
<path id="tests.client.classpath">
+ <path refid="ws.stack.classpath"/>
<pathelement location="${jboss.client}/commons-logging.jar"/>
<pathelement location="${jboss.client}/javassist.jar"/>
<pathelement location="${jboss.client}/jaxb-xjc.jar"/>
<pathelement location="${jboss.client}/jboss-aop-jdk50-client.jar"/>
<pathelement location="${jboss.client}/jboss-aspect-jdk50-client.jar"/>
- <pathelement location="${jboss.client}/log4j.jar"/>
- <pathelement location="${jboss.client}/wsdl4j.jar"/>
<pathelement location="${jboss.client}/jbossws-jboss40.jar"/>
<pathelement location="${jboss.client}/jboss-saaj.jar"/>
<pathelement location="${jboss.client}/jbossall-client.jar"/>
+ <pathelement location="${jboss.client}/log4j.jar"/>
+ <pathelement location="${jboss.client}/wsdl4j.jar"/>
<pathelement location="${jboss.server.deploy}/juddi-service.sar/juddi.jar"/>
<pathelement location="${jboss.server.deploy}/juddi-service.sar/juddi-saaj.jar"/>
<pathelement location="${jboss.server.deploy}/juddi-service.sar/scout.jar"/>
- <path refid="tests.javac.classpath"/>
</path>
</target>
Added: branches/tdiesler/trunk/integration/jboss40/src/main/resources/jbossws-jboss40-config.xml
===================================================================
--- branches/tdiesler/trunk/integration/jboss40/src/main/resources/jbossws-jboss40-config.xml (rev 0)
+++ branches/tdiesler/trunk/integration/jboss40/src/main/resources/jbossws-jboss40-config.xml 2007-07-13 12:40:49 UTC (rev 3880)
@@ -0,0 +1,212 @@
+ <!--
+ *********************************************************************************************************************
+ Web Service deployment
+
+ There are three deployer interceptors registered with the JBoss Deployers.
+
+ 1) DeployerInterceptorJSE
+ 2) DeployerInterceptorEJB21
+ 3) DeployerInterceptorEJB3
+
+ Each interceptor has a number of DeployerHooks registerd with it
+
+ Conceptually, each of these hooks implements the following pattern:
+
+ DployerHook.deploy(unit)
+ if(isWebServiceDeployment)
+ Deployment dep = createDeployment(unit)
+ DeploymentAspectManager.deploy(dep)
+
+ DeployerHook.undeploy(unit)
+ Deployment dep = getDeployment(unit)
+ DeploymentAspectManager.undeploy(dep)
+
+ Each deployer hook has a web service DeployerManager injected into it.
+ A web service DeployerManager maintains a list of Deployers, each of which
+ handles a single aspect of web service deployment.
+
+ Finally, each Endpoint is registered with the EndpointRegistry.
+
+ *********************************************************************************************************************
+ -->
+
+ <!-- Locate the single instance of the kernel -->
+ <bean name="WSKernelLocator" class="org.jboss.ws.integration.KernelLocator">
+ <property name="kernel"><inject bean="jboss.kernel:service=Kernel"/></property>
+ </bean>
+
+ <!--
+ Register DeployerHooks with JBoss deployers
+ -->
+ <bean name="WSDeployerHook_JAXRPC_JSE" class="org.jboss.wsf.container.jboss42.JAXRPCDeployerHookJSE">
+ <property name="deploymentAspectManager"><inject bean="WSDeploymentAspectManagerJSE"/></property>
+ <property name="phaseOneInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorJSE</value>
+ </list>
+ </property>
+ </bean>
+ <bean name="WSDeployerHook_JAXRPC_EJB21" class="org.jboss.wsf.container.jboss42.JAXRPCDeployerHookEJB21">
+ <property name="deploymentAspectManager"><inject bean="WSDeploymentAspectManagerEJB"/></property>
+ <property name="phaseOneInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorEJB21</value>
+ </list>
+ </property>
+ </bean>
+ <bean name="WSDeployerHook_JAXWS_JSE" class="org.jboss.wsf.container.jboss42.JAXWSDeployerHookJSE">
+ <property name="deploymentAspectManager"><inject bean="WSDeploymentAspectManagerJSE"/></property>
+ <property name="phaseOneInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorJSE</value>
+ </list>
+ </property>
+ </bean>
+ <bean name="WSDeployerHook_JAXWS_EJB3" class="org.jboss.wsf.container.jboss42.JAXWSDeployerHookEJB3">
+ <property name="deploymentAspectManager"><inject bean="WSDeploymentAspectManagerEJB"/></property>
+ <property name="phaseOneInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorEJB3</value>
+ </list>
+ </property>
+ </bean>
+ <bean name="WSMainDeployerHook" class="org.jboss.wsf.container.jboss42.MainDeployerHook">
+ <property name="deploymentAspectManager"><inject bean="WSMainDeploymentAspectManager"/></property>
+ <property name="phaseTwoInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorJSE</value>
+ <value>jboss.ws:service=DeployerInterceptorEJB21</value>
+ <value>jboss.ws:service=DeployerInterceptorEJB3</value>
+ </list>
+ </property>
+ </bean>
+
+ <!--
+ Each DeploymentAspectManger maintains a list of DeploymentAspects
+ -->
+ <bean name="WSDeploymentAspectManagerJSE" class="org.jboss.wsf.spi.deployment.BasicDeploymentAspectManager">
+ <property name="name">WSDeploymentAspectManagerJSE</property>
+ </bean>
+ <bean name="WSDeploymentAspectManagerEJB" class="org.jboss.wsf.spi.deployment.BasicDeploymentAspectManager">
+ <property name="name">WSDeploymentAspectManagerEJB</property>
+ </bean>
+ <bean name="WSMainDeploymentAspectManager" class="org.jboss.wsf.spi.deployment.BasicDeploymentAspectManager">
+ <property name="name">WSMainDeploymentAspectManager</property>
+ </bean>
+
+ <!--
+ The container deployment aspects
+ -->
+ <bean name="WSClassLoaderInjectionDeploymentAspect" class="org.jboss.wsf.container.jboss42.ClassLoaderInjectionDeploymentAspect">
+ <property name="requires">AllowClassLoaderInjection</property>
+ <property name="provides">ContainerClassLoader</property>
+ </bean>
+
+ <bean name="WSContextRootDeploymentAspect" class="org.jboss.wsf.spi.deployment.BackwardCompatibleContextRootDeploymentAspect">
+ <property name="requires">ContainerMetaData</property>
+ <property name="provides">ContextRoot</property>
+ </bean>
+
+ <bean name="WSEndpointHandlerDeploymentAspect" class="org.jboss.wsf.spi.deployment.EndpointHandlerDeploymentAspect">
+ <property name="provides">ContainerEndpointHandler</property>
+ <property name="invocationHandler">
+ <map keyClass="java.lang.String" valueClass="java.lang.String">
+ <entry><key>JAXRPC_EJB21</key><value>org.jboss.wsf.container.jboss42.InvocationHandlerEJB21</value></entry>
+ <entry><key>JAXRPC_MDB21</key><value>org.jboss.wsf.container.jboss42.InvocationHandlerMDB21</value></entry>
+ <entry><key>JAXWS_JSE</key><value>org.jboss.wsf.spi.invocation.InvocationHandlerJSE</value></entry>
+ <entry><key>JAXWS_EJB3</key><value>org.jboss.wsf.container.jboss40.InvocationHandlerEJB3</value></entry>
+ </map>
+ </property>
+ </bean>
+
+ <bean name="WSEndpointLifecycleDeploymentAspect" class="org.jboss.wsf.spi.deployment.EndpointLifecycleDeploymentAspect">
+ <property name="requires">LAST_DEPLOYMENT_ASPECT</property>
+ </bean>
+
+ <bean name="WSEndpointMetricsDeploymentAspect" class="org.jboss.wsf.spi.deployment.EndpointMetricsDeploymentAspect">
+ <property name="endpointMetrics"><inject bean="WSEndpointMetrics"/></property>
+ </bean>
+
+ <bean name="WSEndpointNameDeploymentAspect" class="org.jboss.wsf.spi.deployment.EndpointNameDeploymentAspect">
+ <property name="requires">URLPattern</property>
+ <property name="provides">EndpointName</property>
+ </bean>
+
+ <bean name="WSEndpointRegistryDeploymentAspect" class="org.jboss.wsf.spi.deployment.EndpointRegistryDeploymentAspect">
+ <property name="requires">EndpointName,StackEndpointHandler,InitializedMetaDataModel</property>
+ <property name="provides">RegisteredEndpoint</property>
+ </bean>
+
+ <bean name="WSModifyWebMetaDataDeploymentAspect" class="org.jboss.wsf.container.jboss42.ModifyWebMetaDataDeploymentAspect">
+ <property name="requires">ContextProperties, ContainerMetaData</property>
+ <property name="webXMLRewriter"><inject bean="WSWebXMLRewriter"/></property>
+ </bean>
+
+ <bean name="WSUnifiedDeploymentInfoDeploymentAspect" class="org.jboss.wsf.container.jboss42.UnifiedDeploymentInfoDeploymentAspect">
+ <property name="provides">ContainerMetaData</property>
+ <property name="deploymentInfoAdapter"><inject bean="WSDeploymentInfoAdapter"/></property>
+ </bean>
+
+ <bean name="WSURLPatternDeploymentAspect" class="org.jboss.wsf.spi.deployment.BackwardCompatibleURLPatternDeploymentAspect">
+ <property name="requires">ContextRoot, ContainerMetaData</property>
+ <property name="provides">URLPattern</property>
+ </bean>
+
+ <bean name="WSWebAppDeploymentAspect" class="org.jboss.wsf.container.jboss42.WebAppDeploymentAspect">
+ <property name="requires">WebMetaData, ContextProperties</property>
+ <property name="webXMLRewriter"><inject bean="WSWebXMLRewriter"/></property>
+ </bean>
+
+ <bean name="WSWebAppGeneratorDeploymentAspect" class="org.jboss.wsf.spi.deployment.WebAppGeneratorDeploymentAspect">
+ <property name="requires">URLPattern</property>
+ <property name="provides">WebMetaData</property>
+ <property name="securityHandlerEJB21"><inject bean="WSSecurityHandlerEJB21"/></property>
+ <property name="securityHandlerEJB3"><inject bean="WSSecurityHandlerEJB3"/></property>
+ </bean>
+
+ <!-- Deployment aspect helper beans -->
+ <bean name="WSApplicationMetaDataAdapterEJB21" class="org.jboss.wsf.container.jboss40.ApplicationMetaDataAdapterEJB21"/>
+ <bean name="WSApplicationMetaDataAdapterEJB3" class="org.jboss.wsf.container.jboss42.ApplicationMetaDataAdapterEJB3"/>
+ <bean name="WSDeploymentInfoAdapter" class="org.jboss.wsf.container.jboss42.DeploymentInfoAdapter">
+ <property name="applicationMetaDataAdapterEJB21"><inject bean="WSApplicationMetaDataAdapterEJB21"/></property>
+ <property name="applicationMetaDataAdapterEJB3"><inject bean="WSApplicationMetaDataAdapterEJB3"/></property>
+ <property name="webMetaDataAdapter"><inject bean="WSWebMetaDataAdapter"/></property>
+ </bean>
+ <bean name="WSEndpointMetrics" class="org.jboss.wsf.spi.management.BasicEndpointMetrics"/>
+ <bean name="WSSecurityHandlerEJB21" class="org.jboss.wsf.container.jboss42.SecurityHandlerEJB21"/>
+ <bean name="WSSecurityHandlerEJB3" class="org.jboss.wsf.container.jboss42.SecurityHandlerEJB3"/>
+ <bean name="WSServiceRefMetaDataAdapter" class="org.jboss.wsf.container.jboss40.ServiceRefMetaDataAdapter"/>
+ <bean name="WSWebAppDesciptorModifier" class="org.jboss.wsf.spi.deployment.WebAppDesciptorModifierImpl"/>
+ <bean name="WSWebMetaDataAdapter" class="org.jboss.wsf.container.jboss42.WebMetaDataAdapter"/>
+ <bean name="WSWebXMLRewriter" class="org.jboss.wsf.spi.deployment.WebXMLRewriter">
+ <property name="desciptorModifier"><inject bean="WSWebAppDesciptorModifier"/></property>
+ </bean>
+
+ <!-- Deployment aspect installers -->
+ <bean name="WSDeploymentAspectInstallerJSE" class="org.jboss.wsf.spi.deployment.DeploymentAspectInstaller">
+ <property name="manager"><inject bean="WSDeploymentAspectManagerJSE"/></property>
+ <property name="aspects">
+ <set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSModifyWebMetaDataDeploymentAspect"/>
+ <inject bean="WSUnifiedDeploymentInfoDeploymentAspect"/>
+ </set>
+ </property>
+ </bean>
+ <bean name="WSMainDeploymentAspectInstaller" class="org.jboss.wsf.spi.deployment.DeploymentAspectInstaller">
+ <property name="manager"><inject bean="WSMainDeploymentAspectManager"/></property>
+ <property name="aspects">
+ <set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSClassLoaderInjectionDeploymentAspect"/>
+ <inject bean="WSContextRootDeploymentAspect"/>
+ <inject bean="WSEndpointHandlerDeploymentAspect"/>
+ <inject bean="WSEndpointLifecycleDeploymentAspect"/>
+ <inject bean="WSEndpointMetricsDeploymentAspect"/>
+ <inject bean="WSEndpointNameDeploymentAspect"/>
+ <inject bean="WSEndpointRegistryDeploymentAspect"/>
+ <inject bean="WSUnifiedDeploymentInfoDeploymentAspect"/>
+ <inject bean="WSURLPatternDeploymentAspect"/>
+ <inject bean="WSWebAppDeploymentAspect"/>
+ <inject bean="WSWebAppGeneratorDeploymentAspect"/>
+ </set>
+ </property>
+ </bean>
Copied: branches/tdiesler/trunk/integration/jboss40/src/main/resources/jbossws-jboss40.sar/META-INF (from rev 3869, branches/tdiesler/trunk/integration/native/src/main/resources/jbossws-native40.sar/META-INF)
Added: branches/tdiesler/trunk/integration/jboss42/src/main/resources/jbossws-jboss42-config.xml
===================================================================
--- branches/tdiesler/trunk/integration/jboss42/src/main/resources/jbossws-jboss42-config.xml (rev 0)
+++ branches/tdiesler/trunk/integration/jboss42/src/main/resources/jbossws-jboss42-config.xml 2007-07-13 12:40:49 UTC (rev 3880)
@@ -0,0 +1,211 @@
+ <!--
+ *********************************************************************************************************************
+ Web Service deployment
+
+ There are three deployer interceptors registered with the JBoss Deployers.
+
+ 1) DeployerInterceptorJSE
+ 2) DeployerInterceptorEJB21
+ 3) DeployerInterceptorEJB3
+
+ Each interceptor has a number of DeployerHooks registerd with it
+
+ Conceptually, each of these hooks implements the following pattern:
+
+ DployerHook.deploy(unit)
+ if(isWebServiceDeployment)
+ Deployment dep = createDeployment(unit)
+ DeploymentAspectManager.deploy(dep)
+
+ DeployerHook.undeploy(unit)
+ Deployment dep = getDeployment(unit)
+ DeploymentAspectManager.undeploy(dep)
+
+ Each deployer hook has a web service DeployerManager injected into it.
+ A web service DeployerManager maintains a list of Deployers, each of which
+ handles a single aspect of web service deployment.
+
+ Finally, each Endpoint is registered with the EndpointRegistry.
+
+ *********************************************************************************************************************
+ -->
+
+ <!-- Locate the single instance of the kernel -->
+ <bean name="WSKernelLocator" class="org.jboss.ws.integration.KernelLocator">
+ <property name="kernel"><inject bean="jboss.kernel:service=Kernel"/></property>
+ </bean>
+
+ <!--
+ Register DeployerHooks with JBoss deployers
+ -->
+ <bean name="WSDeployerHook_JAXRPC_JSE" class="org.jboss.wsf.container.jboss42.JAXRPCDeployerHookJSE">
+ <property name="deploymentAspectManager"><inject bean="WSDeploymentAspectManagerJSE"/></property>
+ <property name="phaseOneInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorJSE</value>
+ </list>
+ </property>
+ </bean>
+ <bean name="WSDeployerHook_JAXRPC_EJB21" class="org.jboss.wsf.container.jboss42.JAXRPCDeployerHookEJB21">
+ <property name="deploymentAspectManager"><inject bean="WSDeploymentAspectManagerEJB"/></property>
+ <property name="phaseOneInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorEJB21</value>
+ </list>
+ </property>
+ </bean>
+ <bean name="WSDeployerHook_JAXWS_JSE" class="org.jboss.wsf.container.jboss42.JAXWSDeployerHookJSE">
+ <property name="deploymentAspectManager"><inject bean="WSDeploymentAspectManagerJSE"/></property>
+ <property name="phaseOneInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorJSE</value>
+ </list>
+ </property>
+ </bean>
+ <bean name="WSDeployerHook_JAXWS_EJB3" class="org.jboss.wsf.container.jboss42.JAXWSDeployerHookEJB3">
+ <property name="deploymentAspectManager"><inject bean="WSDeploymentAspectManagerEJB"/></property>
+ <property name="phaseOneInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorEJB3</value>
+ </list>
+ </property>
+ </bean>
+ <bean name="WSMainDeployerHook" class="org.jboss.wsf.container.jboss42.MainDeployerHook">
+ <property name="deploymentAspectManager"><inject bean="WSMainDeploymentAspectManager"/></property>
+ <property name="phaseTwoInterceptors">
+ <list class="java.util.LinkedList" elementClass="javax.management.ObjectName">
+ <value>jboss.ws:service=DeployerInterceptorJSE</value>
+ <value>jboss.ws:service=DeployerInterceptorEJB21</value>
+ <value>jboss.ws:service=DeployerInterceptorEJB3</value>
+ </list>
+ </property>
+ </bean>
+
+ <!--
+ Each DeploymentAspectManger maintains a list of DeploymentAspects
+ -->
+ <bean name="WSDeploymentAspectManagerJSE" class="org.jboss.wsf.spi.deployment.BasicDeploymentAspectManager">
+ <property name="name">WSDeploymentAspectManagerJSE</property>
+ </bean>
+ <bean name="WSDeploymentAspectManagerEJB" class="org.jboss.wsf.spi.deployment.BasicDeploymentAspectManager">
+ <property name="name">WSDeploymentAspectManagerEJB</property>
+ </bean>
+ <bean name="WSMainDeploymentAspectManager" class="org.jboss.wsf.spi.deployment.BasicDeploymentAspectManager">
+ <property name="name">WSMainDeploymentAspectManager</property>
+ </bean>
+
+ <!--
+ The container deployment aspects
+ -->
+ <bean name="WSClassLoaderInjectionDeploymentAspect" class="org.jboss.wsf.container.jboss42.ClassLoaderInjectionDeploymentAspect">
+ <property name="requires">AllowClassLoaderInjection</property>
+ <property name="provides">ContainerClassLoader</property>
+ </bean>
+
+ <bean name="WSContextRootDeploymentAspect" class="org.jboss.wsf.spi.deployment.BackwardCompatibleContextRootDeploymentAspect">
+ <property name="requires">ContainerMetaData</property>
+ <property name="provides">ContextRoot</property>
+ </bean>
+
+ <bean name="WSEndpointHandlerDeploymentAspect" class="org.jboss.wsf.spi.deployment.EndpointHandlerDeploymentAspect">
+ <property name="provides">ContainerEndpointHandler</property>
+ <property name="invocationHandler">
+ <map keyClass="java.lang.String" valueClass="java.lang.String">
+ <entry><key>JAXRPC_EJB21</key><value>org.jboss.wsf.container.jboss42.InvocationHandlerEJB21</value></entry>
+ <entry><key>JAXRPC_MDB21</key><value>org.jboss.wsf.container.jboss42.InvocationHandlerMDB21</value></entry>
+ <entry><key>JAXWS_JSE</key><value>org.jboss.wsf.spi.invocation.InvocationHandlerJSE</value></entry>
+ <entry><key>JAXWS_EJB3</key><value>org.jboss.wsf.container.jboss42.InvocationHandlerEJB3</value></entry>
+ </map>
+ </property>
+ </bean>
+
+ <bean name="WSEndpointLifecycleDeploymentAspect" class="org.jboss.wsf.spi.deployment.EndpointLifecycleDeploymentAspect">
+ <property name="requires">LAST_DEPLOYMENT_ASPECT</property>
+ </bean>
+
+ <bean name="WSEndpointMetricsDeploymentAspect" class="org.jboss.wsf.spi.deployment.EndpointMetricsDeploymentAspect">
+ <property name="endpointMetrics"><inject bean="WSEndpointMetrics"/></property>
+ </bean>
+
+ <bean name="WSEndpointNameDeploymentAspect" class="org.jboss.wsf.spi.deployment.EndpointNameDeploymentAspect">
+ <property name="requires">URLPattern</property>
+ <property name="provides">EndpointName</property>
+ </bean>
+
+ <bean name="WSEndpointRegistryDeploymentAspect" class="org.jboss.wsf.spi.deployment.EndpointRegistryDeploymentAspect">
+ <property name="requires">EndpointName,StackEndpointHandler,InitializedMetaDataModel</property>
+ <property name="provides">RegisteredEndpoint</property>
+ </bean>
+
+ <bean name="WSModifyWebMetaDataDeploymentAspect" class="org.jboss.wsf.container.jboss42.ModifyWebMetaDataDeploymentAspect">
+ <property name="requires">ContextProperties, ContainerMetaData</property>
+ <property name="webXMLRewriter"><inject bean="WSWebXMLRewriter"/></property>
+ </bean>
+
+ <bean name="WSUnifiedDeploymentInfoDeploymentAspect" class="org.jboss.wsf.container.jboss42.UnifiedDeploymentInfoDeploymentAspect">
+ <property name="provides">ContainerMetaData</property>
+ <property name="deploymentInfoAdapter"><inject bean="WSDeploymentInfoAdapter"/></property>
+ </bean>
+
+ <bean name="WSURLPatternDeploymentAspect" class="org.jboss.wsf.spi.deployment.BackwardCompatibleURLPatternDeploymentAspect">
+ <property name="requires">ContextRoot, ContainerMetaData</property>
+ <property name="provides">URLPattern</property>
+ </bean>
+
+ <bean name="WSWebAppDeploymentAspect" class="org.jboss.wsf.container.jboss42.WebAppDeploymentAspect">
+ <property name="requires">WebMetaData, ContextProperties</property>
+ <property name="webXMLRewriter"><inject bean="WSWebXMLRewriter"/></property>
+ </bean>
+
+ <bean name="WSWebAppGeneratorDeploymentAspect" class="org.jboss.wsf.spi.deployment.WebAppGeneratorDeploymentAspect">
+ <property name="requires">URLPattern</property>
+ <property name="provides">WebMetaData</property>
+ <property name="securityHandlerEJB21"><inject bean="WSSecurityHandlerEJB21"/></property>
+ <property name="securityHandlerEJB3"><inject bean="WSSecurityHandlerEJB3"/></property>
+ </bean>
+
+ <!-- Deployment aspect helper beans -->
+ <bean name="WSApplicationMetaDataAdapterEJB21" class="org.jboss.wsf.container.jboss42.ApplicationMetaDataAdapterEJB21"/>
+ <bean name="WSApplicationMetaDataAdapterEJB3" class="org.jboss.wsf.container.jboss42.ApplicationMetaDataAdapterEJB3"/>
+ <bean name="WSDeploymentInfoAdapter" class="org.jboss.wsf.container.jboss42.DeploymentInfoAdapter">
+ <property name="applicationMetaDataAdapterEJB21"><inject bean="WSApplicationMetaDataAdapterEJB21"/></property>
+ <property name="applicationMetaDataAdapterEJB3"><inject bean="WSApplicationMetaDataAdapterEJB3"/></property>
+ <property name="webMetaDataAdapter"><inject bean="WSWebMetaDataAdapter"/></property>
+ </bean>
+ <bean name="WSEndpointMetrics" class="org.jboss.wsf.spi.management.BasicEndpointMetrics"/>
+ <bean name="WSSecurityHandlerEJB21" class="org.jboss.wsf.container.jboss42.SecurityHandlerEJB21"/>
+ <bean name="WSSecurityHandlerEJB3" class="org.jboss.wsf.container.jboss42.SecurityHandlerEJB3"/>
+ <bean name="WSWebAppDesciptorModifier" class="org.jboss.wsf.spi.deployment.WebAppDesciptorModifierImpl"/>
+ <bean name="WSWebMetaDataAdapter" class="org.jboss.wsf.container.jboss42.WebMetaDataAdapter"/>
+ <bean name="WSWebXMLRewriter" class="org.jboss.wsf.spi.deployment.WebXMLRewriter">
+ <property name="desciptorModifier"><inject bean="WSWebAppDesciptorModifier"/></property>
+ </bean>
+
+ <!-- Deployment aspect installers -->
+ <bean name="WSDeploymentAspectInstallerJSE" class="org.jboss.wsf.spi.deployment.DeploymentAspectInstaller">
+ <property name="manager"><inject bean="WSDeploymentAspectManagerJSE"/></property>
+ <property name="aspects">
+ <set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSModifyWebMetaDataDeploymentAspect"/>
+ <inject bean="WSUnifiedDeploymentInfoDeploymentAspect"/>
+ </set>
+ </property>
+ </bean>
+ <bean name="WSMainDeploymentAspectInstaller" class="org.jboss.wsf.spi.deployment.DeploymentAspectInstaller">
+ <property name="manager"><inject bean="WSMainDeploymentAspectManager"/></property>
+ <property name="aspects">
+ <set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSClassLoaderInjectionDeploymentAspect"/>
+ <inject bean="WSContextRootDeploymentAspect"/>
+ <inject bean="WSEndpointHandlerDeploymentAspect"/>
+ <inject bean="WSEndpointLifecycleDeploymentAspect"/>
+ <inject bean="WSEndpointMetricsDeploymentAspect"/>
+ <inject bean="WSEndpointNameDeploymentAspect"/>
+ <inject bean="WSEndpointRegistryDeploymentAspect"/>
+ <inject bean="WSUnifiedDeploymentInfoDeploymentAspect"/>
+ <inject bean="WSURLPatternDeploymentAspect"/>
+ <inject bean="WSWebAppDeploymentAspect"/>
+ <inject bean="WSWebAppGeneratorDeploymentAspect"/>
+ </set>
+ </property>
+ </bean>
Modified: branches/tdiesler/trunk/integration/native/build.xml
===================================================================
--- branches/tdiesler/trunk/integration/native/build.xml 2007-07-13 11:55:00 UTC (rev 3879)
+++ branches/tdiesler/trunk/integration/native/build.xml 2007-07-13 12:40:49 UTC (rev 3880)
@@ -175,8 +175,8 @@
<header trimleading="yes">
<deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:jboss:bean-deployer bean-deployer_1_0.xsd" xmlns="urn:jboss:bean-deployer">
</header>
- <fileset file="${native.resources.dir}/jbossws.beans/META-INF/jbossws-stack-config.xml"/>
- <fileset file="${int.jboss42.dir}/src/main/resources/jbossws-jboss42.sar/jbossws.beans/META-INF/jbossws-container-config.xml"/>
+ <fileset file="${native.resources.dir}/jbossws-native-config.xml"/>
+ <fileset file="${int.jboss42.dir}/src/main/resources/jbossws-jboss42-config.xml"/>
<footer trimleading="yes">
</deployment>
</footer>
@@ -220,6 +220,18 @@
<ant antfile="${int.jboss40.dir}/build.xml" target="jars" inheritall="false"/>
+ <!-- Concat jboss-beans.xml -->
+ <concat destfile="${native.output.lib.dir}/jbossws-native40/jbossws.beans/META-INF/jboss-beans.xml">
+ <header trimleading="yes">
+ <deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:jboss:bean-deployer bean-deployer_1_0.xsd" xmlns="urn:jboss:bean-deployer">
+ </header>
+ <fileset file="${native.resources.dir}/jbossws-native-config.xml"/>
+ <fileset file="${int.jboss40.dir}/src/main/resources/jbossws-jboss40-config.xml"/>
+ <footer trimleading="yes">
+ </deployment>
+ </footer>
+ </concat>
+
<!-- Build jbossws-native40.sar -->
<mkdir dir="${native.output.lib.dir}"/>
<jar jarfile="${native.output.lib.dir}/jbossws-native40.sar" manifest="${native.output.etc.dir}/default.mf">
@@ -240,9 +252,10 @@
<include name="xmlsec.jar"/>
<include name="wstx.jar"/>
</fileset>
- <fileset dir="${native.resources.dir}/jbossws-native40.sar">
+ <fileset dir="${native.output.lib.dir}/jbossws-native40">
<include name="jbossws.beans/**"/>
</fileset>
+ <metainf dir="${int.jboss40.dir}/src/main/resources/jbossws-jboss40.sar/META-INF"/>
<metainf dir="${core.dir}/src/main/resources/standard-config">
<include name="standard-*-config.xml"/>
</metainf>
Added: branches/tdiesler/trunk/integration/native/src/main/resources/jbossws-native-config.xml
===================================================================
--- branches/tdiesler/trunk/integration/native/src/main/resources/jbossws-native-config.xml (rev 0)
+++ branches/tdiesler/trunk/integration/native/src/main/resources/jbossws-native-config.xml 2007-07-13 12:40:49 UTC (rev 3880)
@@ -0,0 +1,109 @@
+
+ <!-- An abstraction of server configuration aspects. -->
+ <bean name="WSServerConfig" class="org.jboss.wsf.spi.management.BasicServerConfig">
+ <!--
+ The WSDL, that is a required deployment artifact for an endpoint, has a <soap:address>
+ element which points to the location of the endpoint. JBoss supports rewriting of that SOAP address.
+
+ If the content of <soap:address> is a valid URL, JBossWS will not rewrite it unless 'modifySOAPAddress' is true.
+ If the content of <soap:address> is not a valid URL, JBossWS will rewrite it using the attribute values given below.
+
+ If 'webServiceHost' is not set, JBossWS uses requesters protocol host when rewriting the <soap:address>.
+ -->
+ <property name="webServiceHost">${jboss.bind.address}</property>
+ <property name="modifySOAPAddress">true</property>
+
+ <!--
+ Set these properties to explicitly define the ports that will be used for rewriting the SOAP address.
+ Otherwise the ports will be identified by querying the list of installed connectors.
+ If multiple connectors are found the port of the first connector is used.
+ <property name="webServiceSecurePort">8443</property>
+ <property name="webServicePort">8080</property>
+ -->
+ </bean>
+
+ <!-- The registry for web service endpoints -->
+ <bean name="WSEndpointRegistry" class="org.jboss.wsf.stack.jbws.ManagedEndpointRegistry"/>
+
+ <!-- A subscription manager for WS-Eventing -->
+ <bean name="WSSubscriptionManager" class="org.jboss.ws.extensions.eventing.mgmt.SubscriptionManager">
+ <property name="bindAddress">${jboss.bind.address}</property>
+ </bean>
+
+ <!-- Bind Service objects in client environment context -->
+ <bean name="WSServiceRefHandler" class="org.jboss.ws.core.client.ServiceRefHandlerImpl"/>
+
+ <!-- Note, JBoss_4_2_0_GA uses this hardcoded bean name -->
+ <bean name="ServiceRefHandler" class="org.jboss.ws.core.client.ServiceRefHandlerImpl"/>
+
+ <!--
+ The stack specific deployment aspects
+ -->
+ <bean name="WSNativeContextPropertiesDeploymentAspect" class="org.jboss.wsf.spi.deployment.ContextPropertiesDeploymentAspect">
+ <property name="provides">ContextProperties</property>
+ <property name="contextProperties">
+ <map keyClass="java.lang.String" valueClass="java.lang.String">
+ <entry><key>SERVICE_ENDPOINT_SERVLET</key><value>org.jboss.wsf.stack.jbws.ServiceEndpointServlet</value></entry>
+ </map>
+ </property>
+ </bean>
+
+ <bean name="WSNativeEagerInitializeDeploymentAspect" class="org.jboss.wsf.stack.jbws.EagerInitializeDeploymentAspect">
+ <property name="requires">ContainerClassLoader,UnifiedMetaDataModel</property>
+ <property name="provides">InitializedMetaDataModel</property>
+ </bean>
+
+ <bean name="WSNativeEndpointHandlerDeploymentAspect" class="org.jboss.wsf.spi.deployment.EndpointHandlerDeploymentAspect">
+ <property name="requires">ContainerEndpointHandler</property>
+ <property name="provides">StackEndpointHandler</property>
+ <property name="requestHandler">org.jboss.wsf.stack.jbws.RequestHandlerImpl</property>
+ <property name="lifecycleHandler">org.jboss.wsf.stack.jbws.LifecycleHandlerImpl</property>
+ <property name="invocationHandler">
+ <map keyClass="java.lang.String" valueClass="java.lang.String">
+ <entry><key>JAXRPC_JSE</key><value>org.jboss.wsf.stack.jbws.ServiceLifecycleInvocationHandler</value></entry>
+ </map>
+ </property>
+ </bean>
+
+ <bean name="WSNativeEventingDeploymentAspect" class="org.jboss.wsf.stack.jbws.EventingDeploymentAspect">
+ <property name="requires">UnifiedMetaDataModel</property>
+ </bean>
+
+ <bean name="WSNativePublishContractDeploymentAspect" class="org.jboss.wsf.stack.jbws.PublishContractDeploymentAspect">
+ <property name="requires">UnifiedMetaDataModel</property>
+ <property name="provides">PublishedContract</property>
+ </bean>
+
+ <bean name="WSNativeServiceEndpointInvokerDeploymentAspect" class="org.jboss.wsf.stack.jbws.ServiceEndpointInvokerDeploymentAspect">
+ <property name="requires">UnifiedMetaDataModel</property>
+ </bean>
+
+ <bean name="WSNativeUnifiedMetaDataDeploymentAspect" class="org.jboss.wsf.stack.jbws.UnifiedMetaDataDeploymentAspect">
+ <property name="requires">ContainerMetaData, URLPattern</property>
+ <property name="provides">UnifiedMetaDataModel, AllowClassLoaderInjection</property>
+ </bean>
+
+ <!-- Deployment aspect installers -->
+ <bean name="WSNativeJSEDeploymentAspectInstaller" class="org.jboss.wsf.spi.deployment.DeploymentAspectInstaller">
+ <property name="manager"><inject bean="WSDeploymentAspectManagerJSE"/></property>
+ <property name="aspects">
+ <set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSNativeContextPropertiesDeploymentAspect"/>
+ </set>
+ </property>
+ </bean>
+ <bean name="WSNativeMainDeploymentAspectInstaller" class="org.jboss.wsf.spi.deployment.DeploymentAspectInstaller">
+ <property name="manager"><inject bean="WSMainDeploymentAspectManager"/></property>
+ <property name="aspects">
+ <set class="java.util.HashSet" elementClass="org.jboss.wsf.spi.deployment.DeploymentAspect">
+ <inject bean="WSNativeContextPropertiesDeploymentAspect"/>
+ <inject bean="WSNativeEagerInitializeDeploymentAspect"/>
+ <inject bean="WSNativeEndpointHandlerDeploymentAspect"/>
+ <inject bean="WSNativeEventingDeploymentAspect"/>
+ <inject bean="WSNativePublishContractDeploymentAspect"/>
+ <inject bean="WSNativeServiceEndpointInvokerDeploymentAspect"/>
+ <inject bean="WSNativeUnifiedMetaDataDeploymentAspect"/>
+ </set>
+ </property>
+ </bean>
+
Modified: branches/tdiesler/trunk/jbossws-core/.classpath
===================================================================
--- branches/tdiesler/trunk/jbossws-core/.classpath 2007-07-13 11:55:00 UTC (rev 3879)
+++ branches/tdiesler/trunk/jbossws-core/.classpath 2007-07-13 12:40:49 UTC (rev 3880)
@@ -15,7 +15,7 @@
<classpathentry kind="lib" path="thirdparty/jboss-j2ee.jar"/>
<classpathentry kind="lib" path="thirdparty/jboss-logging-spi.jar"/>
<classpathentry kind="lib" path="thirdparty/jboss-microcontainer.jar"/>
- <classpathentry kind="lib" path="thirdparty/jboss-remoting.jar" sourcepath="thirdparty/jboss-remoting-src.jar"/>
+ <classpathentry kind="lib" path="thirdparty/jboss-remoting.jar" sourcepath="/home/tdiesler/svn/jbossas/tags/JBoss_4_0_5_GA/thirdparty/jboss/remoting/lib/jboss-remoting-src.jar"/>
<classpathentry kind="lib" path="thirdparty/jbosssx-client.jar"/>
<classpathentry kind="lib" path="thirdparty/jboss-xml-binding.jar" sourcepath="thirdparty/jboss-xml-binding-sources.jar"/>
<classpathentry kind="lib" path="thirdparty/mail.jar"/>
Modified: branches/tdiesler/trunk/jbossws-core/ant-import-tests/build-testsuite.xml
===================================================================
--- branches/tdiesler/trunk/jbossws-core/ant-import-tests/build-testsuite.xml 2007-07-13 11:55:00 UTC (rev 3879)
+++ branches/tdiesler/trunk/jbossws-core/ant-import-tests/build-testsuite.xml 2007-07-13 12:40:49 UTC (rev 3880)
@@ -38,7 +38,6 @@
<pathelement location="${spi.dir}/output/lib/jbossws-spi.jar"/>
<pathelement location="${core.dir}/thirdparty/ejb3.deployer/jboss-annotations-ejb3.jar"/>
<pathelement location="${core.dir}/thirdparty/ejb3.deployer/jboss-ejb3.jar"/>
- <pathelement location="${core.dir}/thirdparty/jboss-remoting.jar"/>
<pathelement location="${core.dir}/thirdparty/policy.jar"/>
<pathelement location="${core.dir}/thirdparty/qdox.jar"/>
<pathelement location="${core.dir}/thirdparty/wsdl4j.jar"/>
Modified: branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java
===================================================================
--- branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java 2007-07-13 11:55:00 UTC (rev 3879)
+++ branches/tdiesler/trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/RemotingConnectionImpl.java 2007-07-13 12:40:49 UTC (rev 3880)
@@ -26,6 +26,7 @@
import java.io.IOException;
import java.net.MalformedURLException;
import java.net.SocketTimeoutException;
+import java.net.URL;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Map;
@@ -40,6 +41,8 @@
import org.jboss.logging.Logger;
import org.jboss.remoting.Client;
import org.jboss.remoting.InvokerLocator;
+import org.jboss.remoting.Version;
+import org.jboss.remoting.marshal.MarshalFactory;
import org.jboss.remoting.marshal.Marshaller;
import org.jboss.remoting.marshal.UnMarshaller;
import org.jboss.ws.core.CommonMessageContext;
@@ -217,13 +220,32 @@
{
// Get the invoker from Remoting for a given endpoint address
log.debug("Get locator for: " + endpoint);
-
+
Marshaller marshaller = getMarshaller();
UnMarshaller unmarshaller = getUnmarshaller();
+
+ /*
+ * [JBWS-1704] The Use Of Remoting Causes An Additional 'datatype' Parameter To Be Sent On All Requests
+ *
+ * An HTTPClientInvoker may disconnect from the server and recreated by the remoting layer.
+ * In that case the new invoker does not inherit the marshaller/unmarshaller from the disconnected invoker.
+ * We therefore explicitly specify the invoker locator datatype and register the SOAP marshaller/unmarshaller
+ * with the MarshalFactory.
+ *
+ * This applies to remoting-1.4.5 and less
+ */
+ URL location = Version.class.getProtectionDomain().getCodeSource().getLocation();
+ System.out.println(Version.VERSION + " - " + location);
+ if (Version.VERSION.startsWith("1.4"))
+ {
+ targetAddress = addURLParameter(targetAddress, InvokerLocator.DATATYPE, "JBossWSMessage");
+ MarshalFactory.addMarshaller("JBossWSMessage", marshaller, unmarshaller);
+ }
InvokerLocator locator = new InvokerLocator(targetAddress);
client = new Client(locator, "jbossws", clientConfig);
client.connect();
+
client.setMarshaller(marshaller);
if (oneway == false)
17 years, 6 months
JBossWS SVN: r3879 - in trunk: integration/native/src/main/resources/jbossws-native50.sar/META-INF and 32 other directories.
by jbossws-commits@lists.jboss.org
Author: heiko.braun(a)jboss.com
Date: 2007-07-13 07:55:00 -0400 (Fri, 13 Jul 2007)
New Revision: 3879
Added:
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/WSFException.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/CommonServiceRefBinder.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefBinder.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefHandlerImpl.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefObjectFactory.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/DummyServiceRefBinderJAXRPC.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/ServiceRefBinderJAXWS.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceObjectFactory.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceReferenceable.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/injection/
trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceRefBinderJAXRPC.java
trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxws/client/ServiceRefBinderJAXWS.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java
trunk/testsuite/src/resources/jaxws/samples/serviceref/
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl
trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/
trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml
trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/
trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/
trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml
Removed:
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/CommonServiceRefBinder.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefBinder.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefHandlerImpl.java
trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefObjectFactory.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/DummyServiceRefBinderJAXRPC.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/ServiceRefBinderJAXWS.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceObjectFactory.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceReferenceable.java
trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java
trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java
trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceRefHandlerJAXRPC.java
trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxws/client/ServiceRefHandlerJAXWS.java
trunk/jbossws-core/src/test/java/org/jboss/test/ws/jaxws/serviceref/
trunk/jbossws-core/src/test/resources/jaxws/serviceref/
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/
trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl
trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/
trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml
trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/
trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/
trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml
Modified:
trunk/integration/native/src/main/resources/jbossws-native42.sar/jbossws.beans/META-INF/jboss-beans.xml
trunk/integration/native/src/main/resources/jbossws-native50.sar/META-INF/jbossws-beans.xml
trunk/integration/spi/src/main/java/org/jboss/ws/integration/ServiceRefHandler.java
trunk/integration/spi/src/main/java/org/jboss/ws/integration/ServiceRefHandlerFactory.java
trunk/integration/sunri/ant-import/build-testsuite.xml
trunk/integration/sunri/build.xml
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/DeploymentDescriptorParserExt.java
trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/WSServletContextListenerExt.java
trunk/integration/sunri/src/main/resources/jbossws-sunri42.sar/jbossws.beans/META-INF/jboss-beans.xml
trunk/integration/sunri/src/main/resources/jbossws-sunri50.deployer/META-INF/jbossws-deployer-beans.xml
trunk/integration/sunri/src/main/resources/jbossws-sunri50.sar/META-INF/jbossws-beans.xml
trunk/integration/sunri/src/test/resources/test-excludes.txt
trunk/jbossws-core/ant-import-tests/build-jars-jaxws.xml
trunk/jbossws-core/src/test/resources/test-excludes-jboss40.txt
trunk/jbossws-core/src/test/resources/test-excludes-jboss42.txt
trunk/jbossws-core/src/test/resources/test-excludes-jboss50.txt
trunk/testsuite/ant-import/build-jars-jaxws.xml
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/OrderMgmtBean.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/cc/CCVerification.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/cc/CCVerificationBean.java
trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/profile/ProfileMgmtBean.java
Log:
Fix [JBWS-1737]: Service-ref for Sun-RI
Modified: trunk/integration/native/src/main/resources/jbossws-native42.sar/jbossws.beans/META-INF/jboss-beans.xml
===================================================================
--- trunk/integration/native/src/main/resources/jbossws-native42.sar/jbossws.beans/META-INF/jboss-beans.xml 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/native/src/main/resources/jbossws-native42.sar/jbossws.beans/META-INF/jboss-beans.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -32,13 +32,31 @@
<bean name="WSSubscriptionManager" class="org.jboss.ws.extensions.eventing.mgmt.SubscriptionManager">
<property name="bindAddress">${jboss.bind.address}</property>
</bean>
-
- <!-- Bind Service objects in client environment context -->
- <bean name="WSServiceRefHandler" class="org.jboss.ws.core.client.ServiceRefHandlerImpl"/>
-
- <!-- Note, JBoss_4_2_0_GA uses this hardcoded bean name -->
- <bean name="ServiceRefHandler" class="org.jboss.ws.core.client.ServiceRefHandlerImpl"/>
-
+
+ <!--
+ ServiceRe Handling
+ -->
+
+ <!-- Bind Service objects in client environment context -->
+ <bean name="WSServiceRefHandler" class="org.jboss.wsf.spi.deployment.serviceref.ServiceRefHandlerImpl">
+ <property name="jaxrpcBinder"><inject bean="WSServiceRefBinderJAXRPC"/></property>
+ <property name="jaxwsBinder"><inject bean="WSServiceRefBinderJAXWS"/></property>
+ </bean>
+
+ <!-- Note, JBoss_4_2_0_GA uses this hardcoded bean name -->
+ <bean name="ServiceRefHandler" class="org.jboss.wsf.spi.deployment.serviceref.ServiceRefHandlerImpl">
+ <property name="jaxrpcBinder"><inject bean="WSServiceRefBinderJAXRPC"/></property>
+ <property name="jaxwsBinder"><inject bean="WSServiceRefBinderJAXWS"/></property>
+ </bean>
+
+ <bean name="WSServiceRefBinderJAXRPC" class="org.jboss.ws.core.jaxrpc.client.ServiceRefBinderJAXRPC"/>
+
+ <bean name="WSServiceRefBinderJAXWS" class="org.jboss.ws.core.jaxws.client.ServiceRefBinderJAXWS"/>
+
+ <!--
+ MC Utils
+ -->
+
<!-- Locate the single instance of the kernel -->
<bean name="WSKernelLocator" class="org.jboss.ws.integration.KernelLocator">
<property name="kernel"><inject bean="jboss.kernel:service=Kernel"/></property>
Modified: trunk/integration/native/src/main/resources/jbossws-native50.sar/META-INF/jbossws-beans.xml
===================================================================
--- trunk/integration/native/src/main/resources/jbossws-native50.sar/META-INF/jbossws-beans.xml 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/native/src/main/resources/jbossws-native50.sar/META-INF/jbossws-beans.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -34,8 +34,15 @@
</bean>
<!-- Bind Service objects in client environment context -->
- <bean name="WSServiceRefHandler" class="org.jboss.ws.core.client.ServiceRefHandlerImpl"/>
-
+ <bean name="WSServiceRefHandler" class="org.jboss.wsf.spi.deployment.serviceref.ServiceRefHandlerImpl">
+ <property name="jaxrpcBinder"><inject bean="WSServiceRefBinderJAXRPC"/></property>
+ <property name="jaxwsBinder"><inject bean="WSServiceRefBinderJAXWS"/></property>
+ </bean>
+
+ <bean name="WSServiceRefBinderJAXRPC" class="org.jboss.ws.core.jaxrpc.client.ServiceRefBinderJAXRPC"/>
+
+ <bean name="WSServiceRefBinderJAXWS" class="org.jboss.ws.core.jaxws.client.ServiceRefBinderJAXWS"/>
+
<!-- Locate the single instance of the kernel -->
<bean name="WSKernelLocator" class="org.jboss.ws.integration.KernelLocator">
<property name="kernel"><inject bean="jboss.kernel:service=Kernel"/></property>
Modified: trunk/integration/spi/src/main/java/org/jboss/ws/integration/ServiceRefHandler.java
===================================================================
--- trunk/integration/spi/src/main/java/org/jboss/ws/integration/ServiceRefHandler.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/spi/src/main/java/org/jboss/ws/integration/ServiceRefHandler.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -27,6 +27,7 @@
import javax.naming.NamingException;
import org.jboss.xb.binding.UnmarshallingContext;
+import org.jboss.wsf.spi.deployment.serviceref.ServiceRefBinder;
import org.xml.sax.Attributes;
/**
@@ -46,4 +47,8 @@
void setValue(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value);
void bindServiceRef(Context encCtx, String encName, UnifiedVirtualFile vfsRoot, ClassLoader loader, ServiceRefMetaData sref) throws NamingException;
+
+ void setJaxrpcBinder(ServiceRefBinder binder);
+
+ void setJaxwsBinder(ServiceRefBinder binder);
}
Modified: trunk/integration/spi/src/main/java/org/jboss/ws/integration/ServiceRefHandlerFactory.java
===================================================================
--- trunk/integration/spi/src/main/java/org/jboss/ws/integration/ServiceRefHandlerFactory.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/spi/src/main/java/org/jboss/ws/integration/ServiceRefHandlerFactory.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -57,7 +57,7 @@
KernelRegistryEntry entry = registry.getEntry(ServiceRefHandler.BEAN_NAME);
ServiceRefHandler handler = (ServiceRefHandler)entry.getTarget();
- // Try legancy JBossAS-4.2 name
+ // Try legacy JBossAS-4.2 name
if (handler == null)
{
entry = registry.getEntry("ServiceRefHandler");
@@ -69,7 +69,7 @@
private static ServiceRefHandler getClientSideServiceRefHandler()
{
String propName = ServiceRefHandler.class.getName();
- String defaultImpl = "org.jboss.ws.core.client.ServiceRefHandlerImpl";
+ String defaultImpl = "org.jboss.wsf.spi.deployment.serviceref.ServiceRefHandlerImpl";
ServiceRefHandler handler = (ServiceRefHandler)ServiceLoader.loadService(propName, defaultImpl);
return handler;
}
Copied: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/WSFException.java (from rev 3873, branches/hbraun/trunk/integration/spi/src/main/java/org/jboss/wsf/spi/WSFException.java)
===================================================================
--- trunk/integration/spi/src/main/java/org/jboss/wsf/spi/WSFException.java (rev 0)
+++ trunk/integration/spi/src/main/java/org/jboss/wsf/spi/WSFException.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,65 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.wsf.spi;
+
+/**
+ * @author Heiko.Braun(a)jboss.com
+ * Created: Jul 11, 2007
+ */
+public class WSFException extends RuntimeException
+{
+ public WSFException()
+ {
+ super();
+ }
+
+ public WSFException(String message)
+ {
+ super(message);
+ }
+
+ public WSFException(String message, Throwable cause)
+ {
+ super(message, cause);
+ }
+
+ public WSFException(Throwable cause)
+ {
+ super(cause);
+ }
+
+ public static void rethrow(String string, Throwable th)
+ {
+ if (th instanceof WSFException)
+ throw (WSFException)th;
+
+ throw new WSFException(string, th);
+ }
+
+ public static void rethrow(Throwable th)
+ {
+ if (th instanceof WSFException)
+ throw (WSFException)th;
+
+ throw new WSFException(th);
+ }
+}
Copied: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref (from rev 3873, branches/hbraun/trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref)
Deleted: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/CommonServiceRefBinder.java
===================================================================
--- branches/hbraun/trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/CommonServiceRefBinder.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/CommonServiceRefBinder.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,201 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.wsf.spi.deployment.serviceref;
-
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-import org.jboss.util.naming.Util;
-import org.jboss.logging.Logger;
-
-import javax.naming.Context;
-import javax.naming.NamingException;
-import javax.naming.Referenceable;
-import javax.xml.ws.WebServiceRef;
-import javax.xml.ws.WebServiceRefs;
-import javax.xml.ws.Service;
-import javax.jws.HandlerChain;
-import java.lang.reflect.AnnotatedElement;
-import java.lang.reflect.Field;
-import java.lang.reflect.Method;
-import java.lang.annotation.Annotation;
-import java.util.List;
-import java.util.ArrayList;
-import java.net.URL;
-import java.net.MalformedURLException;
-
-/**
- * A generic ServiceRefBinder that knows how to deal with JAX-WS services.
- * Subclasses need to provide a stack specific {@link Referenceable} that can be bound into JNDI.
- * <p/>
- * This works in conjunction with a ServiceObjectFactory that knows how to assemble
- * the Service after JNDI lookup on the client side.
- *
- * @see javax.naming.spi.ObjectFactory
- *
- * @author Heiko.Braun(a)jboss.com
- * Created: Jul 12, 2007
- */
-public abstract class CommonServiceRefBinder implements ServiceRefBinder
-{
- // logging support
- private static Logger log = Logger.getLogger(CommonServiceRefBinder.class);
-
- public void setupServiceRef(Context encCtx, String encName, AnnotatedElement anElement, UnifiedServiceRefMetaData serviceRef) throws NamingException
- {
- WebServiceRef wsref = null;
-
- // Build the list of @WebServiceRef relevant annotations
- List<WebServiceRef> wsrefList = new ArrayList<WebServiceRef>();
- if (anElement != null)
- {
- for (Annotation an : anElement.getAnnotations())
- {
- if (an instanceof WebServiceRef)
- wsrefList.add((WebServiceRef)an);
-
- if (an instanceof WebServiceRefs)
- {
- WebServiceRefs wsrefs = (WebServiceRefs)an;
- for (WebServiceRef aux : wsrefs.value())
- wsrefList.add(aux);
- }
- }
- }
-
- // Use the single @WebServiceRef
- if (wsrefList.size() == 1)
- {
- wsref = wsrefList.get(0);
- }
- else
- {
- for (WebServiceRef aux : wsrefList)
- {
- if (encName.endsWith("/" + aux.name()))
- {
- wsref = aux;
- break;
- }
- }
- }
-
- Class targetClass = null;
- if (anElement instanceof Field)
- {
- targetClass = ((Field)anElement).getType();
- }
- else if (anElement instanceof Method)
- {
- targetClass = ((Method)anElement).getParameterTypes()[0];
- }
- else
- {
- if( wsref!=null && (wsref.type() != Object.class) )
- targetClass = wsref.type();
- }
-
- String targetClassName = (targetClass != null ? targetClass.getName() : null);
- String externalName = encCtx.getNameInNamespace() + "/" + encName;
- log.debug("setupServiceRef [jndi=" + externalName + ",target=" + targetClassName + "]");
-
- String serviceImplClass = null;
-
- // #1 Use the explicit @WebServiceRef.value
- if (wsref != null && wsref.value() != Object.class)
- serviceImplClass = wsref.value().getName();
-
- // #2 Use the target ref type
- if (serviceImplClass == null && targetClass != null && Service.class.isAssignableFrom(targetClass))
- serviceImplClass = targetClass.getName();
-
- // #3 Use <service-interface>
- if (serviceImplClass == null && serviceRef.getServiceInterface() != null)
- serviceImplClass = serviceRef.getServiceInterface();
-
- // #4 Use javax.xml.ws.Service
- if (serviceImplClass == null)
- serviceImplClass = Service.class.getName();
-
- // #1 Use the explicit @WebServiceRef.type
- if (wsref != null && wsref.type() != Object.class)
- targetClassName = wsref.type().getName();
-
-
- // #2 Use the target ref type
- if (targetClassName == null && targetClass != null && Service.class.isAssignableFrom(targetClass) == false)
- targetClassName = targetClass.getName();
-
- // Set the wsdlLocation if there is no override already
- if (serviceRef.getWsdlOverride() == null && wsref != null && wsref.wsdlLocation().length() > 0)
- serviceRef.setWsdlOverride(wsref.wsdlLocation());
-
- // Set the handlerChain from @HandlerChain on the annotated element
- String handlerChain = serviceRef.getHandlerChain();
- if (anElement != null)
- {
- HandlerChain anHandlerChain = anElement.getAnnotation(HandlerChain.class);
- if (handlerChain == null && anHandlerChain != null && anHandlerChain.file().length() > 0)
- handlerChain = anHandlerChain.file();
- }
-
- // Resolve path to handler chain
- if (handlerChain != null)
- {
- try
- {
- new URL(handlerChain);
- }
- catch (MalformedURLException ex)
- {
- Class declaringClass = null;
- if (anElement instanceof Field)
- declaringClass = ((Field)anElement).getDeclaringClass();
- else if (anElement instanceof Method)
- declaringClass = ((Method)anElement).getDeclaringClass();
- else if (anElement instanceof Class)
- declaringClass = (Class)anElement;
-
- handlerChain = declaringClass.getPackage().getName().replace('.', '/') + "/" + handlerChain;
- }
-
- serviceRef.setHandlerChain(handlerChain);
- }
-
- // Do not use rebind, the binding should be unique
- // [JBWS-1499] - Revisit WebServiceRefHandler JNDI rebind
- Referenceable serviceReferenceable = buildServiceReferenceable(serviceImplClass, targetClassName, serviceRef);
- Util.bind(encCtx, encName, serviceReferenceable);
-
- }
-
- /**
- * Subclasses should provide a stack specific ServiceReferenceable.
- *
- * @param serviceImplClass
- * @param targetClassName
- * @param serviceRef
- * @return a Referenceable that can be used by a stack specific {@link javax.naming.spi.ObjectFactory} on the client side
- * to create a web service stub
- * */
- protected abstract Referenceable buildServiceReferenceable(
- String serviceImplClass, String targetClassName, UnifiedServiceRefMetaData serviceRef
- );
-}
Copied: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/CommonServiceRefBinder.java (from rev 3873, branches/hbraun/trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/CommonServiceRefBinder.java)
===================================================================
--- trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/CommonServiceRefBinder.java (rev 0)
+++ trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/CommonServiceRefBinder.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,201 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.wsf.spi.deployment.serviceref;
+
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+import org.jboss.util.naming.Util;
+import org.jboss.logging.Logger;
+
+import javax.naming.Context;
+import javax.naming.NamingException;
+import javax.naming.Referenceable;
+import javax.xml.ws.WebServiceRef;
+import javax.xml.ws.WebServiceRefs;
+import javax.xml.ws.Service;
+import javax.jws.HandlerChain;
+import java.lang.reflect.AnnotatedElement;
+import java.lang.reflect.Field;
+import java.lang.reflect.Method;
+import java.lang.annotation.Annotation;
+import java.util.List;
+import java.util.ArrayList;
+import java.net.URL;
+import java.net.MalformedURLException;
+
+/**
+ * A generic ServiceRefBinder that knows how to deal with JAX-WS services.
+ * Subclasses need to provide a stack specific {@link Referenceable} that can be bound into JNDI.
+ * <p/>
+ * This works in conjunction with a ServiceObjectFactory that knows how to assemble
+ * the Service after JNDI lookup on the client side.
+ *
+ * @see javax.naming.spi.ObjectFactory
+ *
+ * @author Heiko.Braun(a)jboss.com
+ * Created: Jul 12, 2007
+ */
+public abstract class CommonServiceRefBinder implements ServiceRefBinder
+{
+ // logging support
+ private static Logger log = Logger.getLogger(CommonServiceRefBinder.class);
+
+ public void setupServiceRef(Context encCtx, String encName, AnnotatedElement anElement, UnifiedServiceRefMetaData serviceRef) throws NamingException
+ {
+ WebServiceRef wsref = null;
+
+ // Build the list of @WebServiceRef relevant annotations
+ List<WebServiceRef> wsrefList = new ArrayList<WebServiceRef>();
+ if (anElement != null)
+ {
+ for (Annotation an : anElement.getAnnotations())
+ {
+ if (an instanceof WebServiceRef)
+ wsrefList.add((WebServiceRef)an);
+
+ if (an instanceof WebServiceRefs)
+ {
+ WebServiceRefs wsrefs = (WebServiceRefs)an;
+ for (WebServiceRef aux : wsrefs.value())
+ wsrefList.add(aux);
+ }
+ }
+ }
+
+ // Use the single @WebServiceRef
+ if (wsrefList.size() == 1)
+ {
+ wsref = wsrefList.get(0);
+ }
+ else
+ {
+ for (WebServiceRef aux : wsrefList)
+ {
+ if (encName.endsWith("/" + aux.name()))
+ {
+ wsref = aux;
+ break;
+ }
+ }
+ }
+
+ Class targetClass = null;
+ if (anElement instanceof Field)
+ {
+ targetClass = ((Field)anElement).getType();
+ }
+ else if (anElement instanceof Method)
+ {
+ targetClass = ((Method)anElement).getParameterTypes()[0];
+ }
+ else
+ {
+ if( wsref!=null && (wsref.type() != Object.class) )
+ targetClass = wsref.type();
+ }
+
+ String targetClassName = (targetClass != null ? targetClass.getName() : null);
+ String externalName = encCtx.getNameInNamespace() + "/" + encName;
+ log.debug("setupServiceRef [jndi=" + externalName + ",target=" + targetClassName + "]");
+
+ String serviceImplClass = null;
+
+ // #1 Use the explicit @WebServiceRef.value
+ if (wsref != null && wsref.value() != Object.class)
+ serviceImplClass = wsref.value().getName();
+
+ // #2 Use the target ref type
+ if (serviceImplClass == null && targetClass != null && Service.class.isAssignableFrom(targetClass))
+ serviceImplClass = targetClass.getName();
+
+ // #3 Use <service-interface>
+ if (serviceImplClass == null && serviceRef.getServiceInterface() != null)
+ serviceImplClass = serviceRef.getServiceInterface();
+
+ // #4 Use javax.xml.ws.Service
+ if (serviceImplClass == null)
+ serviceImplClass = Service.class.getName();
+
+ // #1 Use the explicit @WebServiceRef.type
+ if (wsref != null && wsref.type() != Object.class)
+ targetClassName = wsref.type().getName();
+
+
+ // #2 Use the target ref type
+ if (targetClassName == null && targetClass != null && Service.class.isAssignableFrom(targetClass) == false)
+ targetClassName = targetClass.getName();
+
+ // Set the wsdlLocation if there is no override already
+ if (serviceRef.getWsdlOverride() == null && wsref != null && wsref.wsdlLocation().length() > 0)
+ serviceRef.setWsdlOverride(wsref.wsdlLocation());
+
+ // Set the handlerChain from @HandlerChain on the annotated element
+ String handlerChain = serviceRef.getHandlerChain();
+ if (anElement != null)
+ {
+ HandlerChain anHandlerChain = anElement.getAnnotation(HandlerChain.class);
+ if (handlerChain == null && anHandlerChain != null && anHandlerChain.file().length() > 0)
+ handlerChain = anHandlerChain.file();
+ }
+
+ // Resolve path to handler chain
+ if (handlerChain != null)
+ {
+ try
+ {
+ new URL(handlerChain);
+ }
+ catch (MalformedURLException ex)
+ {
+ Class declaringClass = null;
+ if (anElement instanceof Field)
+ declaringClass = ((Field)anElement).getDeclaringClass();
+ else if (anElement instanceof Method)
+ declaringClass = ((Method)anElement).getDeclaringClass();
+ else if (anElement instanceof Class)
+ declaringClass = (Class)anElement;
+
+ handlerChain = declaringClass.getPackage().getName().replace('.', '/') + "/" + handlerChain;
+ }
+
+ serviceRef.setHandlerChain(handlerChain);
+ }
+
+ // Do not use rebind, the binding should be unique
+ // [JBWS-1499] - Revisit WebServiceRefHandler JNDI rebind
+ Referenceable serviceReferenceable = buildServiceReferenceable(serviceImplClass, targetClassName, serviceRef);
+ Util.bind(encCtx, encName, serviceReferenceable);
+
+ }
+
+ /**
+ * Subclasses should provide a stack specific ServiceReferenceable.
+ *
+ * @param serviceImplClass
+ * @param targetClassName
+ * @param serviceRef
+ * @return a Referenceable that can be used by a stack specific {@link javax.naming.spi.ObjectFactory} on the client side
+ * to create a web service stub
+ * */
+ protected abstract Referenceable buildServiceReferenceable(
+ String serviceImplClass, String targetClassName, UnifiedServiceRefMetaData serviceRef
+ );
+}
Deleted: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefBinder.java
===================================================================
--- branches/hbraun/trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefBinder.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefBinder.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,44 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.wsf.spi.deployment.serviceref;
-
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-
-import javax.naming.Context;
-import javax.naming.NamingException;
-import java.lang.reflect.AnnotatedElement;
-
-/**
- * Creates a ServiceReferenceable and binds it to JNDI.
- *
- * @author Heiko.Braun(a)jboss.com
- * Created: Jul 11, 2007
- */
-public interface ServiceRefBinder
-{
- public final static String JAXRPC_BINDER = "WSServiceRefBinderJAXRPC";
-
- public final static String JAXWS_BINDER = "WSServiceRefBinderJAXWS";
-
- void setupServiceRef(Context encCtx, String encName, AnnotatedElement anElement, UnifiedServiceRefMetaData serviceRef)
- throws NamingException;
-}
Copied: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefBinder.java (from rev 3873, branches/hbraun/trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefBinder.java)
===================================================================
--- trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefBinder.java (rev 0)
+++ trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefBinder.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,44 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.wsf.spi.deployment.serviceref;
+
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+
+import javax.naming.Context;
+import javax.naming.NamingException;
+import java.lang.reflect.AnnotatedElement;
+
+/**
+ * Creates a ServiceReferenceable and binds it to JNDI.
+ *
+ * @author Heiko.Braun(a)jboss.com
+ * Created: Jul 11, 2007
+ */
+public interface ServiceRefBinder
+{
+ public final static String JAXRPC_BINDER = "WSServiceRefBinderJAXRPC";
+
+ public final static String JAXWS_BINDER = "WSServiceRefBinderJAXWS";
+
+ void setupServiceRef(Context encCtx, String encName, AnnotatedElement anElement, UnifiedServiceRefMetaData serviceRef)
+ throws NamingException;
+}
Deleted: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefHandlerImpl.java
===================================================================
--- branches/hbraun/trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefHandlerImpl.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefHandlerImpl.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,180 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.wsf.spi.deployment.serviceref;
-
-// $Id$
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.integration.*;
-import org.jboss.wsf.spi.WSFException;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-import org.jboss.xb.binding.UnmarshallingContext;
-import org.xml.sax.Attributes;
-
-import javax.naming.Context;
-import javax.naming.NamingException;
-import java.io.File;
-import java.lang.reflect.AnnotatedElement;
-import java.net.MalformedURLException;
-import java.net.URL;
-
-/**
- * Bind service refs in the client's ENC
- * for every service-ref element in the deployment descriptor.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @author Heiko.Braun(a)jboss.com
- *
- * @since 04-Nov-2006
- */
-public class ServiceRefHandlerImpl implements ServiceRefHandler
-{
- // logging support
- private static Logger log = Logger.getLogger(ServiceRefHandlerImpl.class);
-
- private ServiceRefObjectFactory objectFactory = new ServiceRefObjectFactory();
-
- enum Type {JAXRPC, JAXWS};
-
- /* binds jaxrpc deployments */
- private ServiceRefBinder jaxrpcBinder;
-
- /*binds jaxws deployments */
- private ServiceRefBinder jaxwsBinder;
-
- public void setJaxrpcBinder(ServiceRefBinder binder)
- {
- this.jaxrpcBinder = binder;
- }
-
- public void setJaxwsBinder(ServiceRefBinder binder)
- {
- this.jaxwsBinder = binder;
- }
-
- public ServiceRefMetaData newServiceRefMetaData()
- {
- return new UnifiedServiceRefMetaData();
- }
-
- public void bindServiceRef(Context encCtx, String encName, UnifiedVirtualFile vfsRoot, ClassLoader loader, ServiceRefMetaData sref) throws NamingException
- {
- if (sref.isProcessed())
- {
- log.debug("Attempt to rebind the service-ref: " + sref.getServiceRefName());
- return;
- }
-
- // In case of an .war deployment the associated root file doesn't point to
- // the expanded war file structure and thus breaks service-ref usage for servlet clients.
- // This needs to be fixed in org.jboss.web.AbstractWebDeployer (JBOSS_AS/server module)
- if(vfsRoot instanceof URLLoaderAdapter)
- {
- URLLoaderAdapter ula = (URLLoaderAdapter)vfsRoot;
- URL rootURL = ula.toURL();
- if("file".equals( rootURL.getProtocol()) && rootURL.getFile().endsWith(".war") )
- {
- String fileName = rootURL.getFile();
-
- if( ! new File(fileName).exists() ) // might be an exploded directory
- {
- // There is a filename convention for exploded directories
- fileName = fileName.substring(0, fileName.indexOf(".war")) + "-exp.war";
-
- File expandedDirectory = new File(fileName);
- if(! expandedDirectory.exists())
- throw new WSFException("Failed to bind service-ref, the deployment root expandedDirectory doesn't exist: " + fileName);
-
- // update the rootFile
- try
- {
- vfsRoot = new URLLoaderAdapter(expandedDirectory.toURL());
- }
- catch (MalformedURLException e){}
- }
-
- }
- }
-
- UnifiedServiceRefMetaData serviceRef = (UnifiedServiceRefMetaData)sref;
- serviceRef.setVfsRoot(vfsRoot);
- try
- {
- if (getServiceRefType(serviceRef, loader) == Type.JAXRPC)
- {
- jaxrpcBinder.setupServiceRef(encCtx, encName, null, serviceRef);
- }
- else
- {
- AnnotatedElement anElement = (AnnotatedElement)sref.getAnnotatedElement();
- jaxwsBinder.setupServiceRef(encCtx, encName, anElement, serviceRef);
- }
- }
- finally
- {
- sref.setProcessed(true);
- }
- }
-
- public Object newChild(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- return objectFactory.newChild(ref, navigator, namespaceURI, localName, attrs);
- }
-
- public void setValue(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- objectFactory.setValue(ref, navigator, namespaceURI, localName, value);
- }
-
- private Type getServiceRefType(UnifiedServiceRefMetaData serviceRef, ClassLoader loader) throws NamingException
- {
- // The service-ref-type is JAXWS specific
- String serviceRefType = serviceRef.getServiceRefType();
- if (serviceRefType != null || serviceRef.getAnnotatedElement() != null)
- return Type.JAXWS;
-
- // The mapping-file is JAXRPC specific
- if (serviceRef.getMappingFile() != null)
- return Type.JAXRPC;
-
- String siName = serviceRef.getServiceInterface();
- if (siName == null)
- throw new IllegalStateException("<service-interface> cannot be null");
-
- if (siName.equals("javax.xml.rpc.Service"))
- return Type.JAXRPC;
-
- try
- {
- Class siClass = loader.loadClass(siName);
- if (javax.xml.ws.Service.class.isAssignableFrom(siClass))
- return Type.JAXWS;
- else if (javax.xml.rpc.Service.class.isAssignableFrom(siClass))
- return Type.JAXRPC;
- else throw new IllegalStateException("Illegal service interface: " + siName);
- }
- catch (ClassNotFoundException e)
- {
- throw new IllegalStateException("Cannot load <service-interface>: " + siName);
- }
- }
-}
Copied: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefHandlerImpl.java (from rev 3873, branches/hbraun/trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefHandlerImpl.java)
===================================================================
--- trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefHandlerImpl.java (rev 0)
+++ trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefHandlerImpl.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,180 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.wsf.spi.deployment.serviceref;
+
+// $Id$
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.integration.*;
+import org.jboss.wsf.spi.WSFException;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+import org.jboss.xb.binding.UnmarshallingContext;
+import org.xml.sax.Attributes;
+
+import javax.naming.Context;
+import javax.naming.NamingException;
+import java.io.File;
+import java.lang.reflect.AnnotatedElement;
+import java.net.MalformedURLException;
+import java.net.URL;
+
+/**
+ * Bind service refs in the client's ENC
+ * for every service-ref element in the deployment descriptor.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @author Heiko.Braun(a)jboss.com
+ *
+ * @since 04-Nov-2006
+ */
+public class ServiceRefHandlerImpl implements ServiceRefHandler
+{
+ // logging support
+ private static Logger log = Logger.getLogger(ServiceRefHandlerImpl.class);
+
+ private ServiceRefObjectFactory objectFactory = new ServiceRefObjectFactory();
+
+ enum Type {JAXRPC, JAXWS};
+
+ /* binds jaxrpc deployments */
+ private ServiceRefBinder jaxrpcBinder;
+
+ /*binds jaxws deployments */
+ private ServiceRefBinder jaxwsBinder;
+
+ public void setJaxrpcBinder(ServiceRefBinder binder)
+ {
+ this.jaxrpcBinder = binder;
+ }
+
+ public void setJaxwsBinder(ServiceRefBinder binder)
+ {
+ this.jaxwsBinder = binder;
+ }
+
+ public ServiceRefMetaData newServiceRefMetaData()
+ {
+ return new UnifiedServiceRefMetaData();
+ }
+
+ public void bindServiceRef(Context encCtx, String encName, UnifiedVirtualFile vfsRoot, ClassLoader loader, ServiceRefMetaData sref) throws NamingException
+ {
+ if (sref.isProcessed())
+ {
+ log.debug("Attempt to rebind the service-ref: " + sref.getServiceRefName());
+ return;
+ }
+
+ // In case of an .war deployment the associated root file doesn't point to
+ // the expanded war file structure and thus breaks service-ref usage for servlet clients.
+ // This needs to be fixed in org.jboss.web.AbstractWebDeployer (JBOSS_AS/server module)
+ if(vfsRoot instanceof URLLoaderAdapter)
+ {
+ URLLoaderAdapter ula = (URLLoaderAdapter)vfsRoot;
+ URL rootURL = ula.toURL();
+ if("file".equals( rootURL.getProtocol()) && rootURL.getFile().endsWith(".war") )
+ {
+ String fileName = rootURL.getFile();
+
+ if( ! new File(fileName).exists() ) // might be an exploded directory
+ {
+ // There is a filename convention for exploded directories
+ fileName = fileName.substring(0, fileName.indexOf(".war")) + "-exp.war";
+
+ File expandedDirectory = new File(fileName);
+ if(! expandedDirectory.exists())
+ throw new WSFException("Failed to bind service-ref, the deployment root expandedDirectory doesn't exist: " + fileName);
+
+ // update the rootFile
+ try
+ {
+ vfsRoot = new URLLoaderAdapter(expandedDirectory.toURL());
+ }
+ catch (MalformedURLException e){}
+ }
+
+ }
+ }
+
+ UnifiedServiceRefMetaData serviceRef = (UnifiedServiceRefMetaData)sref;
+ serviceRef.setVfsRoot(vfsRoot);
+ try
+ {
+ if (getServiceRefType(serviceRef, loader) == Type.JAXRPC)
+ {
+ jaxrpcBinder.setupServiceRef(encCtx, encName, null, serviceRef);
+ }
+ else
+ {
+ AnnotatedElement anElement = (AnnotatedElement)sref.getAnnotatedElement();
+ jaxwsBinder.setupServiceRef(encCtx, encName, anElement, serviceRef);
+ }
+ }
+ finally
+ {
+ sref.setProcessed(true);
+ }
+ }
+
+ public Object newChild(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ return objectFactory.newChild(ref, navigator, namespaceURI, localName, attrs);
+ }
+
+ public void setValue(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+ {
+ objectFactory.setValue(ref, navigator, namespaceURI, localName, value);
+ }
+
+ private Type getServiceRefType(UnifiedServiceRefMetaData serviceRef, ClassLoader loader) throws NamingException
+ {
+ // The service-ref-type is JAXWS specific
+ String serviceRefType = serviceRef.getServiceRefType();
+ if (serviceRefType != null || serviceRef.getAnnotatedElement() != null)
+ return Type.JAXWS;
+
+ // The mapping-file is JAXRPC specific
+ if (serviceRef.getMappingFile() != null)
+ return Type.JAXRPC;
+
+ String siName = serviceRef.getServiceInterface();
+ if (siName == null)
+ throw new IllegalStateException("<service-interface> cannot be null");
+
+ if (siName.equals("javax.xml.rpc.Service"))
+ return Type.JAXRPC;
+
+ try
+ {
+ Class siClass = loader.loadClass(siName);
+ if (javax.xml.ws.Service.class.isAssignableFrom(siClass))
+ return Type.JAXWS;
+ else if (javax.xml.rpc.Service.class.isAssignableFrom(siClass))
+ return Type.JAXRPC;
+ else throw new IllegalStateException("Illegal service interface: " + siName);
+ }
+ catch (ClassNotFoundException e)
+ {
+ throw new IllegalStateException("Cannot load <service-interface>: " + siName);
+ }
+ }
+}
Deleted: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefObjectFactory.java
===================================================================
--- branches/hbraun/trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefObjectFactory.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefObjectFactory.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,305 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.wsf.spi.deployment.serviceref;
-
-// $Id$
-
-import javax.xml.namespace.QName;
-
-import org.jboss.ws.integration.ServiceRefElement;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedCallPropertyMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerChainMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerChainsMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedInitParamMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedPortComponentRefMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedStubPropertyMetaData;
-import org.jboss.xb.binding.UnmarshallingContext;
-import org.xml.sax.Attributes;
-
-/**
- * A object model factory for <service-ref>
- *
- * @author Thomas.Diesler(a)jboss.com
- */
-public class ServiceRefObjectFactory
-{
- public Object newChild(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (ref instanceof UnifiedHandlerChainsMetaData)
- child = newChild((UnifiedHandlerChainsMetaData)ref, navigator, namespaceURI, localName, attrs);
- else if (ref instanceof UnifiedHandlerMetaData)
- child = newChild((UnifiedHandlerMetaData)ref, navigator, namespaceURI, localName, attrs);
- else if (ref instanceof UnifiedPortComponentRefMetaData)
- child = newChild((UnifiedPortComponentRefMetaData)ref, navigator, namespaceURI, localName, attrs);
- else if (ref instanceof UnifiedServiceRefMetaData)
- child = newChild((UnifiedServiceRefMetaData)ref, navigator, namespaceURI, localName, attrs);
- return child;
- }
-
- public void setValue(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (ref instanceof UnifiedCallPropertyMetaData)
- setValue((UnifiedCallPropertyMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedHandlerChainMetaData)
- setValue((UnifiedHandlerChainMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedHandlerMetaData)
- setValue((UnifiedHandlerMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedInitParamMetaData)
- setValue((UnifiedInitParamMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedPortComponentRefMetaData)
- setValue((UnifiedPortComponentRefMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedServiceRefMetaData)
- setValue((UnifiedServiceRefMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedCallPropertyMetaData)
- setValue((UnifiedCallPropertyMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedStubPropertyMetaData)
- setValue((UnifiedStubPropertyMetaData)ref, navigator, namespaceURI, localName, value);
- }
-
- private void setValue(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- /* Standard properties */
- if (localName.equals("service-ref-name"))
- {
- ref.setServiceRefName(value);
- }
- else if (localName.equals("service-interface"))
- {
- ref.setServiceInterface(value);
- }
- else if (localName.equals("service-ref-type"))
- {
- ref.setServiceRefType(value);
- }
- else if (localName.equals("wsdl-file"))
- {
- ref.setWsdlFile(value);
- }
- else if (localName.equals("jaxrpc-mapping-file"))
- {
- ref.setMappingFile(value);
- }
- else if (localName.equals("service-qname"))
- {
- ref.setServiceQName(getQNameValue(navigator, value));
- }
-
- /* JBoss properties */
- else if (localName.equals("service-impl-class"))
- {
- ref.setServiceImplClass(value);
- }
- else if (localName.equals("config-name"))
- {
- ref.setConfigName(value);
- }
- else if (localName.equals("config-file"))
- {
- ref.setConfigFile(value);
- }
- else if (localName.equals("wsdl-override"))
- {
- ref.setWsdlOverride(value);
- }
- else if (localName.equals("handler-chain"))
- {
- ref.setHandlerChain(value);
- }
- }
-
- private Object newChild(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("port-component-ref"))
- {
- child = new UnifiedPortComponentRefMetaData(ref);
- ref.addPortComponentRef((UnifiedPortComponentRefMetaData)child);
- }
- else if (localName.equals("handler"))
- {
- child = new UnifiedHandlerMetaData();
- ref.addHandler((UnifiedHandlerMetaData)child);
- }
- else if (localName.equals("handler-chains"))
- {
- child = new UnifiedHandlerChainsMetaData();
- ref.setHandlerChains((UnifiedHandlerChainsMetaData)child);
- }
- else if (localName.equals("call-property"))
- {
- child = new UnifiedCallPropertyMetaData();
- ref.addCallProperty((UnifiedCallPropertyMetaData)child);
- }
- return child;
- }
-
- private Object newChild(UnifiedHandlerChainsMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("handler-chain"))
- {
- child = new UnifiedHandlerChainMetaData();
- ref.addHandlerChain((UnifiedHandlerChainMetaData)child);
- }
- return child;
- }
-
- private void setValue(UnifiedPortComponentRefMetaData pcref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("service-endpoint-interface"))
- {
- pcref.setServiceEndpointInterface(value);
- }
- else if (localName.equals("enable-mtom"))
- {
- pcref.setEnableMTOM(Boolean.valueOf(value));
- }
- else if (localName.equals("port-component-link"))
- {
- pcref.setPortComponentLink(value);
- }
- else if (localName.equals("port-qname"))
- {
- pcref.setPortQName(getQNameValue(navigator, value));
- }
- else if (localName.equals("config-name"))
- {
- pcref.setConfigName(value);
- }
- else if (localName.equals("config-file"))
- {
- pcref.setConfigFile(value);
- }
- }
-
- private Object newChild(UnifiedPortComponentRefMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("call-property"))
- {
- child = new UnifiedCallPropertyMetaData();
- ref.addCallProperty((UnifiedCallPropertyMetaData)child);
- }
- if (localName.equals("stub-property"))
- {
- child = new UnifiedStubPropertyMetaData();
- ref.addStubProperty((UnifiedStubPropertyMetaData)child);
- }
- return child;
- }
-
- private void setValue(UnifiedHandlerChainMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("service-name-pattern"))
- {
- ref.setServiceNamePattern(getQNameValue(navigator, value));
- }
- else if (localName.equals("port-name-pattern"))
- {
- ref.setPortNamePattern(getQNameValue(navigator, value));
- }
- else if (localName.equals("protocol-binding"))
- {
- ref.setProtocolBindings(value);
- }
- }
-
- private void setValue(UnifiedHandlerMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("handler-name"))
- {
- ref.setHandlerName(value);
- }
- else if (localName.equals("handler-class"))
- {
- ref.setHandlerClass(value);
- }
- else if (localName.equals("soap-header"))
- {
- ref.addSoapHeader(getQNameValue(navigator, value));
- }
- else if (localName.equals("soap-role"))
- {
- ref.addSoapRole(value);
- }
- else if (localName.equals("port-name"))
- {
- ref.addPortName(value);
- }
- }
-
- private Object newChild(UnifiedHandlerMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("init-param"))
- {
- child = new UnifiedInitParamMetaData();
- ref.addInitParam((UnifiedInitParamMetaData)child);
- }
- return child;
- }
-
- private void setValue(UnifiedInitParamMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("param-name"))
- {
- ref.setParamName(value);
- }
- else if (localName.equals("param-value"))
- {
- ref.setParamValue(value);
- }
- }
-
- private void setValue(UnifiedCallPropertyMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("prop-name"))
- {
- ref.setPropName(value);
- }
- else if (localName.equals("prop-value"))
- {
- ref.setPropValue(value);
- }
- }
-
- private void setValue(UnifiedStubPropertyMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("prop-name"))
- {
- ref.setPropName(value);
- }
- else if (localName.equals("prop-value"))
- {
- ref.setPropValue(value);
- }
- }
-
- private QName getQNameValue(UnmarshallingContext navigator, String value)
- {
- QName qname = (value.startsWith("{") ? QName.valueOf(value) : navigator.resolveQName(value));
- return qname;
- }
-}
Copied: trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefObjectFactory.java (from rev 3873, branches/hbraun/trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefObjectFactory.java)
===================================================================
--- trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefObjectFactory.java (rev 0)
+++ trunk/integration/spi/src/main/java/org/jboss/wsf/spi/deployment/serviceref/ServiceRefObjectFactory.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,305 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.wsf.spi.deployment.serviceref;
+
+// $Id$
+
+import javax.xml.namespace.QName;
+
+import org.jboss.ws.integration.ServiceRefElement;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedCallPropertyMetaData;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerChainMetaData;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerChainsMetaData;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedInitParamMetaData;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedPortComponentRefMetaData;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedStubPropertyMetaData;
+import org.jboss.xb.binding.UnmarshallingContext;
+import org.xml.sax.Attributes;
+
+/**
+ * A object model factory for <service-ref>
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ */
+public class ServiceRefObjectFactory
+{
+ public Object newChild(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ Object child = null;
+ if (ref instanceof UnifiedHandlerChainsMetaData)
+ child = newChild((UnifiedHandlerChainsMetaData)ref, navigator, namespaceURI, localName, attrs);
+ else if (ref instanceof UnifiedHandlerMetaData)
+ child = newChild((UnifiedHandlerMetaData)ref, navigator, namespaceURI, localName, attrs);
+ else if (ref instanceof UnifiedPortComponentRefMetaData)
+ child = newChild((UnifiedPortComponentRefMetaData)ref, navigator, namespaceURI, localName, attrs);
+ else if (ref instanceof UnifiedServiceRefMetaData)
+ child = newChild((UnifiedServiceRefMetaData)ref, navigator, namespaceURI, localName, attrs);
+ return child;
+ }
+
+ public void setValue(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+ {
+ if (ref instanceof UnifiedCallPropertyMetaData)
+ setValue((UnifiedCallPropertyMetaData)ref, navigator, namespaceURI, localName, value);
+ else if (ref instanceof UnifiedHandlerChainMetaData)
+ setValue((UnifiedHandlerChainMetaData)ref, navigator, namespaceURI, localName, value);
+ else if (ref instanceof UnifiedHandlerMetaData)
+ setValue((UnifiedHandlerMetaData)ref, navigator, namespaceURI, localName, value);
+ else if (ref instanceof UnifiedInitParamMetaData)
+ setValue((UnifiedInitParamMetaData)ref, navigator, namespaceURI, localName, value);
+ else if (ref instanceof UnifiedPortComponentRefMetaData)
+ setValue((UnifiedPortComponentRefMetaData)ref, navigator, namespaceURI, localName, value);
+ else if (ref instanceof UnifiedServiceRefMetaData)
+ setValue((UnifiedServiceRefMetaData)ref, navigator, namespaceURI, localName, value);
+ else if (ref instanceof UnifiedCallPropertyMetaData)
+ setValue((UnifiedCallPropertyMetaData)ref, navigator, namespaceURI, localName, value);
+ else if (ref instanceof UnifiedStubPropertyMetaData)
+ setValue((UnifiedStubPropertyMetaData)ref, navigator, namespaceURI, localName, value);
+ }
+
+ private void setValue(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+ {
+ /* Standard properties */
+ if (localName.equals("service-ref-name"))
+ {
+ ref.setServiceRefName(value);
+ }
+ else if (localName.equals("service-interface"))
+ {
+ ref.setServiceInterface(value);
+ }
+ else if (localName.equals("service-ref-type"))
+ {
+ ref.setServiceRefType(value);
+ }
+ else if (localName.equals("wsdl-file"))
+ {
+ ref.setWsdlFile(value);
+ }
+ else if (localName.equals("jaxrpc-mapping-file"))
+ {
+ ref.setMappingFile(value);
+ }
+ else if (localName.equals("service-qname"))
+ {
+ ref.setServiceQName(getQNameValue(navigator, value));
+ }
+
+ /* JBoss properties */
+ else if (localName.equals("service-impl-class"))
+ {
+ ref.setServiceImplClass(value);
+ }
+ else if (localName.equals("config-name"))
+ {
+ ref.setConfigName(value);
+ }
+ else if (localName.equals("config-file"))
+ {
+ ref.setConfigFile(value);
+ }
+ else if (localName.equals("wsdl-override"))
+ {
+ ref.setWsdlOverride(value);
+ }
+ else if (localName.equals("handler-chain"))
+ {
+ ref.setHandlerChain(value);
+ }
+ }
+
+ private Object newChild(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ Object child = null;
+ if (localName.equals("port-component-ref"))
+ {
+ child = new UnifiedPortComponentRefMetaData(ref);
+ ref.addPortComponentRef((UnifiedPortComponentRefMetaData)child);
+ }
+ else if (localName.equals("handler"))
+ {
+ child = new UnifiedHandlerMetaData();
+ ref.addHandler((UnifiedHandlerMetaData)child);
+ }
+ else if (localName.equals("handler-chains"))
+ {
+ child = new UnifiedHandlerChainsMetaData();
+ ref.setHandlerChains((UnifiedHandlerChainsMetaData)child);
+ }
+ else if (localName.equals("call-property"))
+ {
+ child = new UnifiedCallPropertyMetaData();
+ ref.addCallProperty((UnifiedCallPropertyMetaData)child);
+ }
+ return child;
+ }
+
+ private Object newChild(UnifiedHandlerChainsMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ Object child = null;
+ if (localName.equals("handler-chain"))
+ {
+ child = new UnifiedHandlerChainMetaData();
+ ref.addHandlerChain((UnifiedHandlerChainMetaData)child);
+ }
+ return child;
+ }
+
+ private void setValue(UnifiedPortComponentRefMetaData pcref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("service-endpoint-interface"))
+ {
+ pcref.setServiceEndpointInterface(value);
+ }
+ else if (localName.equals("enable-mtom"))
+ {
+ pcref.setEnableMTOM(Boolean.valueOf(value));
+ }
+ else if (localName.equals("port-component-link"))
+ {
+ pcref.setPortComponentLink(value);
+ }
+ else if (localName.equals("port-qname"))
+ {
+ pcref.setPortQName(getQNameValue(navigator, value));
+ }
+ else if (localName.equals("config-name"))
+ {
+ pcref.setConfigName(value);
+ }
+ else if (localName.equals("config-file"))
+ {
+ pcref.setConfigFile(value);
+ }
+ }
+
+ private Object newChild(UnifiedPortComponentRefMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ Object child = null;
+ if (localName.equals("call-property"))
+ {
+ child = new UnifiedCallPropertyMetaData();
+ ref.addCallProperty((UnifiedCallPropertyMetaData)child);
+ }
+ if (localName.equals("stub-property"))
+ {
+ child = new UnifiedStubPropertyMetaData();
+ ref.addStubProperty((UnifiedStubPropertyMetaData)child);
+ }
+ return child;
+ }
+
+ private void setValue(UnifiedHandlerChainMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("service-name-pattern"))
+ {
+ ref.setServiceNamePattern(getQNameValue(navigator, value));
+ }
+ else if (localName.equals("port-name-pattern"))
+ {
+ ref.setPortNamePattern(getQNameValue(navigator, value));
+ }
+ else if (localName.equals("protocol-binding"))
+ {
+ ref.setProtocolBindings(value);
+ }
+ }
+
+ private void setValue(UnifiedHandlerMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("handler-name"))
+ {
+ ref.setHandlerName(value);
+ }
+ else if (localName.equals("handler-class"))
+ {
+ ref.setHandlerClass(value);
+ }
+ else if (localName.equals("soap-header"))
+ {
+ ref.addSoapHeader(getQNameValue(navigator, value));
+ }
+ else if (localName.equals("soap-role"))
+ {
+ ref.addSoapRole(value);
+ }
+ else if (localName.equals("port-name"))
+ {
+ ref.addPortName(value);
+ }
+ }
+
+ private Object newChild(UnifiedHandlerMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
+ {
+ Object child = null;
+ if (localName.equals("init-param"))
+ {
+ child = new UnifiedInitParamMetaData();
+ ref.addInitParam((UnifiedInitParamMetaData)child);
+ }
+ return child;
+ }
+
+ private void setValue(UnifiedInitParamMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("param-name"))
+ {
+ ref.setParamName(value);
+ }
+ else if (localName.equals("param-value"))
+ {
+ ref.setParamValue(value);
+ }
+ }
+
+ private void setValue(UnifiedCallPropertyMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("prop-name"))
+ {
+ ref.setPropName(value);
+ }
+ else if (localName.equals("prop-value"))
+ {
+ ref.setPropValue(value);
+ }
+ }
+
+ private void setValue(UnifiedStubPropertyMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
+ {
+ if (localName.equals("prop-name"))
+ {
+ ref.setPropName(value);
+ }
+ else if (localName.equals("prop-value"))
+ {
+ ref.setPropValue(value);
+ }
+ }
+
+ private QName getQNameValue(UnmarshallingContext navigator, String value)
+ {
+ QName qname = (value.startsWith("{") ? QName.valueOf(value) : navigator.resolveQName(value));
+ return qname;
+ }
+}
Modified: trunk/integration/sunri/ant-import/build-testsuite.xml
===================================================================
--- trunk/integration/sunri/ant-import/build-testsuite.xml 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/sunri/ant-import/build-testsuite.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -46,6 +46,7 @@
</path>
<path id="tests.extra.classpath">
+ <pathelement location="${int.sunri.dir}/output/lib/jbossws-sunri-client.jar"/>
<pathelement location="${spi.dir}/output/lib/jbossws-spi.jar"/>
</path>
Modified: trunk/integration/sunri/build.xml
===================================================================
--- trunk/integration/sunri/build.xml 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/sunri/build.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -112,20 +112,23 @@
<target name="jars-common" depends="compile">
<!-- Build jbossws-sunri.jar -->
- <mkdir dir="${sunri.output.lib.dir}"/>
+ <mkdir dir="${sunri.output.lib.dir}"/>
<jar jarfile="${sunri.output.lib.dir}/jbossws-sunri.jar" manifest="${sunri.output.etc.dir}/default.mf">
<fileset dir="${sunri.output.classes.dir}">
- <exclude name="org/jboss/wsf/stack/sunri/sunri/tools/**"/>
- <include name="org/jboss/wsf/stack/sunri50/**"/>
- <include name="org/jboss/wsf/stack/sunri/metadata/**"/>
- <include name="org/jboss/wsf/stack/sunri/log/**"/>
- <include name="org/jboss/wsf/stack/sunri/*"/>
+ <exclude name="org/jboss/wsf/stack/sunri/sunri/tools/**"/>
+ <include name="org/jboss/wsf/stack/sunri50/**"/>
+ <include name="org/jboss/wsf/stack/sunri/injection/**"/>
+ <include name="org/jboss/wsf/stack/sunri/client/**"/>
+ <include name="org/jboss/wsf/stack/sunri/metadata/**"/>
+ <include name="org/jboss/wsf/stack/sunri/log/**"/>
+ <include name="org/jboss/wsf/stack/sunri/*"/>
</fileset>
</jar>
<!-- jbossws-sunri-client.jar -->
<jar jarfile="${sunri.output.lib.dir}/jbossws-sunri-client.jar" manifest="${sunri.output.etc.dir}/default.mf">
<fileset dir="${sunri.output.classes.dir}">
+ <include name="org/jboss/wsf/stack/sunri/client/**"/>
<include name="org/jboss/wsf/stack/sunri/tools/**"/>
</fileset>
<metainf dir="${sunri.resources.dir}/jbossws-sunri-client.jar/META-INF"/>
Modified: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/DeploymentDescriptorParserExt.java
===================================================================
--- trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/DeploymentDescriptorParserExt.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/DeploymentDescriptorParserExt.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -80,6 +80,8 @@
* {@link createInvoker(Class)}
*
*
+ * @see com.sun.xml.ws.transport.http.servlet.WSServletContextListener
+ *
* @author WS Development Team
* @author Kohsuke Kawaguchi
* @author Thomas.Diesler(a)jboss.org
Modified: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/WSServletContextListenerExt.java
===================================================================
--- trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/WSServletContextListenerExt.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/WSServletContextListenerExt.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -23,24 +23,11 @@
// $Id$
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.logging.Level;
-import java.util.logging.Logger;
-
-import javax.servlet.ServletContext;
-import javax.servlet.ServletContextAttributeEvent;
-import javax.servlet.ServletContextAttributeListener;
-import javax.servlet.ServletContextEvent;
-import javax.servlet.ServletContextListener;
-import javax.xml.ws.WebServiceException;
-
import com.sun.istack.NotNull;
import com.sun.xml.ws.api.server.BoundEndpoint;
import com.sun.xml.ws.api.server.Container;
import com.sun.xml.ws.api.server.Module;
+import com.sun.xml.ws.api.server.ResourceInjector;
import com.sun.xml.ws.resources.WsservletMessages;
import com.sun.xml.ws.transport.http.DeploymentDescriptorParser.AdapterFactory;
import com.sun.xml.ws.transport.http.servlet.ServletAdapter;
@@ -48,6 +35,15 @@
import com.sun.xml.ws.transport.http.servlet.WSServlet;
import com.sun.xml.ws.transport.http.servlet.WSServletDelegate;
+import javax.servlet.*;
+import javax.xml.ws.WebServiceException;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
/**
* A copy of WSServletContextListener that externalizes
*
@@ -173,10 +169,16 @@
{
return (T)servletContext;
}
- if (spiType == Module.class)
+ else if (spiType == Module.class)
{
return spiType.cast(module);
}
+ else if(spiType == ResourceInjector.class)
+ {
+ return (T)ResourceInjector.STANDALONE;
+ }
+
+ logger.log(Level.WARNING, "Unable to resolve SPI for type: " + spiType);
return null;
}
}
Copied: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client (from rev 3873, branches/hbraun/trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client)
Deleted: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/DummyServiceRefBinderJAXRPC.java
===================================================================
--- branches/hbraun/trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/DummyServiceRefBinderJAXRPC.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/DummyServiceRefBinderJAXRPC.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,41 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.wsf.stack.sunri.client;
-
-import org.jboss.wsf.spi.deployment.serviceref.ServiceRefBinder;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-
-import javax.naming.Context;
-import javax.naming.NamingException;
-import java.lang.reflect.AnnotatedElement;
-
-/**
- * @author Heiko.Braun(a)jboss.com
- * Created: Jul 12, 2007
- */
-public class DummyServiceRefBinderJAXRPC implements ServiceRefBinder
-{
- public void setupServiceRef(Context encCtx, String encName, AnnotatedElement anElement, UnifiedServiceRefMetaData serviceRef) throws NamingException
- {
- throw new IllegalArgumentException("The Sun-RI stack doesnt support JAX-RPC service-ref deployments");
- }
-}
Copied: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/DummyServiceRefBinderJAXRPC.java (from rev 3873, branches/hbraun/trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/DummyServiceRefBinderJAXRPC.java)
===================================================================
--- trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/DummyServiceRefBinderJAXRPC.java (rev 0)
+++ trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/DummyServiceRefBinderJAXRPC.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,41 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.wsf.stack.sunri.client;
+
+import org.jboss.wsf.spi.deployment.serviceref.ServiceRefBinder;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+
+import javax.naming.Context;
+import javax.naming.NamingException;
+import java.lang.reflect.AnnotatedElement;
+
+/**
+ * @author Heiko.Braun(a)jboss.com
+ * Created: Jul 12, 2007
+ */
+public class DummyServiceRefBinderJAXRPC implements ServiceRefBinder
+{
+ public void setupServiceRef(Context encCtx, String encName, AnnotatedElement anElement, UnifiedServiceRefMetaData serviceRef) throws NamingException
+ {
+ throw new IllegalArgumentException("The Sun-RI stack doesnt support JAX-RPC service-ref deployments");
+ }
+}
Deleted: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/ServiceRefBinderJAXWS.java
===================================================================
--- branches/hbraun/trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/ServiceRefBinderJAXWS.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/ServiceRefBinderJAXWS.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,49 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.wsf.stack.sunri.client;
-
-import org.jboss.wsf.spi.deployment.serviceref.CommonServiceRefBinder;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-
-import javax.naming.Referenceable;
-
-/**
- * @author Heiko.Braun(a)jboss.com
- * Created: Jul 12, 2007
- */
-public class ServiceRefBinderJAXWS extends CommonServiceRefBinder
-{
- /**
- * Create a Sun-RI specific service referenceable.
- * Most of the setup is done in {@link CommonServiceRefBinder}
- *
- * @param serviceImplClass
- * @param targetClassName
- * @param serviceRef
- * @return a Sun-RI specific service referenceable.
- */
- protected Referenceable buildServiceReferenceable(
- String serviceImplClass, String targetClassName, UnifiedServiceRefMetaData serviceRef)
- {
- return new SunRIServiceReferenceable(serviceImplClass, targetClassName, serviceRef);
- }
-}
Copied: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/ServiceRefBinderJAXWS.java (from rev 3873, branches/hbraun/trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/ServiceRefBinderJAXWS.java)
===================================================================
--- trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/ServiceRefBinderJAXWS.java (rev 0)
+++ trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/ServiceRefBinderJAXWS.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,49 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.wsf.stack.sunri.client;
+
+import org.jboss.wsf.spi.deployment.serviceref.CommonServiceRefBinder;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+
+import javax.naming.Referenceable;
+
+/**
+ * @author Heiko.Braun(a)jboss.com
+ * Created: Jul 12, 2007
+ */
+public class ServiceRefBinderJAXWS extends CommonServiceRefBinder
+{
+ /**
+ * Create a Sun-RI specific service referenceable.
+ * Most of the setup is done in {@link CommonServiceRefBinder}
+ *
+ * @param serviceImplClass
+ * @param targetClassName
+ * @param serviceRef
+ * @return a Sun-RI specific service referenceable.
+ */
+ protected Referenceable buildServiceReferenceable(
+ String serviceImplClass, String targetClassName, UnifiedServiceRefMetaData serviceRef)
+ {
+ return new SunRIServiceReferenceable(serviceImplClass, targetClassName, serviceRef);
+ }
+}
Deleted: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceObjectFactory.java
===================================================================
--- branches/hbraun/trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceObjectFactory.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceObjectFactory.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,213 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.wsf.stack.sunri.client;
-
-import org.jboss.wsf.spi.WSFException;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-
-import javax.naming.*;
-import javax.naming.spi.ObjectFactory;
-import javax.xml.namespace.QName;
-import javax.xml.ws.Service;
-import java.io.ByteArrayInputStream;
-import java.io.IOException;
-import java.io.ObjectInputStream;
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.net.URL;
-import java.util.Hashtable;
-import org.jboss.logging.Logger;
-
-/**
- * This ServiceObjectFactory reconstructs a javax.xml.ws.Service
- * for a given WSDL when the webservice client does a JNDI lookup
- *
- * @see SunRIServiceReferenceable
- *
- * @author Heiko.Braun(a)jboss.com
- * Created: Jul 12, 2007
- * */
-public class SunRIServiceObjectFactory implements ObjectFactory
-{
- protected final Logger log = Logger.getLogger(SunRIServiceObjectFactory.class);
-
- /**
- * Creates an object using the location or reference information specified.
- * <p/>
- *
- * @param obj The possibly null object containing location or reference
- * information that can be used in creating an object.
- * @param name The name of this object relative to <code>nameCtx</code>,
- * or null if no name is specified.
- * @param nameCtx The context relative to which the <code>name</code>
- * parameter is specified, or null if <code>name</code> is
- * relative to the default initial context.
- * @param environment The possibly null environment that is used in
- * creating the object.
- * @return The object created; null if an object cannot be created.
- * @throws Exception if this object factory encountered an exception
- * while attempting to create an object, and no other object factories are
- * to be tried.
- * @see javax.naming.spi.NamingManager#getObjectInstance
- * @see javax.naming.spi.NamingManager#getURLContext
- */
- public Object getObjectInstance(Object obj, Name name, Context nameCtx, Hashtable environment) throws Exception
- {
- try
- {
- Reference ref = (Reference)obj;
-
- // Get the target class name
- String targetClassName = (String)ref.get(SunRIServiceReferenceable.TARGET_CLASS_NAME).getContent();
-
- // Unmarshall the UnifiedServiceRef
- UnifiedServiceRefMetaData serviceRef = unmarshallServiceRef(ref);
- String serviceRefName = serviceRef.getServiceRefName();
- QName serviceQName = serviceRef.getServiceQName();
-
- String serviceImplClass = serviceRef.getServiceImplClass();
- if (serviceImplClass == null)
- serviceImplClass = (String)ref.get(SunRIServiceReferenceable.SERVICE_IMPL_CLASS).getContent();
-
- // If the target defaults to javax.xml.ws.Service, use the service as the target
- if (Service.class.getName().equals(targetClassName))
- targetClassName = serviceImplClass;
-
- log.debug("getObjectInstance [name=" + serviceRefName + ",service=" + serviceImplClass + ",target=" + targetClassName + "]");
-
- // Load the service class
- ClassLoader ctxLoader = Thread.currentThread().getContextClassLoader();
- Class serviceClass = ctxLoader.loadClass(serviceImplClass);
- Class targetClass = (targetClassName != null ? ctxLoader.loadClass(targetClassName) : null);
-
- if (Service.class.isAssignableFrom(serviceClass) == false)
- throw new IllegalArgumentException("WebServiceRef type '" + serviceClass + "' is not assignable to javax.xml.ws.Service");
-
- // Receives either a javax.xml.ws.Service or a dynamic proxy
- Object target;
-
- // Get the URL to the wsdl
- URL wsdlURL = serviceRef.getWsdlLocation();
-
- // Generic javax.xml.ws.Service
- if (serviceClass == Service.class)
- {
- if (wsdlURL != null)
- {
- target = Service.create(wsdlURL, serviceQName);
- }
- else
- {
- throw new IllegalArgumentException("Cannot create generic javax.xml.ws.Service without wsdlLocation: " + serviceRefName);
- }
- }
- // Generated javax.xml.ws.Service subclass
- else
- {
- if (wsdlURL != null)
- {
- Constructor ctor = serviceClass.getConstructor(new Class[] { URL.class, QName.class });
- target = ctor.newInstance(new Object[] { wsdlURL, serviceQName });
- }
- else
- {
- target = (Service)serviceClass.newInstance();
- }
- }
-
- // Configure the service
- configureService((Service)target, serviceRef);
-
- if (targetClassName != null && targetClassName.equals(serviceImplClass) == false)
- {
- try
- {
- Object port = null;
- if (serviceClass != Service.class)
- {
- for (Method method : serviceClass.getDeclaredMethods())
- {
- String methodName = method.getName();
- Class retType = method.getReturnType();
- if (methodName.startsWith("get") && targetClass.isAssignableFrom(retType))
- {
- port = method.invoke(target, new Object[0]);
- target = port;
- break;
- }
- }
- }
-
- if (port == null)
- {
- Method method = serviceClass.getMethod("getPort", new Class[] { Class.class });
- port = method.invoke(target, new Object[] { targetClass });
- target = port;
- }
- }
- catch (InvocationTargetException ex)
- {
- throw ex.getTargetException();
- }
- }
-
- return target;
- }
- catch (Throwable ex)
- {
- WSFException.rethrow("Cannot create service", ex);
- return null;
- }
- }
-
-
- private void configureService(Service service, UnifiedServiceRefMetaData serviceRef)
- {
- log.warn("Service configuration not available in Sun-RI");
- }
-
- private UnifiedServiceRefMetaData unmarshallServiceRef(Reference ref) throws ClassNotFoundException, NamingException
- {
- UnifiedServiceRefMetaData sref;
- RefAddr refAddr = ref.get(SunRIServiceReferenceable.SERVICE_REF_META_DATA);
- ByteArrayInputStream bais = new ByteArrayInputStream((byte[])refAddr.getContent());
- try
- {
- ObjectInputStream ois = new ObjectInputStream(bais);
- sref = (UnifiedServiceRefMetaData)ois.readObject();
- ois.close();
- }
- catch (IOException e)
- {
- throw new NamingException("Cannot unmarshall service ref meta data, cause: " + e.toString());
- }
-
- // Verify it. There is some know coinstraints
- if(null == sref.getServiceQName())
- throw new IllegalArgumentException("ServiceQName may not be null. " +
- "Specify a service QName in the service-ref declaration.");
-
- return sref;
- }
-}
-
Copied: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceObjectFactory.java (from rev 3873, branches/hbraun/trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceObjectFactory.java)
===================================================================
--- trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceObjectFactory.java (rev 0)
+++ trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceObjectFactory.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,213 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.wsf.stack.sunri.client;
+
+import org.jboss.wsf.spi.WSFException;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+
+import javax.naming.*;
+import javax.naming.spi.ObjectFactory;
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import java.io.ByteArrayInputStream;
+import java.io.IOException;
+import java.io.ObjectInputStream;
+import java.lang.reflect.Constructor;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.net.URL;
+import java.util.Hashtable;
+import org.jboss.logging.Logger;
+
+/**
+ * This ServiceObjectFactory reconstructs a javax.xml.ws.Service
+ * for a given WSDL when the webservice client does a JNDI lookup
+ *
+ * @see SunRIServiceReferenceable
+ *
+ * @author Heiko.Braun(a)jboss.com
+ * Created: Jul 12, 2007
+ * */
+public class SunRIServiceObjectFactory implements ObjectFactory
+{
+ protected final Logger log = Logger.getLogger(SunRIServiceObjectFactory.class);
+
+ /**
+ * Creates an object using the location or reference information specified.
+ * <p/>
+ *
+ * @param obj The possibly null object containing location or reference
+ * information that can be used in creating an object.
+ * @param name The name of this object relative to <code>nameCtx</code>,
+ * or null if no name is specified.
+ * @param nameCtx The context relative to which the <code>name</code>
+ * parameter is specified, or null if <code>name</code> is
+ * relative to the default initial context.
+ * @param environment The possibly null environment that is used in
+ * creating the object.
+ * @return The object created; null if an object cannot be created.
+ * @throws Exception if this object factory encountered an exception
+ * while attempting to create an object, and no other object factories are
+ * to be tried.
+ * @see javax.naming.spi.NamingManager#getObjectInstance
+ * @see javax.naming.spi.NamingManager#getURLContext
+ */
+ public Object getObjectInstance(Object obj, Name name, Context nameCtx, Hashtable environment) throws Exception
+ {
+ try
+ {
+ Reference ref = (Reference)obj;
+
+ // Get the target class name
+ String targetClassName = (String)ref.get(SunRIServiceReferenceable.TARGET_CLASS_NAME).getContent();
+
+ // Unmarshall the UnifiedServiceRef
+ UnifiedServiceRefMetaData serviceRef = unmarshallServiceRef(ref);
+ String serviceRefName = serviceRef.getServiceRefName();
+ QName serviceQName = serviceRef.getServiceQName();
+
+ String serviceImplClass = serviceRef.getServiceImplClass();
+ if (serviceImplClass == null)
+ serviceImplClass = (String)ref.get(SunRIServiceReferenceable.SERVICE_IMPL_CLASS).getContent();
+
+ // If the target defaults to javax.xml.ws.Service, use the service as the target
+ if (Service.class.getName().equals(targetClassName))
+ targetClassName = serviceImplClass;
+
+ log.debug("getObjectInstance [name=" + serviceRefName + ",service=" + serviceImplClass + ",target=" + targetClassName + "]");
+
+ // Load the service class
+ ClassLoader ctxLoader = Thread.currentThread().getContextClassLoader();
+ Class serviceClass = ctxLoader.loadClass(serviceImplClass);
+ Class targetClass = (targetClassName != null ? ctxLoader.loadClass(targetClassName) : null);
+
+ if (Service.class.isAssignableFrom(serviceClass) == false)
+ throw new IllegalArgumentException("WebServiceRef type '" + serviceClass + "' is not assignable to javax.xml.ws.Service");
+
+ // Receives either a javax.xml.ws.Service or a dynamic proxy
+ Object target;
+
+ // Get the URL to the wsdl
+ URL wsdlURL = serviceRef.getWsdlLocation();
+
+ // Generic javax.xml.ws.Service
+ if (serviceClass == Service.class)
+ {
+ if (wsdlURL != null)
+ {
+ target = Service.create(wsdlURL, serviceQName);
+ }
+ else
+ {
+ throw new IllegalArgumentException("Cannot create generic javax.xml.ws.Service without wsdlLocation: " + serviceRefName);
+ }
+ }
+ // Generated javax.xml.ws.Service subclass
+ else
+ {
+ if (wsdlURL != null)
+ {
+ Constructor ctor = serviceClass.getConstructor(new Class[] { URL.class, QName.class });
+ target = ctor.newInstance(new Object[] { wsdlURL, serviceQName });
+ }
+ else
+ {
+ target = (Service)serviceClass.newInstance();
+ }
+ }
+
+ // Configure the service
+ configureService((Service)target, serviceRef);
+
+ if (targetClassName != null && targetClassName.equals(serviceImplClass) == false)
+ {
+ try
+ {
+ Object port = null;
+ if (serviceClass != Service.class)
+ {
+ for (Method method : serviceClass.getDeclaredMethods())
+ {
+ String methodName = method.getName();
+ Class retType = method.getReturnType();
+ if (methodName.startsWith("get") && targetClass.isAssignableFrom(retType))
+ {
+ port = method.invoke(target, new Object[0]);
+ target = port;
+ break;
+ }
+ }
+ }
+
+ if (port == null)
+ {
+ Method method = serviceClass.getMethod("getPort", new Class[] { Class.class });
+ port = method.invoke(target, new Object[] { targetClass });
+ target = port;
+ }
+ }
+ catch (InvocationTargetException ex)
+ {
+ throw ex.getTargetException();
+ }
+ }
+
+ return target;
+ }
+ catch (Throwable ex)
+ {
+ WSFException.rethrow("Cannot create service", ex);
+ return null;
+ }
+ }
+
+
+ private void configureService(Service service, UnifiedServiceRefMetaData serviceRef)
+ {
+ log.warn("Service configuration not available in Sun-RI");
+ }
+
+ private UnifiedServiceRefMetaData unmarshallServiceRef(Reference ref) throws ClassNotFoundException, NamingException
+ {
+ UnifiedServiceRefMetaData sref;
+ RefAddr refAddr = ref.get(SunRIServiceReferenceable.SERVICE_REF_META_DATA);
+ ByteArrayInputStream bais = new ByteArrayInputStream((byte[])refAddr.getContent());
+ try
+ {
+ ObjectInputStream ois = new ObjectInputStream(bais);
+ sref = (UnifiedServiceRefMetaData)ois.readObject();
+ ois.close();
+ }
+ catch (IOException e)
+ {
+ throw new NamingException("Cannot unmarshall service ref meta data, cause: " + e.toString());
+ }
+
+ // Verify it. There is some know coinstraints
+ if(null == sref.getServiceQName())
+ throw new IllegalArgumentException("ServiceQName may not be null. " +
+ "Specify a service QName in the service-ref declaration.");
+
+ return sref;
+ }
+}
+
Deleted: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceReferenceable.java
===================================================================
--- branches/hbraun/trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceReferenceable.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceReferenceable.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,88 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.wsf.stack.sunri.client;
-
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-
-import javax.naming.*;
-import java.io.ByteArrayOutputStream;
-import java.io.ObjectOutputStream;
-import java.io.IOException;
-
-/**
- * A JNDI reference to a javax.xml.ws.Service
- *
- * It holds the information to reconstrut the javax.xml.ws.Service
- * when the client does a JNDI lookup.
- *
- * @author Heiko.Braun(a)jboss.com
- */
-public class SunRIServiceReferenceable implements Referenceable
-{
- public static final String SERVICE_REF_META_DATA = "SERVICE_REF_META_DATA";
- public static final String SERVICE_IMPL_CLASS = "SERVICE_CLASS_NAME";
- public static final String TARGET_CLASS_NAME = "TARGET_CLASS_NAME";
-
- private String serviceImplClass;
- private String targetClassName;
- private UnifiedServiceRefMetaData serviceRef;
-
- public SunRIServiceReferenceable(String serviceImplClass, String targetClassName, UnifiedServiceRefMetaData serviceRef)
- {
- this.serviceImplClass = serviceImplClass;
- this.targetClassName = targetClassName;
- this.serviceRef = serviceRef;
- }
-
- /**
- * Retrieves the Reference of this object.
- *
- * @return The non-null Reference of this object.
- * @throws javax.naming.NamingException If a naming exception was encountered while retrieving the reference.
- */
- public Reference getReference() throws NamingException
- {
- Reference myRef = new Reference(SunRIServiceReferenceable.class.getName(), SunRIServiceObjectFactory.class.getName(), null);
-
- myRef.add(new StringRefAddr(SERVICE_IMPL_CLASS, serviceImplClass));
- myRef.add(new StringRefAddr(TARGET_CLASS_NAME, targetClassName));
- myRef.add(new BinaryRefAddr(SERVICE_REF_META_DATA, marshall(serviceRef)));
-
- return myRef;
- }
-
- private byte[] marshall(Object obj) throws NamingException
- {
- ByteArrayOutputStream baos = new ByteArrayOutputStream(512);
- try
- {
- ObjectOutputStream oos = new ObjectOutputStream(baos);
- oos.writeObject(obj);
- oos.close();
- }
- catch (IOException e)
- {
- throw new NamingException("Cannot marshall object, cause: " + e.toString());
- }
- return baos.toByteArray();
- }
-}
Copied: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceReferenceable.java (from rev 3873, branches/hbraun/trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceReferenceable.java)
===================================================================
--- trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceReferenceable.java (rev 0)
+++ trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/client/SunRIServiceReferenceable.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,88 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.wsf.stack.sunri.client;
+
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+
+import javax.naming.*;
+import java.io.ByteArrayOutputStream;
+import java.io.ObjectOutputStream;
+import java.io.IOException;
+
+/**
+ * A JNDI reference to a javax.xml.ws.Service
+ *
+ * It holds the information to reconstrut the javax.xml.ws.Service
+ * when the client does a JNDI lookup.
+ *
+ * @author Heiko.Braun(a)jboss.com
+ */
+public class SunRIServiceReferenceable implements Referenceable
+{
+ public static final String SERVICE_REF_META_DATA = "SERVICE_REF_META_DATA";
+ public static final String SERVICE_IMPL_CLASS = "SERVICE_CLASS_NAME";
+ public static final String TARGET_CLASS_NAME = "TARGET_CLASS_NAME";
+
+ private String serviceImplClass;
+ private String targetClassName;
+ private UnifiedServiceRefMetaData serviceRef;
+
+ public SunRIServiceReferenceable(String serviceImplClass, String targetClassName, UnifiedServiceRefMetaData serviceRef)
+ {
+ this.serviceImplClass = serviceImplClass;
+ this.targetClassName = targetClassName;
+ this.serviceRef = serviceRef;
+ }
+
+ /**
+ * Retrieves the Reference of this object.
+ *
+ * @return The non-null Reference of this object.
+ * @throws javax.naming.NamingException If a naming exception was encountered while retrieving the reference.
+ */
+ public Reference getReference() throws NamingException
+ {
+ Reference myRef = new Reference(SunRIServiceReferenceable.class.getName(), SunRIServiceObjectFactory.class.getName(), null);
+
+ myRef.add(new StringRefAddr(SERVICE_IMPL_CLASS, serviceImplClass));
+ myRef.add(new StringRefAddr(TARGET_CLASS_NAME, targetClassName));
+ myRef.add(new BinaryRefAddr(SERVICE_REF_META_DATA, marshall(serviceRef)));
+
+ return myRef;
+ }
+
+ private byte[] marshall(Object obj) throws NamingException
+ {
+ ByteArrayOutputStream baos = new ByteArrayOutputStream(512);
+ try
+ {
+ ObjectOutputStream oos = new ObjectOutputStream(baos);
+ oos.writeObject(obj);
+ oos.close();
+ }
+ catch (IOException e)
+ {
+ throw new NamingException("Cannot marshall object, cause: " + e.toString());
+ }
+ return baos.toByteArray();
+ }
+}
Copied: trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/injection (from rev 3873, branches/hbraun/trunk/integration/sunri/src/main/java/org/jboss/wsf/stack/sunri/injection)
Modified: trunk/integration/sunri/src/main/resources/jbossws-sunri42.sar/jbossws.beans/META-INF/jboss-beans.xml
===================================================================
--- trunk/integration/sunri/src/main/resources/jbossws-sunri42.sar/jbossws.beans/META-INF/jboss-beans.xml 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/sunri/src/main/resources/jbossws-sunri42.sar/jbossws.beans/META-INF/jboss-beans.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -31,7 +31,9 @@
<!-- Bind Service objects in client environment context -->
<!-- The bean name is compiled into the server. Changeit with the next release. -->
- <!--bean name="ServiceRefHandler" class="org.jboss.ws.core.client.ServiceRefHandlerImpl"/-->
+
+ <!-- Bind Service objects in client environment context -->
+ <!--bean name="WSServiceRefHandler" class="org.jboss.wsf.spi.deployment.serviceref.ServiceRefHandlerImpl"/-->
<!-- Locate the single instance of the kernel -->
<bean name="WSKernelLocator" class="org.jboss.ws.integration.KernelLocator">
Modified: trunk/integration/sunri/src/main/resources/jbossws-sunri50.deployer/META-INF/jbossws-deployer-beans.xml
===================================================================
--- trunk/integration/sunri/src/main/resources/jbossws-sunri50.deployer/META-INF/jbossws-deployer-beans.xml 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/sunri/src/main/resources/jbossws-sunri50.deployer/META-INF/jbossws-deployer-beans.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -8,16 +8,6 @@
<bean name="WebServiceDeployerEJB" class="org.jboss.wsf.container.jboss50.WebServiceDeployerEJB">
<property name="relOrderEJB2x"><inject bean="EJB2xDeployer" property="relativeOrder"/></property>
<property name="relOrderEJB3"><inject bean="EJBRegistrationDeployer" property="relativeOrder"/></property>
- <install bean="MainDeployer" method="addDeployer">
- <parameter>
- <this/>
- </parameter>
- </install>
- <uninstall bean="MainDeployer" method="removeDeployer">
- <parameter>
- <this/>
- </parameter>
- </uninstall>
<depends>EJB2xDeployer</depends>
<depends>EJBRegistrationDeployer</depends>
</bean>
@@ -27,16 +17,6 @@
-->
<bean name="WebServiceDeployerJSE" class="org.jboss.wsf.container.jboss50.WebServiceDeployerJSE">
<property name="relOrderWar"><inject bean="WarDeployer" property="relativeOrder"/></property>
- <install bean="MainDeployer" method="addDeployer">
- <parameter>
- <this/>
- </parameter>
- </install>
- <uninstall bean="MainDeployer" method="removeDeployer">
- <parameter>
- <this/>
- </parameter>
- </uninstall>
<depends>WebAppParsingDeployer</depends>
</bean>
@@ -46,16 +26,6 @@
<bean name="WebServiceMainDeployer" class="org.jboss.wsf.container.jboss50.WebServiceMainDeployer">
<property name="relOrderJSE"><inject bean="WebServiceDeployerJSE" property="relativeOrder"/></property>
<property name="relOrderEJB"><inject bean="WebServiceDeployerEJB" property="relativeOrder"/></property>
- <install bean="MainDeployer" method="addDeployer">
- <parameter>
- <this/>
- </parameter>
- </install>
- <uninstall bean="MainDeployer" method="removeDeployer">
- <parameter>
- <this/>
- </parameter>
- </uninstall>
<depends>WarDeployer</depends>
<depends>WebServiceDeployerEJB</depends>
<depends>WebServiceDeployerJSE</depends>
Modified: trunk/integration/sunri/src/main/resources/jbossws-sunri50.sar/META-INF/jbossws-beans.xml
===================================================================
--- trunk/integration/sunri/src/main/resources/jbossws-sunri50.sar/META-INF/jbossws-beans.xml 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/sunri/src/main/resources/jbossws-sunri50.sar/META-INF/jbossws-beans.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -29,8 +29,15 @@
<bean name="WSEndpointRegistry" class="org.jboss.wsf.stack.sunri.ManagedEndpointRegistry"/>
<!-- Bind Service objects in client environment context -->
- <!-- The bean name is compiled into the server. Changeit with the next release. -->
- <!--bean name="ServiceRefHandler" class="org.jboss.ws.core.client.ServiceRefHandlerImpl"/-->
+ <bean name="WSServiceRefHandler" class="org.jboss.wsf.spi.deployment.serviceref.ServiceRefHandlerImpl">
+ <property name="jaxrpcBinder"><inject bean="WSServiceRefBinderJAXRPC"/></property>
+ <property name="jaxwsBinder"><inject bean="WSServiceRefBinderJAXWS"/></property>
+ </bean>
+
+ <bean name="WSServiceRefBinderJAXRPC" class="org.jboss.wsf.stack.sunri.client.DummyServiceRefBinderJAXRPC"/>
+
+ <bean name="WSServiceRefBinderJAXWS" class="org.jboss.wsf.stack.sunri.client.ServiceRefBinderJAXWS"/>
+
<!-- Locate the single instance of the kernel -->
<bean name="WSKernelLocator" class="org.jboss.ws.integration.KernelLocator">
Modified: trunk/integration/sunri/src/test/resources/test-excludes.txt
===================================================================
--- trunk/integration/sunri/src/test/resources/test-excludes.txt 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/integration/sunri/src/test/resources/test-excludes.txt 2007-07-13 11:55:00 UTC (rev 3879)
@@ -18,5 +18,4 @@
org/jboss/test/ws/jaxws/samples/jaxr/**
# [JBWS-1674] Fix @WebServiceRef with SunRI
-org/jboss/test/ws/jaxws/samples/retail/**
-org/jboss/test/ws/jaxws/samples/webserviceref/**
+#org/jboss/test/ws/jaxws/samples/retail/**
Modified: trunk/jbossws-core/ant-import-tests/build-jars-jaxws.xml
===================================================================
--- trunk/jbossws-core/ant-import-tests/build-jars-jaxws.xml 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/jbossws-core/ant-import-tests/build-jars-jaxws.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -344,51 +344,6 @@
</webinf>
</war>
- <!-- jaxws-serviceref -->
- <war warfile="${tests.output.dir}/libs/jaxws-serviceref.war" webxml="${tests.output.dir}/resources/jaxws/serviceref/WEB-INF/web.xml">
- <classes dir="${tests.output.dir}/classes">
- <include name="org/jboss/test/ws/jaxws/serviceref/TestEndpointImpl.class"/>
- </classes>
- </war>
- <jar destfile="${tests.output.dir}/libs/jaxws-serviceref-client.jar">
- <fileset dir="${tests.output.dir}/classes">
- <include name="org/jboss/test/ws/jaxws/serviceref/ApplicationClient.class"/>
- <include name="org/jboss/test/ws/jaxws/serviceref/TestEndpointService.class"/>
- <include name="org/jboss/test/ws/jaxws/serviceref/TestEndpoint.class"/>
- </fileset>
- <metainf dir="${tests.output.dir}/resources/jaxws/serviceref/META-INF">
- <include name="application-client.xml"/>
- <include name="jboss-client.xml"/>
- <include name="wsdl/**"/>
- </metainf>
- </jar>
- <war destfile="${tests.output.dir}/libs/jaxws-serviceref-servlet-client.war" webxml="${tests.output.dir}/resources/jaxws/serviceref/servlet-client/WEB-INF/web.xml">
- <classes dir="${tests.output.dir}/classes">
- <include name="org/jboss/test/ws/jaxws/serviceref/ServletClient.class"/>
- <include name="org/jboss/test/ws/jaxws/serviceref/TestEndpointService.class"/>
- <include name="org/jboss/test/ws/jaxws/serviceref/TestEndpoint.class"/>
- </classes>
- <webinf dir="${tests.output.dir}/resources/jaxws/serviceref/META-INF">
- <include name="wsdl/**"/>
- </webinf>
- <webinf dir="${tests.output.dir}/resources/jaxws/serviceref/servlet-client/WEB-INF">
- <include name="jboss-web.xml"/>
- </webinf>
- </war>
- <jar destfile="${tests.output.dir}/libs/jaxws-serviceref-ejb-client.jar">
- <fileset dir="${tests.output.dir}/classes">
- <include name="org/jboss/test/ws/jaxws/serviceref/EJBClient.class"/>
- <include name="org/jboss/test/ws/jaxws/serviceref/EJBRemote.class"/>
- <include name="org/jboss/test/ws/jaxws/serviceref/TestEndpointService.class"/>
- <include name="org/jboss/test/ws/jaxws/serviceref/TestEndpoint.class"/>
- </fileset>
- <metainf dir="${tests.output.dir}/resources/jaxws/serviceref/META-INF">
- <include name="ejb-jar.xml"/>
- <include name="jboss.xml"/>
- <include name="wsdl/**"/>
- </metainf>
- </jar>
-
<!-- jaxws-wrapped-accessor -->
<war warfile="${tests.output.dir}/libs/jaxws-wrapped-accessor.war" webxml="${tests.output.dir}/resources/jaxws/wrapped/accessor/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
Deleted: trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/ServiceRefHandlerImpl.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,166 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.core.client;
-
-// $Id$
-
-import java.lang.reflect.AnnotatedElement;
-import java.net.URL;
-import java.net.MalformedURLException;
-import java.io.File;
-
-import javax.naming.Context;
-import javax.naming.NamingException;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.core.jaxrpc.client.ServiceRefHandlerJAXRPC;
-import org.jboss.ws.core.jaxws.client.ServiceRefHandlerJAXWS;
-import org.jboss.ws.integration.*;
-import org.jboss.ws.metadata.umdm.EndpointMetaData.Type;
-import org.jboss.ws.WSException;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-import org.jboss.xb.binding.UnmarshallingContext;
-import org.xml.sax.Attributes;
-
-/**
- * Bind service refs in the client's ENC for every service-ref element in the
- * deployment descriptor.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 04-Nov-2006
- */
-public class ServiceRefHandlerImpl implements ServiceRefHandler
-{
- // logging support
- private static Logger log = Logger.getLogger(ServiceRefHandlerImpl.class);
-
- private ServiceRefObjectFactory objectFactory = new ServiceRefObjectFactory();
-
- public ServiceRefMetaData newServiceRefMetaData()
- {
- return new UnifiedServiceRefMetaData();
- }
-
- public void bindServiceRef(Context encCtx, String encName, UnifiedVirtualFile vfsRoot, ClassLoader loader, ServiceRefMetaData sref) throws NamingException
- {
- if (sref.isProcessed())
- {
- log.debug("Attempt to rebind the service-ref: " + sref.getServiceRefName());
- return;
- }
-
- // In case of an .war deployment the associated root file doesn't point to
- // the expanded war file structure and thus breaks service-ref usage for servlet clients.
- // This needs to be fixed in org.jboss.web.AbstractWebDeployer (JBOSS_AS/server module)
- if(vfsRoot instanceof URLLoaderAdapter)
- {
- URLLoaderAdapter ula = (URLLoaderAdapter)vfsRoot;
- URL rootURL = ula.toURL();
- if("file".equals( rootURL.getProtocol()) && rootURL.getFile().endsWith(".war") )
- {
- String fileName = rootURL.getFile();
-
- if( ! new File(fileName).exists() ) // might be an exploded directory
- {
- // There is a filename convention for exploded directories
- fileName = fileName.substring(0, fileName.indexOf(".war")) + "-exp.war";
-
- File expandedDirectory = new File(fileName);
- if(! expandedDirectory.exists())
- throw new WSException("Failed to bind service-ref, the deployment root expandedDirectory doesn't exist: " + fileName);
-
- // update the rootFile
- try
- {
- vfsRoot = new URLLoaderAdapter(expandedDirectory.toURL());
- }
- catch (MalformedURLException e){}
- }
-
- }
- }
-
- UnifiedServiceRefMetaData serviceRef = (UnifiedServiceRefMetaData)sref;
- serviceRef.setVfsRoot(vfsRoot);
- try
- {
- if (getServiceRefType(serviceRef, loader) == Type.JAXRPC)
- {
- ServiceRefHandlerJAXRPC handler = new ServiceRefHandlerJAXRPC();
- handler.setupServiceRef(encCtx, encName, serviceRef);
- }
- else
- {
- AnnotatedElement anElement = (AnnotatedElement)sref.getAnnotatedElement();
- ServiceRefHandlerJAXWS handler = new ServiceRefHandlerJAXWS();
- handler.setupServiceRef(encCtx, encName, anElement, serviceRef);
- }
- }
- finally
- {
- sref.setProcessed(true);
- }
- }
-
- public Object newChild(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- return objectFactory.newChild(ref, navigator, namespaceURI, localName, attrs);
- }
-
- public void setValue(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- objectFactory.setValue(ref, navigator, namespaceURI, localName, value);
- }
-
- private Type getServiceRefType(UnifiedServiceRefMetaData serviceRef, ClassLoader loader) throws NamingException
- {
- // The service-ref-type is JAXWS specific
- String serviceRefType = serviceRef.getServiceRefType();
- if (serviceRefType != null || serviceRef.getAnnotatedElement() != null)
- return Type.JAXWS;
-
- // The mapping-file is JAXRPC specific
- if (serviceRef.getMappingFile() != null)
- return Type.JAXRPC;
-
- String siName = serviceRef.getServiceInterface();
- if (siName == null)
- throw new IllegalStateException("<service-interface> cannot be null");
-
- if (siName.equals("javax.xml.rpc.Service"))
- return Type.JAXRPC;
-
- try
- {
- Class siClass = loader.loadClass(siName);
- if (javax.xml.ws.Service.class.isAssignableFrom(siClass))
- return Type.JAXWS;
- else if (javax.xml.rpc.Service.class.isAssignableFrom(siClass))
- return Type.JAXRPC;
- else throw new IllegalStateException("Illegal service interface: " + siName);
- }
- catch (ClassNotFoundException e)
- {
- throw new IllegalStateException("Cannot load <service-interface>: " + siName);
- }
- }
-}
Deleted: trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/client/ServiceRefObjectFactory.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,305 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.core.client;
-
-// $Id$
-
-import javax.xml.namespace.QName;
-
-import org.jboss.ws.integration.ServiceRefElement;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedCallPropertyMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerChainMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerChainsMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedHandlerMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedInitParamMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedPortComponentRefMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedStubPropertyMetaData;
-import org.jboss.xb.binding.UnmarshallingContext;
-import org.xml.sax.Attributes;
-
-/**
- * A object model factory for <service-ref>
- *
- * @author Thomas.Diesler(a)jboss.com
- */
-public class ServiceRefObjectFactory
-{
- public Object newChild(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (ref instanceof UnifiedHandlerChainsMetaData)
- child = newChild((UnifiedHandlerChainsMetaData)ref, navigator, namespaceURI, localName, attrs);
- else if (ref instanceof UnifiedHandlerMetaData)
- child = newChild((UnifiedHandlerMetaData)ref, navigator, namespaceURI, localName, attrs);
- else if (ref instanceof UnifiedPortComponentRefMetaData)
- child = newChild((UnifiedPortComponentRefMetaData)ref, navigator, namespaceURI, localName, attrs);
- else if (ref instanceof UnifiedServiceRefMetaData)
- child = newChild((UnifiedServiceRefMetaData)ref, navigator, namespaceURI, localName, attrs);
- return child;
- }
-
- public void setValue(ServiceRefElement ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (ref instanceof UnifiedCallPropertyMetaData)
- setValue((UnifiedCallPropertyMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedHandlerChainMetaData)
- setValue((UnifiedHandlerChainMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedHandlerMetaData)
- setValue((UnifiedHandlerMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedInitParamMetaData)
- setValue((UnifiedInitParamMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedPortComponentRefMetaData)
- setValue((UnifiedPortComponentRefMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedServiceRefMetaData)
- setValue((UnifiedServiceRefMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedCallPropertyMetaData)
- setValue((UnifiedCallPropertyMetaData)ref, navigator, namespaceURI, localName, value);
- else if (ref instanceof UnifiedStubPropertyMetaData)
- setValue((UnifiedStubPropertyMetaData)ref, navigator, namespaceURI, localName, value);
- }
-
- private void setValue(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- /* Standard properties */
- if (localName.equals("service-ref-name"))
- {
- ref.setServiceRefName(value);
- }
- else if (localName.equals("service-interface"))
- {
- ref.setServiceInterface(value);
- }
- else if (localName.equals("service-ref-type"))
- {
- ref.setServiceRefType(value);
- }
- else if (localName.equals("wsdl-file"))
- {
- ref.setWsdlFile(value);
- }
- else if (localName.equals("jaxrpc-mapping-file"))
- {
- ref.setMappingFile(value);
- }
- else if (localName.equals("service-qname"))
- {
- ref.setServiceQName(getQNameValue(navigator, value));
- }
-
- /* JBoss properties */
- else if (localName.equals("service-impl-class"))
- {
- ref.setServiceImplClass(value);
- }
- else if (localName.equals("config-name"))
- {
- ref.setConfigName(value);
- }
- else if (localName.equals("config-file"))
- {
- ref.setConfigFile(value);
- }
- else if (localName.equals("wsdl-override"))
- {
- ref.setWsdlOverride(value);
- }
- else if (localName.equals("handler-chain"))
- {
- ref.setHandlerChain(value);
- }
- }
-
- private Object newChild(UnifiedServiceRefMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("port-component-ref"))
- {
- child = new UnifiedPortComponentRefMetaData(ref);
- ref.addPortComponentRef((UnifiedPortComponentRefMetaData)child);
- }
- else if (localName.equals("handler"))
- {
- child = new UnifiedHandlerMetaData();
- ref.addHandler((UnifiedHandlerMetaData)child);
- }
- else if (localName.equals("handler-chains"))
- {
- child = new UnifiedHandlerChainsMetaData();
- ref.setHandlerChains((UnifiedHandlerChainsMetaData)child);
- }
- else if (localName.equals("call-property"))
- {
- child = new UnifiedCallPropertyMetaData();
- ref.addCallProperty((UnifiedCallPropertyMetaData)child);
- }
- return child;
- }
-
- private Object newChild(UnifiedHandlerChainsMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("handler-chain"))
- {
- child = new UnifiedHandlerChainMetaData();
- ref.addHandlerChain((UnifiedHandlerChainMetaData)child);
- }
- return child;
- }
-
- private void setValue(UnifiedPortComponentRefMetaData pcref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("service-endpoint-interface"))
- {
- pcref.setServiceEndpointInterface(value);
- }
- else if (localName.equals("enable-mtom"))
- {
- pcref.setEnableMTOM(Boolean.valueOf(value));
- }
- else if (localName.equals("port-component-link"))
- {
- pcref.setPortComponentLink(value);
- }
- else if (localName.equals("port-qname"))
- {
- pcref.setPortQName(getQNameValue(navigator, value));
- }
- else if (localName.equals("config-name"))
- {
- pcref.setConfigName(value);
- }
- else if (localName.equals("config-file"))
- {
- pcref.setConfigFile(value);
- }
- }
-
- private Object newChild(UnifiedPortComponentRefMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("call-property"))
- {
- child = new UnifiedCallPropertyMetaData();
- ref.addCallProperty((UnifiedCallPropertyMetaData)child);
- }
- if (localName.equals("stub-property"))
- {
- child = new UnifiedStubPropertyMetaData();
- ref.addStubProperty((UnifiedStubPropertyMetaData)child);
- }
- return child;
- }
-
- private void setValue(UnifiedHandlerChainMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("service-name-pattern"))
- {
- ref.setServiceNamePattern(getQNameValue(navigator, value));
- }
- else if (localName.equals("port-name-pattern"))
- {
- ref.setPortNamePattern(getQNameValue(navigator, value));
- }
- else if (localName.equals("protocol-binding"))
- {
- ref.setProtocolBindings(value);
- }
- }
-
- private void setValue(UnifiedHandlerMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("handler-name"))
- {
- ref.setHandlerName(value);
- }
- else if (localName.equals("handler-class"))
- {
- ref.setHandlerClass(value);
- }
- else if (localName.equals("soap-header"))
- {
- ref.addSoapHeader(getQNameValue(navigator, value));
- }
- else if (localName.equals("soap-role"))
- {
- ref.addSoapRole(value);
- }
- else if (localName.equals("port-name"))
- {
- ref.addPortName(value);
- }
- }
-
- private Object newChild(UnifiedHandlerMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, Attributes attrs)
- {
- Object child = null;
- if (localName.equals("init-param"))
- {
- child = new UnifiedInitParamMetaData();
- ref.addInitParam((UnifiedInitParamMetaData)child);
- }
- return child;
- }
-
- private void setValue(UnifiedInitParamMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("param-name"))
- {
- ref.setParamName(value);
- }
- else if (localName.equals("param-value"))
- {
- ref.setParamValue(value);
- }
- }
-
- private void setValue(UnifiedCallPropertyMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("prop-name"))
- {
- ref.setPropName(value);
- }
- else if (localName.equals("prop-value"))
- {
- ref.setPropValue(value);
- }
- }
-
- private void setValue(UnifiedStubPropertyMetaData ref, UnmarshallingContext navigator, String namespaceURI, String localName, String value)
- {
- if (localName.equals("prop-name"))
- {
- ref.setPropName(value);
- }
- else if (localName.equals("prop-value"))
- {
- ref.setPropValue(value);
- }
- }
-
- private QName getQNameValue(UnmarshallingContext navigator, String value)
- {
- QName qname = (value.startsWith("{") ? QName.valueOf(value) : navigator.resolveQName(value));
- return qname;
- }
-}
Copied: trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceRefBinderJAXRPC.java (from rev 3873, branches/hbraun/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceRefBinderJAXRPC.java)
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceRefBinderJAXRPC.java (rev 0)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceRefBinderJAXRPC.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,61 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.core.jaxrpc.client;
+
+// $Id$
+
+import javax.naming.Context;
+import javax.naming.NamingException;
+
+import org.jboss.logging.Logger;
+import org.jboss.util.naming.Util;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+import org.jboss.wsf.spi.deployment.serviceref.ServiceRefBinder;
+
+import java.lang.reflect.AnnotatedElement;
+
+/**
+ * Binds a JAXRPC Service object in the client's ENC for every service-ref element in the
+ * deployment descriptor.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 04-Nov-2006
+ */
+public class ServiceRefBinderJAXRPC implements ServiceRefBinder
+{
+ // logging support
+ private static Logger log = Logger.getLogger(ServiceRefBinderJAXRPC.class);
+
+ /**
+ * Binds a Service into the callers ENC for every service-ref element
+ */
+ public void setupServiceRef(Context encCtx, String encName, AnnotatedElement anElement, UnifiedServiceRefMetaData serviceRef)
+ throws NamingException
+ {
+ String externalName = encCtx.getNameInNamespace() + "/" + encName;
+ log.info("setupServiceRef [jndi=" + externalName + "]");
+
+ // Do not use rebind, the binding should be unique
+ ServiceReferenceable ref = new ServiceReferenceable(serviceRef);
+ Util.bind(encCtx, encName, ref);
+ }
+}
Deleted: trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceRefHandlerJAXRPC.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceRefHandlerJAXRPC.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceRefHandlerJAXRPC.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,57 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.core.jaxrpc.client;
-
-// $Id$
-
-import javax.naming.Context;
-import javax.naming.NamingException;
-
-import org.jboss.logging.Logger;
-import org.jboss.util.naming.Util;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-
-/**
- * Binds a JAXRPC Service object in the client's ENC for every service-ref element in the
- * deployment descriptor.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 04-Nov-2006
- */
-public class ServiceRefHandlerJAXRPC
-{
- // logging support
- private static Logger log = Logger.getLogger(ServiceRefHandlerJAXRPC.class);
-
- /**
- * Binds a Service into the callers ENC for every service-ref element
- */
- public void setupServiceRef(Context encCtx, String encName, UnifiedServiceRefMetaData serviceRef) throws NamingException
- {
- String externalName = encCtx.getNameInNamespace() + "/" + encName;
- log.info("setupServiceRef [jndi=" + externalName + "]");
-
- // Do not use rebind, the binding should be unique
- ServiceReferenceable ref = new ServiceReferenceable(serviceRef);
- Util.bind(encCtx, encName, ref);
- }
-}
Copied: trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxws/client/ServiceRefBinderJAXWS.java (from rev 3873, branches/hbraun/trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxws/client/ServiceRefBinderJAXWS.java)
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxws/client/ServiceRefBinderJAXWS.java (rev 0)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxws/client/ServiceRefBinderJAXWS.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,44 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ws.core.jaxws.client;
+
+// $Id$
+
+import org.jboss.wsf.spi.deployment.serviceref.CommonServiceRefBinder;
+import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
+
+import javax.naming.Referenceable;
+
+/**
+ * Binds a JAXWS Service object in the client's ENC
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 17-Jan-2007
+ */
+public class ServiceRefBinderJAXWS extends CommonServiceRefBinder
+{
+ protected Referenceable buildServiceReferenceable(
+ String serviceImplClass, String targetClassName, UnifiedServiceRefMetaData serviceRef)
+ {
+ return new ServiceReferenceable(serviceImplClass, targetClassName, serviceRef);
+ }
+}
Deleted: trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxws/client/ServiceRefHandlerJAXWS.java
===================================================================
--- trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxws/client/ServiceRefHandlerJAXWS.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/jbossws-core/src/main/java/org/jboss/ws/core/jaxws/client/ServiceRefHandlerJAXWS.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,182 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ws.core.jaxws.client;
-
-// $Id$
-
-import org.jboss.logging.Logger;
-import org.jboss.util.naming.Util;
-import org.jboss.wsf.spi.metadata.j2ee.serviceref.UnifiedServiceRefMetaData;
-
-import javax.jws.HandlerChain;
-import javax.naming.Context;
-import javax.naming.NamingException;
-import javax.xml.ws.Service;
-import javax.xml.ws.WebServiceRef;
-import javax.xml.ws.WebServiceRefs;
-import java.lang.annotation.Annotation;
-import java.lang.reflect.AnnotatedElement;
-import java.lang.reflect.Field;
-import java.lang.reflect.Method;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Binds a JAXWS Service object in the client's ENC
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 17-Jan-2007
- */
-public class ServiceRefHandlerJAXWS
-{
- // logging support
- private static Logger log = Logger.getLogger(ServiceRefHandlerJAXWS.class);
-
- public void setupServiceRef(Context encCtx, String encName, AnnotatedElement anElement, UnifiedServiceRefMetaData serviceRef) throws NamingException
- {
- WebServiceRef wsref = null;
-
- // Build the list of @WebServiceRef relevant annotations
- List<WebServiceRef> wsrefList = new ArrayList<WebServiceRef>();
- if (anElement != null)
- {
- for (Annotation an : anElement.getAnnotations())
- {
- if (an instanceof WebServiceRef)
- wsrefList.add((WebServiceRef)an);
-
- if (an instanceof WebServiceRefs)
- {
- WebServiceRefs wsrefs = (WebServiceRefs)an;
- for (WebServiceRef aux : wsrefs.value())
- wsrefList.add(aux);
- }
- }
- }
-
- // Use the single @WebServiceRef
- if (wsrefList.size() == 1)
- {
- wsref = wsrefList.get(0);
- }
- else
- {
- for (WebServiceRef aux : wsrefList)
- {
- if (encName.endsWith("/" + aux.name()))
- {
- wsref = aux;
- break;
- }
- }
- }
-
- Class targetClass = null;
- if (anElement instanceof Field)
- {
- targetClass = ((Field)anElement).getType();
- }
- else if (anElement instanceof Method)
- {
- targetClass = ((Method)anElement).getParameterTypes()[0];
- }
- else
- {
- if( wsref!=null && (wsref.type() != Object.class) )
- targetClass = wsref.type();
- }
-
- String targetClassName = (targetClass != null ? targetClass.getName() : null);
- String externalName = encCtx.getNameInNamespace() + "/" + encName;
- log.debug("setupServiceRef [jndi=" + externalName + ",target=" + targetClassName + "]");
-
- String serviceImplClass = null;
-
- // #1 Use the explicit @WebServiceRef.value
- if (wsref != null && wsref.value() != Object.class)
- serviceImplClass = wsref.value().getName();
-
- // #2 Use the target ref type
- if (serviceImplClass == null && targetClass != null && Service.class.isAssignableFrom(targetClass))
- serviceImplClass = targetClass.getName();
-
- // #3 Use <service-interface>
- if (serviceImplClass == null && serviceRef.getServiceInterface() != null)
- serviceImplClass = serviceRef.getServiceInterface();
-
- // #4 Use javax.xml.ws.Service
- if (serviceImplClass == null)
- serviceImplClass = Service.class.getName();
-
- // #1 Use the explicit @WebServiceRef.type
- if (wsref != null && wsref.type() != Object.class)
- targetClassName = wsref.type().getName();
-
-
- // #2 Use the target ref type
- if (targetClassName == null && targetClass != null && Service.class.isAssignableFrom(targetClass) == false)
- targetClassName = targetClass.getName();
-
- // Set the wsdlLocation if there is no override already
- if (serviceRef.getWsdlOverride() == null && wsref != null && wsref.wsdlLocation().length() > 0)
- serviceRef.setWsdlOverride(wsref.wsdlLocation());
-
- // Set the handlerChain from @HandlerChain on the annotated element
- String handlerChain = serviceRef.getHandlerChain();
- if (anElement != null)
- {
- HandlerChain anHandlerChain = anElement.getAnnotation(HandlerChain.class);
- if (handlerChain == null && anHandlerChain != null && anHandlerChain.file().length() > 0)
- handlerChain = anHandlerChain.file();
- }
-
- // Resolve path to handler chain
- if (handlerChain != null)
- {
- try
- {
- new URL(handlerChain);
- }
- catch (MalformedURLException ex)
- {
- Class declaringClass = null;
- if (anElement instanceof Field)
- declaringClass = ((Field)anElement).getDeclaringClass();
- else if (anElement instanceof Method)
- declaringClass = ((Method)anElement).getDeclaringClass();
- else if (anElement instanceof Class)
- declaringClass = (Class)anElement;
-
- handlerChain = declaringClass.getPackage().getName().replace('.', '/') + "/" + handlerChain;
- }
-
- serviceRef.setHandlerChain(handlerChain);
- }
-
- // Do not use rebind, the binding should be unique
- // [JBWS-1499] - Revisit WebServiceRefHandler JNDI rebind
- Util.bind(encCtx, encName, new ServiceReferenceable(serviceImplClass, targetClassName, serviceRef));
-
- }
-}
Modified: trunk/jbossws-core/src/test/resources/test-excludes-jboss40.txt
===================================================================
--- trunk/jbossws-core/src/test/resources/test-excludes-jboss40.txt 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/jbossws-core/src/test/resources/test-excludes-jboss40.txt 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,6 +1,3 @@
-# Always exclude
-org/jboss/test/ws/benchmark/**
-
# JBossAS-4.0 excludes
org/jboss/test/ws/jaxrpc/jbws723/**
Modified: trunk/jbossws-core/src/test/resources/test-excludes-jboss42.txt
===================================================================
--- trunk/jbossws-core/src/test/resources/test-excludes-jboss42.txt 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/jbossws-core/src/test/resources/test-excludes-jboss42.txt 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,10 +1,7 @@
-# Always exclude
-org/jboss/test/ws/benchmark/**
-
# EJB3/Injection excludes
org/jboss/test/ws/jaxws/endpoint/**
org/jboss/test/ws/jaxws/jbws1581/**
org/jboss/test/ws/jaxws/samples/handlerchain/HandlerChainClientTestCase*
org/jboss/test/ws/jaxws/samples/retail/**
org/jboss/test/ws/jaxws/samples/webserviceref/**
-org/jboss/test/ws/jaxws/serviceref/**
+#org/jboss/test/ws/jaxws/serviceref/**
Modified: trunk/jbossws-core/src/test/resources/test-excludes-jboss50.txt
===================================================================
--- trunk/jbossws-core/src/test/resources/test-excludes-jboss50.txt 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/jbossws-core/src/test/resources/test-excludes-jboss50.txt 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,6 +1,3 @@
-# Always exclude
-org/jboss/test/ws/benchmark/**
-
# Fix before JBoss50 goes final
org/jboss/test/ws/jaxrpc/jbas897/JBAS897TestCase.*
org/jboss/test/ws/jaxrpc/jbws124/JBWS124TestCase.*
Modified: trunk/testsuite/ant-import/build-jars-jaxws.xml
===================================================================
--- trunk/testsuite/ant-import/build-jars-jaxws.xml 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/testsuite/ant-import/build-jars-jaxws.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -27,7 +27,7 @@
<include name="org/jboss/test/ws/jaxws/samples/asynchronous/TestEndpointBean.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-context -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-context.war" webxml="${tests.output.dir}/resources/jaxws/samples/context/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -45,7 +45,7 @@
<include name="jboss.xml"/>
</metainf>
</jar>
-
+
<!-- jaxws-samples-eardeployment -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-eardeployment.war" webxml="${tests.output.dir}/resources/jaxws/samples/eardeployment/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -92,7 +92,7 @@
<include name="org/jboss/test/ws/jaxws/samples/exception/server/UserException.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-handlerchain -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-handlerchain.war" webxml="${tests.output.dir}/resources/jaxws/samples/handlerchain/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -102,7 +102,7 @@
<include name="org/jboss/test/ws/jaxws/samples/handlerchain/jaxws-handlers-server.xml"/>
</classes>
</war>
-
+
<!-- jaxws-samples-httpbinding -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-httpbinding-jaxb.war" webxml="${tests.output.dir}/resources/jaxws/samples/httpbinding/jaxb/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -124,7 +124,7 @@
<include name="wsdl/HttpBinding.wsdl"/>
</webinf>
</war>
-
+
<!-- jaxws-samples-logicalhandler -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-logicalhandler-source.war"
webxml="${tests.output.dir}/resources/jaxws/samples/logicalhandler/WEB-INF/web-source.xml">
@@ -153,14 +153,14 @@
<include name="org/jboss/test/ws/jaxws/samples/logicalhandler/jaxws-server-jaxb-handlers.xml"/>
</classes>
</war>
-
+
<!-- jaxws-samples-oneway -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-oneway.war" webxml="${tests.output.dir}/resources/jaxws/samples/oneway/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
<include name="org/jboss/test/ws/jaxws/samples/oneway/PingEndpointImpl.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-provider -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-provider-jaxb.war" webxml="${tests.output.dir}/resources/jaxws/samples/provider/jaxb/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -190,7 +190,7 @@
<include name="wsdl/Provider.wsdl"/>
</webinf>
</war>
-
+
<!-- jaxws-samples-retail -->
<jar jarfile="${tests.output.dir}/libs/jaxws-samples-retail.jar">
<fileset dir="${tests.output.dir}/classes">
@@ -201,7 +201,54 @@
<include name="wsdl/*"/>
</metainf>
</jar>
-
+
+ <!-- jaxws-serviceref -->
+ <war warfile="${tests.output.dir}/libs/jaxws-serviceref.war" webxml="${tests.output.dir}/resources/jaxws/samples/serviceref/WEB-INF/web.xml">
+ <classes dir="${tests.output.dir}/classes">
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.class"/>
+ </classes>
+ </war>
+ <jar destfile="${tests.output.dir}/libs/jaxws-serviceref-client.jar">
+ <fileset dir="${tests.output.dir}/classes">
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/ApplicationClient.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.class"/>
+ </fileset>
+ <metainf dir="${tests.output.dir}/resources/jaxws/samples/serviceref/META-INF">
+ <include name="application-client.xml"/>
+ <include name="jboss-client.xml"/>
+ <include name="wsdl/**"/>
+ </metainf>
+ </jar>
+ <war destfile="${tests.output.dir}/libs/jaxws-serviceref-servlet-client.war" webxml="${tests.output.dir}/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml">
+ <classes dir="${tests.output.dir}/classes">
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.class"/>
+ </classes>
+ <webinf dir="${tests.output.dir}/resources/jaxws/samples/serviceref/META-INF">
+ <include name="wsdl/**"/>
+ </webinf>
+ <webinf dir="${tests.output.dir}/resources/jaxws/samples/serviceref/servlet-client/WEB-INF">
+ <include name="jboss-web.xml"/>
+ </webinf>
+ </war>
+ <jar destfile="${tests.output.dir}/libs/jaxws-serviceref-ejb-client.jar">
+ <fileset dir="${tests.output.dir}/classes">
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.class"/>
+ </fileset>
+ <metainf dir="${tests.output.dir}/resources/jaxws/samples/serviceref/META-INF">
+ <include name="ejb-jar.xml"/>
+ <include name="jboss.xml"/>
+ <include name="wsdl/**"/>
+ </metainf>
+ </jar>
+
<!-- jaxws-samples-soapbinding -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-soapbinding.war" webxml="${tests.output.dir}/resources/jaxws/samples/soapbinding/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -230,7 +277,7 @@
<include name="org/jboss/test/ws/jaxws/samples/swaref/DocumentPayload*.class"/>
</fileset>
</jar>
-
+
<!-- jaxws-samples-webmethod -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-webmethod.war" webxml="${tests.output.dir}/resources/jaxws/samples/webmethod/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -238,7 +285,7 @@
<include name="org/jboss/test/ws/jaxws/samples/webmethod/TestEndpointImpl.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-webparam -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-webparam.war" webxml="${tests.output.dir}/resources/jaxws/samples/webparam/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -247,7 +294,7 @@
<include name="org/jboss/test/ws/jaxws/samples/webparam/SecurityHeader.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-webresult -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-webresult.war" webxml="${tests.output.dir}/resources/jaxws/samples/webresult/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -256,7 +303,7 @@
<include name="org/jboss/test/ws/jaxws/samples/webresult/USAddress.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-webservice -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-webservice01-jse.war" webxml="${tests.output.dir}/resources/jaxws/samples/webservice/WEB-INF01/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -299,7 +346,7 @@
<include name="org/jboss/test/ws/jaxws/samples/webservice/EndpointInterface03.class"/>
</fileset>
</jar>
-
+
<!-- jaxws-samples-xop-doclit -->
<war jarfile="${tests.output.dir}/libs/jaxws-samples-xop-doclit.war" webxml="${tests.output.dir}/resources/jaxws/samples/xop/doclit/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
Modified: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/OrderMgmtBean.java
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/OrderMgmtBean.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/OrderMgmtBean.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -61,10 +61,21 @@
@PostConstruct
public void initialize()
{
- verificationPort = verificationService.getCCVerificationPort();
- profilePort = profileService.getProfileMgmtPort();
+ // Throws NPE with SUN-RI, use lazy initialize instead
+ //verificationPort = verificationService.getCCVerificationPort();
+ //profilePort = profileService.getProfileMgmtPort();
}
+ public CCVerification getVerificationPort()
+ {
+ return verificationService.getCCVerificationPort();
+ }
+
+ public ProfileMgmt getProfilePort()
+ {
+ return profileService.getProfileMgmtPort();
+ }
+
/**
* Prepare a customer order.
* This will verify the billing details (i.e. creditcard)
@@ -81,17 +92,20 @@
// verify billing details
String creditCard = order.getCustomer().getCreditCardDetails();
- Response<Boolean> response = verificationPort.verifyAsync(creditCard);
+ //Response<Boolean> response = getVerificationPort().verifyAsync(creditCard);
+ boolean validCard = getVerificationPort().verify(creditCard);
+
// high value customer discount
DiscountRequest discountRequest = new DiscountRequest(order.getCustomer());
- DiscountResponse discount = profilePort.getCustomerDiscount(discountRequest);
+ DiscountResponse discount = getProfilePort().getCustomerDiscount(discountRequest);
boolean hasDiscount = discount.getDiscount() > 0.00;
log.info("High value customer ? " + hasDiscount);
try
{
- log.info(creditCard + " valid? " + response.get());
+ //log.info(creditCard + " valid? " + response.get());
+ log.info(creditCard + " valid? " + validCard);
}
catch (Exception e)
{
Modified: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/cc/CCVerification.java
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/cc/CCVerification.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/cc/CCVerification.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -34,6 +34,6 @@
@WebParam(name = "creditCardNumber", targetNamespace = "")
String creditCardNumber);
- Response<Boolean> verifyAsync(String creditCardNumber);
+ //Response<Boolean> verifyAsync(String creditCardNumber);
}
Modified: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/cc/CCVerificationBean.java
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/cc/CCVerificationBean.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/cc/CCVerificationBean.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -32,7 +32,7 @@
@Stateless
@WebService(endpointInterface = "org.jboss.test.ws.jaxws.samples.retail.cc.CCVerification", name = "CCVerification")
@WebContext(contextRoot = "/jaxws-samples-retail")
-@HandlerChain(file = "../jaxws-handler.xml")
+//@HandlerChain(file = "../jaxws-handler.xml")
public class CCVerificationBean implements CCVerification
{
Modified: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/profile/ProfileMgmtBean.java
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/profile/ProfileMgmtBean.java 2007-07-13 11:44:50 UTC (rev 3878)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/retail/profile/ProfileMgmtBean.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -30,7 +30,7 @@
@Stateless
@WebService(endpointInterface = "org.jboss.test.ws.jaxws.samples.retail.profile.ProfileMgmt", name = "ProfileMgmt", serviceName = "ProfileMgmtService")
@WebContext(contextRoot = "/jaxws-samples-retail")
-@HandlerChain(file = "../jaxws-handler.xml")
+//@HandlerChain(file = "../jaxws-handler.xml")
public class ProfileMgmtBean implements ProfileMgmt
{
Copied: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref (from rev 3873, branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref)
Deleted: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,81 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.samples.serviceref;
-
-import org.jboss.annotation.ejb.RemoteBinding;
-import org.jboss.logging.Logger;
-
-import javax.ejb.Remote;
-import javax.ejb.Stateless;
-import javax.naming.InitialContext;
-import javax.xml.ws.BindingProvider;
-import javax.xml.ws.Service;
-import javax.xml.ws.WebServiceException;
-import javax.xml.ws.soap.SOAPBinding;
-import java.rmi.RemoteException;
-import java.util.ArrayList;
-
-(a)Remote(EJBRemote.class)
-@RemoteBinding(jndiBinding = "/ejb/EJBClient")
-@Stateless
-
-public class EJBClient
-{
- // Provide logging
- private static Logger log = Logger.getLogger(EJBClient.class);
-
- public String echo(String inStr) throws RemoteException
- {
- log.info("echo: " + inStr);
-
- ArrayList ports = new ArrayList(2);
-
- try
- {
- InitialContext iniCtx = new InitialContext();
- ports.add((TestEndpoint)((Service)iniCtx.lookup("java:comp/env/service1")).getPort(TestEndpoint.class));
- ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/service2")).getTestEndpointPort());
- }
- catch (Exception ex)
- {
- throw new WebServiceException(ex);
- }
-
- for (int i = 0; i < ports.size(); i++)
- {
- TestEndpoint port = (TestEndpoint)ports.get(i);
-
- BindingProvider bp = (BindingProvider)port;
- boolean mtomEnabled = ((SOAPBinding)bp.getBinding()).isMTOMEnabled();
- boolean expectedSetting = (i==0) ? false : true;
-
- //if(mtomEnabled != expectedSetting)
- // throw new WebServiceException("MTOM settings (enabled="+expectedSetting+") not overridden through service-ref" );
-
- String outStr = port.echo(inStr);
- if (inStr.equals(outStr) == false)
- throw new WebServiceException("Invalid echo return: " + inStr);
- }
-
- return inStr;
- }
-}
Copied: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java (from rev 3873, branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java)
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java (rev 0)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,81 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import org.jboss.annotation.ejb.RemoteBinding;
+import org.jboss.logging.Logger;
+
+import javax.ejb.Remote;
+import javax.ejb.Stateless;
+import javax.naming.InitialContext;
+import javax.xml.ws.BindingProvider;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.soap.SOAPBinding;
+import java.rmi.RemoteException;
+import java.util.ArrayList;
+
+(a)Remote(EJBRemote.class)
+@RemoteBinding(jndiBinding = "/ejb/EJBClient")
+@Stateless
+
+public class EJBClient
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(EJBClient.class);
+
+ public String echo(String inStr) throws RemoteException
+ {
+ log.info("echo: " + inStr);
+
+ ArrayList ports = new ArrayList(2);
+
+ try
+ {
+ InitialContext iniCtx = new InitialContext();
+ ports.add((TestEndpoint)((Service)iniCtx.lookup("java:comp/env/service1")).getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/service2")).getTestEndpointPort());
+ }
+ catch (Exception ex)
+ {
+ throw new WebServiceException(ex);
+ }
+
+ for (int i = 0; i < ports.size(); i++)
+ {
+ TestEndpoint port = (TestEndpoint)ports.get(i);
+
+ BindingProvider bp = (BindingProvider)port;
+ boolean mtomEnabled = ((SOAPBinding)bp.getBinding()).isMTOMEnabled();
+ boolean expectedSetting = (i==0) ? false : true;
+
+ //if(mtomEnabled != expectedSetting)
+ // throw new WebServiceException("MTOM settings (enabled="+expectedSetting+") not overridden through service-ref" );
+
+ String outStr = port.echo(inStr);
+ if (inStr.equals(outStr) == false)
+ throw new WebServiceException("Invalid echo return: " + inStr);
+ }
+
+ return inStr;
+ }
+}
Deleted: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,28 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.samples.serviceref;
-
-
-public interface EJBRemote
-{
- String echo(String input);
-}
Copied: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java (from rev 3873, branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java)
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java (rev 0)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,28 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+
+public interface EJBRemote
+{
+ String echo(String input);
+}
Deleted: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,91 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.samples.serviceref;
-
-import junit.framework.Test;
-import org.jboss.wsf.spi.test.JBossWSTest;
-import org.jboss.wsf.spi.test.JBossWSTestSetup;
-
-import javax.naming.InitialContext;
-import javax.xml.namespace.QName;
-import javax.xml.ws.BindingProvider;
-import javax.xml.ws.Service;
-import java.io.File;
-import java.io.InputStream;
-import java.net.URL;
-
-/**
- * Test the JAXWS <service-ref>
- *
- * @author Thomas.Diesler(a)jboss.com
- * @since 123-Mar-2007
- */
-public class ServiceRefClientTestCase extends JBossWSTest
-{
- public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-serviceref";
-
- public static Test suite()
- {
- return new JBossWSTestSetup(ServiceRefClientTestCase.class, "jaxws-serviceref.war, jaxws-serviceref-client.jar");
- }
-
- public void testWSDLAccess() throws Exception
- {
- URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
- InputStream inputStream = wsdlURL.openStream();
- assertNotNull(inputStream);
- inputStream.close();
- }
-
- public void testDynamicProxy() throws Exception
- {
- URL wsdlURL = new File("resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl").toURL();
- QName qname = new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService");
- Service service = Service.create(wsdlURL, qname);
- TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
-
- String request = "testDynamicProxy";
- String response = port.echo(request);
- assertEquals(request, response);
- }
-
- public void testApplicationClient() throws Exception
- {
- InitialContext iniCtx = getInitialContext("jbossws-client");
- Service service = (Service) iniCtx.lookup("java:comp/env/service2");
- TestEndpoint port = service.getPort(TestEndpoint.class);
- assertNotNull(port);
-
- BindingProvider bp = (BindingProvider)port;
-
- System.out.println("FIXME [JBWS-1736]: MTOM property at service-ref level");
-
- //boolean mtomEnabled = ((SOAPBinding)bp.getBinding()).isMTOMEnabled();
- //assertTrue("MTOM should be enabled on port", mtomEnabled);
-
- String request = "testApplicationClient";
- String response = port.echo(request);
- assertEquals(response, request);
-
- }
-
-}
Copied: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java (from rev 3873, branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java)
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java (rev 0)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,91 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import junit.framework.Test;
+import org.jboss.wsf.spi.test.JBossWSTest;
+import org.jboss.wsf.spi.test.JBossWSTestSetup;
+
+import javax.naming.InitialContext;
+import javax.xml.namespace.QName;
+import javax.xml.ws.BindingProvider;
+import javax.xml.ws.Service;
+import java.io.File;
+import java.io.InputStream;
+import java.net.URL;
+
+/**
+ * Test the JAXWS <service-ref>
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 123-Mar-2007
+ */
+public class ServiceRefClientTestCase extends JBossWSTest
+{
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-serviceref";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(ServiceRefClientTestCase.class, "jaxws-serviceref.war, jaxws-serviceref-client.jar");
+ }
+
+ public void testWSDLAccess() throws Exception
+ {
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ InputStream inputStream = wsdlURL.openStream();
+ assertNotNull(inputStream);
+ inputStream.close();
+ }
+
+ public void testDynamicProxy() throws Exception
+ {
+ URL wsdlURL = new File("resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl").toURL();
+ QName qname = new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService");
+ Service service = Service.create(wsdlURL, qname);
+ TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
+
+ String request = "testDynamicProxy";
+ String response = port.echo(request);
+ assertEquals(request, response);
+ }
+
+ public void testApplicationClient() throws Exception
+ {
+ InitialContext iniCtx = getInitialContext("jbossws-client");
+ Service service = (Service) iniCtx.lookup("java:comp/env/service2");
+ TestEndpoint port = service.getPort(TestEndpoint.class);
+ assertNotNull(port);
+
+ BindingProvider bp = (BindingProvider)port;
+
+ System.out.println("FIXME [JBWS-1736]: MTOM property at service-ref level");
+
+ //boolean mtomEnabled = ((SOAPBinding)bp.getBinding()).isMTOMEnabled();
+ //assertTrue("MTOM should be enabled on port", mtomEnabled);
+
+ String request = "testApplicationClient";
+ String response = port.echo(request);
+ assertEquals(response, request);
+
+ }
+
+}
Deleted: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,82 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.samples.serviceref;
-
-import junit.framework.Test;
-import org.jboss.wsf.spi.test.JBossWSTest;
-import org.jboss.wsf.spi.test.JBossWSTestSetup;
-
-import javax.naming.InitialContext;
-import javax.xml.namespace.QName;
-import javax.xml.ws.Service;
-import java.io.File;
-import java.io.InputStream;
-import java.net.URL;
-
-/**
- * Test the JAXRPC <service-ref>
- *
- * @author Thomas.Diesler(a)jboss.com
- * @since 23-Oct-2005
- */
-public class ServiceRefEJBTestCase extends JBossWSTest
-{
- public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-serviceref";
-
- public static Test suite()
- {
- return new JBossWSTestSetup(ServiceRefEJBTestCase.class, "jaxws-serviceref.war, jaxws-serviceref-ejb-client.jar");
- }
-
- public void testWSDLAccess() throws Exception
- {
- URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
- InputStream inputStream = wsdlURL.openStream();
- assertNotNull(inputStream);
- inputStream.close();
- }
-
-
- public void testDynamicProxy() throws Exception
- {
- URL wsdlURL = new File("resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl").toURL();
- QName qname = new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService");
- Service service = Service.create(wsdlURL, qname);
- TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
-
- String helloWorld = "testDynamicProxy";
- Object retObj = port.echo(helloWorld);
- assertEquals(helloWorld, retObj);
- }
-
-
- public void testEJBClient() throws Exception
- {
- InitialContext iniCtx = getInitialContext();
- EJBRemote ejbRemote = (EJBRemote)iniCtx.lookup("/ejb/EJBClient");
-
- String helloWorld = "Hello World!";
- Object retObj = ejbRemote.echo(helloWorld);
- assertEquals(helloWorld, retObj);
-
- }
-}
Copied: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java (from rev 3873, branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java)
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java (rev 0)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,82 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import junit.framework.Test;
+import org.jboss.wsf.spi.test.JBossWSTest;
+import org.jboss.wsf.spi.test.JBossWSTestSetup;
+
+import javax.naming.InitialContext;
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import java.io.File;
+import java.io.InputStream;
+import java.net.URL;
+
+/**
+ * Test the JAXRPC <service-ref>
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 23-Oct-2005
+ */
+public class ServiceRefEJBTestCase extends JBossWSTest
+{
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-serviceref";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(ServiceRefEJBTestCase.class, "jaxws-serviceref.war, jaxws-serviceref-ejb-client.jar");
+ }
+
+ public void testWSDLAccess() throws Exception
+ {
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ InputStream inputStream = wsdlURL.openStream();
+ assertNotNull(inputStream);
+ inputStream.close();
+ }
+
+
+ public void testDynamicProxy() throws Exception
+ {
+ URL wsdlURL = new File("resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl").toURL();
+ QName qname = new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService");
+ Service service = Service.create(wsdlURL, qname);
+ TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
+
+ String helloWorld = "testDynamicProxy";
+ Object retObj = port.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+ }
+
+
+ public void testEJBClient() throws Exception
+ {
+ InitialContext iniCtx = getInitialContext();
+ EJBRemote ejbRemote = (EJBRemote)iniCtx.lookup("/ejb/EJBClient");
+
+ String helloWorld = "Hello World!";
+ Object retObj = ejbRemote.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+
+ }
+}
Deleted: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,78 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.samples.serviceref;
-
-import junit.framework.Test;
-import org.jboss.wsf.spi.test.JBossWSTest;
-import org.jboss.wsf.spi.test.JBossWSTestSetup;
-
-import javax.xml.namespace.QName;
-import javax.xml.ws.Service;
-import java.io.BufferedReader;
-import java.io.File;
-import java.io.InputStreamReader;
-import java.io.InputStream;
-import java.net.URL;
-
-/**
- * Test the jaxws <service-ref>
- *
- * @author Thomas.Diesler(a)jboss.com
- * @since 23-Oct-2005
- */
-public class ServiceRefServletTestCase extends JBossWSTest
-{
- public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-serviceref";
-
- public static Test suite()
- {
- return new JBossWSTestSetup(ServiceRefServletTestCase.class, "jaxws-serviceref.war, jaxws-serviceref-servlet-client.war");
- }
-
- public void testWSDLAccess() throws Exception
- {
- URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
- InputStream inputStream = wsdlURL.openStream();
- assertNotNull(inputStream);
- inputStream.close();
- }
-
- public void testDynamicProxy() throws Exception
- {
- URL wsdlURL = new File("resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl").toURL();
- QName qname = new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService");
- Service service = Service.create(wsdlURL, qname);
- TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
-
- String helloWorld = "Hello World!";
- Object retObj = port.echo(helloWorld);
- assertEquals(helloWorld, retObj);
- }
-
- public void testServletClient() throws Exception
- {
- URL url = new URL(TARGET_ENDPOINT_ADDRESS + "-servlet-client?echo=HelloWorld");
- BufferedReader br = new BufferedReader(new InputStreamReader(url.openStream()));
- String retStr = br.readLine();
- assertEquals("HelloWorld", retStr);
- }
-}
Copied: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java (from rev 3873, branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java)
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java (rev 0)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,78 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import junit.framework.Test;
+import org.jboss.wsf.spi.test.JBossWSTest;
+import org.jboss.wsf.spi.test.JBossWSTestSetup;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.InputStreamReader;
+import java.io.InputStream;
+import java.net.URL;
+
+/**
+ * Test the jaxws <service-ref>
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 23-Oct-2005
+ */
+public class ServiceRefServletTestCase extends JBossWSTest
+{
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-serviceref";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(ServiceRefServletTestCase.class, "jaxws-serviceref.war, jaxws-serviceref-servlet-client.war");
+ }
+
+ public void testWSDLAccess() throws Exception
+ {
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ InputStream inputStream = wsdlURL.openStream();
+ assertNotNull(inputStream);
+ inputStream.close();
+ }
+
+ public void testDynamicProxy() throws Exception
+ {
+ URL wsdlURL = new File("resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl").toURL();
+ QName qname = new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService");
+ Service service = Service.create(wsdlURL, qname);
+ TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
+
+ String helloWorld = "Hello World!";
+ Object retObj = port.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+ }
+
+ public void testServletClient() throws Exception
+ {
+ URL url = new URL(TARGET_ENDPOINT_ADDRESS + "-servlet-client?echo=HelloWorld");
+ BufferedReader br = new BufferedReader(new InputStreamReader(url.openStream()));
+ String retStr = br.readLine();
+ assertEquals("HelloWorld", retStr);
+ }
+}
Deleted: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,80 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.samples.serviceref;
-
-import java.io.IOException;
-import java.util.ArrayList;
-
-import javax.naming.InitialContext;
-import javax.servlet.ServletException;
-import javax.servlet.http.HttpServlet;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-import javax.xml.ws.Service;
-import javax.xml.ws.WebServiceException;
-import javax.xml.ws.BindingProvider;
-import javax.xml.ws.soap.SOAPBinding;
-
-import org.jboss.logging.Logger;
-
-public class ServletClient extends HttpServlet
-{
- // Provide logging
- private static Logger log = Logger.getLogger(ServletClient.class);
-
- protected void doGet(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException
- {
- String inStr = req.getParameter("echo");
- log.info("doGet: " + inStr);
-
- ArrayList ports = new ArrayList();
- try
- {
- InitialContext iniCtx = new InitialContext();
- ports.add((TestEndpoint)((Service)iniCtx.lookup("java:comp/env/service1")).getPort(TestEndpoint.class));
- ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/service2")).getTestEndpointPort());
- }
- catch (Exception ex)
- {
- log.error("Cannot add port", ex);
- throw new WebServiceException(ex);
- }
-
- for (int i = 0; i < ports.size(); i++)
- {
- TestEndpoint port = (TestEndpoint)ports.get(i);
-
- BindingProvider bp = (BindingProvider)port;
- boolean mtomEnabled = ((SOAPBinding)bp.getBinding()).isMTOMEnabled();
- boolean expectedSetting = (i==0) ? false : true;
-
- //if(mtomEnabled != expectedSetting)
- // throw new WebServiceException("MTOM settings (enabled="+expectedSetting+") not overridden through service-ref" );
-
- String outStr = port.echo(inStr);
- if (inStr.equals(outStr) == false)
- throw new WebServiceException("Invalid echo return: " + inStr);
- }
-
- res.getWriter().print(inStr);
- }
-}
Copied: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java (from rev 3873, branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java)
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java (rev 0)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,80 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import java.io.IOException;
+import java.util.ArrayList;
+
+import javax.naming.InitialContext;
+import javax.servlet.ServletException;
+import javax.servlet.http.HttpServlet;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.BindingProvider;
+import javax.xml.ws.soap.SOAPBinding;
+
+import org.jboss.logging.Logger;
+
+public class ServletClient extends HttpServlet
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(ServletClient.class);
+
+ protected void doGet(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException
+ {
+ String inStr = req.getParameter("echo");
+ log.info("doGet: " + inStr);
+
+ ArrayList ports = new ArrayList();
+ try
+ {
+ InitialContext iniCtx = new InitialContext();
+ ports.add((TestEndpoint)((Service)iniCtx.lookup("java:comp/env/service1")).getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/service2")).getTestEndpointPort());
+ }
+ catch (Exception ex)
+ {
+ log.error("Cannot add port", ex);
+ throw new WebServiceException(ex);
+ }
+
+ for (int i = 0; i < ports.size(); i++)
+ {
+ TestEndpoint port = (TestEndpoint)ports.get(i);
+
+ BindingProvider bp = (BindingProvider)port;
+ boolean mtomEnabled = ((SOAPBinding)bp.getBinding()).isMTOMEnabled();
+ boolean expectedSetting = (i==0) ? false : true;
+
+ //if(mtomEnabled != expectedSetting)
+ // throw new WebServiceException("MTOM settings (enabled="+expectedSetting+") not overridden through service-ref" );
+
+ String outStr = port.echo(inStr);
+ if (inStr.equals(outStr) == false)
+ throw new WebServiceException("Invalid echo return: " + inStr);
+ }
+
+ res.getWriter().print(inStr);
+ }
+}
Deleted: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,40 +0,0 @@
-
-package org.jboss.test.ws.jaxws.samples.serviceref;
-
-import javax.jws.WebMethod;
-import javax.jws.WebParam;
-import javax.jws.WebResult;
-import javax.jws.WebService;
-import javax.jws.soap.SOAPBinding;
-
-
-/**
- * JBossWS Generated Source
- *
- * Generation Date: Mon Mar 12 15:09:39 CET 2007
- *
- * This generated source code represents a derivative work of the input to
- * the generator that produced it. Consult the input for the copyright and
- * terms of use that apply to this source code.
- *
- * JAX-WS Version: 2.0
- *
- */
-@WebService(name = "TestEndpoint", targetNamespace = "http://serviceref.samples.jaxws.ws.test.jboss.org/")
-@SOAPBinding(style = SOAPBinding.Style.RPC)
-public interface TestEndpoint {
-
-
- /**
- *
- * @param arg0
- * @return
- * returns java.lang.String
- */
- @WebMethod
- @WebResult(partName = "return")
- public String echo(
- @WebParam(name = "arg0", partName = "arg0")
- String arg0);
-
-}
Copied: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java (from rev 3873, branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java)
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java (rev 0)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,40 @@
+
+package org.jboss.test.ws.jaxws.samples.serviceref;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebResult;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+
+/**
+ * JBossWS Generated Source
+ *
+ * Generation Date: Mon Mar 12 15:09:39 CET 2007
+ *
+ * This generated source code represents a derivative work of the input to
+ * the generator that produced it. Consult the input for the copyright and
+ * terms of use that apply to this source code.
+ *
+ * JAX-WS Version: 2.0
+ *
+ */
+@WebService(name = "TestEndpoint", targetNamespace = "http://serviceref.samples.jaxws.ws.test.jboss.org/")
+@SOAPBinding(style = SOAPBinding.Style.RPC)
+public interface TestEndpoint {
+
+
+ /**
+ *
+ * @param arg0
+ * @return
+ * returns java.lang.String
+ */
+ @WebMethod
+ @WebResult(partName = "return")
+ public String echo(
+ @WebParam(name = "arg0", partName = "arg0")
+ String arg0);
+
+}
Deleted: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,50 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.samples.serviceref;
-
-import javax.jws.WebMethod;
-import javax.jws.WebService;
-import javax.jws.soap.SOAPBinding;
-
-import org.jboss.logging.Logger;
-
-/**
- * Test the jaxws <service-ref>
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 12-Mar-2007
- */
-
-@WebService (name = "TestEndpoint")
-@SOAPBinding(style = SOAPBinding.Style.RPC)
-public class TestEndpointImpl
-{
- // Provide logging
- private static Logger log = Logger.getLogger(TestEndpointImpl.class);
-
- @WebMethod
- public String echo(String input)
- {
- log.info(input);
- return input;
- }
-}
Copied: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java (from rev 3873, branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java)
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java (rev 0)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+import org.jboss.logging.Logger;
+
+/**
+ * Test the jaxws <service-ref>
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 12-Mar-2007
+ */
+
+@WebService (name = "TestEndpoint")
+@SOAPBinding(style = SOAPBinding.Style.RPC)
+public class TestEndpointImpl
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(TestEndpointImpl.class);
+
+ @WebMethod
+ public String echo(String input)
+ {
+ log.info(input);
+ return input;
+ }
+}
Deleted: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,59 +0,0 @@
-
-package org.jboss.test.ws.jaxws.samples.serviceref;
-
-import java.net.MalformedURLException;
-import java.net.URL;
-import javax.xml.namespace.QName;
-import javax.xml.ws.Service;
-import javax.xml.ws.WebEndpoint;
-import javax.xml.ws.WebServiceClient;
-
-
-/**
- * JBossWS Generated Source
- *
- * Generation Date: Mon Mar 12 15:09:39 CET 2007
- *
- * This generated source code represents a derivative work of the input to
- * the generator that produced it. Consult the input for the copyright and
- * terms of use that apply to this source code.
- *
- * JAX-WS Version: 2.0
- *
- */
-@WebServiceClient(name = "TestEndpointService", targetNamespace = "http://serviceref.samples.jaxws.ws.test.jboss.org/", wsdlLocation = "http://tddell:8080/jaxws-serviceref?wsdl")
-public class TestEndpointService
- extends Service
-{
-
- private final static URL TESTENDPOINTSERVICE_WSDL_LOCATION;
-
- static {
- URL url = null;
- try {
- url = new URL("http://tddell:8080/jaxws-serviceref?wsdl");
- } catch (MalformedURLException e) {
- e.printStackTrace();
- }
- TESTENDPOINTSERVICE_WSDL_LOCATION = url;
- }
-
- public TestEndpointService(URL wsdlLocation, QName serviceName) {
- super(wsdlLocation, serviceName);
- }
-
- public TestEndpointService() {
- super(TESTENDPOINTSERVICE_WSDL_LOCATION, new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService"));
- }
-
- /**
- *
- * @return
- * returns TestEndpoint
- */
- @WebEndpoint(name = "TestEndpointPort")
- public TestEndpoint getTestEndpointPort() {
- return (TestEndpoint)super.getPort(new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointPort"), TestEndpoint.class);
- }
-
-}
Copied: trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java (from rev 3873, branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java)
===================================================================
--- trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java (rev 0)
+++ trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,59 @@
+
+package org.jboss.test.ws.jaxws.samples.serviceref;
+
+import java.net.MalformedURLException;
+import java.net.URL;
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebEndpoint;
+import javax.xml.ws.WebServiceClient;
+
+
+/**
+ * JBossWS Generated Source
+ *
+ * Generation Date: Mon Mar 12 15:09:39 CET 2007
+ *
+ * This generated source code represents a derivative work of the input to
+ * the generator that produced it. Consult the input for the copyright and
+ * terms of use that apply to this source code.
+ *
+ * JAX-WS Version: 2.0
+ *
+ */
+@WebServiceClient(name = "TestEndpointService", targetNamespace = "http://serviceref.samples.jaxws.ws.test.jboss.org/", wsdlLocation = "http://tddell:8080/jaxws-serviceref?wsdl")
+public class TestEndpointService
+ extends Service
+{
+
+ private final static URL TESTENDPOINTSERVICE_WSDL_LOCATION;
+
+ static {
+ URL url = null;
+ try {
+ url = new URL("http://tddell:8080/jaxws-serviceref?wsdl");
+ } catch (MalformedURLException e) {
+ e.printStackTrace();
+ }
+ TESTENDPOINTSERVICE_WSDL_LOCATION = url;
+ }
+
+ public TestEndpointService(URL wsdlLocation, QName serviceName) {
+ super(wsdlLocation, serviceName);
+ }
+
+ public TestEndpointService() {
+ super(TESTENDPOINTSERVICE_WSDL_LOCATION, new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService"));
+ }
+
+ /**
+ *
+ * @return
+ * returns TestEndpoint
+ */
+ @WebEndpoint(name = "TestEndpointPort")
+ public TestEndpoint getTestEndpointPort() {
+ return (TestEndpoint)super.getPort(new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointPort"), TestEndpoint.class);
+ }
+
+}
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref)
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF)
Deleted: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<application-client version="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/javaee/application-client_5.xsd">
-
- <display-name>jaxws simple tests</display-name>
-
- <service-ref>
- <service-ref-name>service1</service-ref-name>
- <service-interface>javax.xml.ws.Service</service-interface>
- <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
- <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
- </service-ref>
-
- <service-ref>
- <service-ref-name>service2</service-ref-name>
- <service-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointService</service-interface>
- <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
- <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
- <port-component-ref>
- <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
- <enable-mtom>true</enable-mtom>
- </port-component-ref>
- </service-ref>
-
-</application-client>
-
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml)
===================================================================
--- trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml (rev 0)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<application-client version="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/javaee/application-client_5.xsd">
+
+ <display-name>jaxws simple tests</display-name>
+
+ <service-ref>
+ <service-ref-name>service1</service-ref-name>
+ <service-interface>javax.xml.ws.Service</service-interface>
+ <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
+ </service-ref>
+
+ <service-ref>
+ <service-ref-name>service2</service-ref-name>
+ <service-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointService</service-interface>
+ <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
+ <enable-mtom>true</enable-mtom>
+ </port-component-ref>
+ </service-ref>
+
+</application-client>
+
Deleted: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<ejb-jar version="3.0"
- 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/javaee/ejb-jar_3_0.xsd">
-
- <enterprise-beans>
- <session>
- <ejb-name>EJBClient</ejb-name>
- <remote>org.jboss.test.ws.jaxws.samples.serviceref.EJBRemote</remote>
- <ejb-class>org.jboss.test.ws.jaxws.samples.serviceref.EJBClient</ejb-class>
- <session-type>Stateless</session-type>
- <transaction-type>Container</transaction-type>
-
- <service-ref>
- <service-ref-name>service1</service-ref-name>
- <service-interface>javax.xml.ws.Service</service-interface>
- <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
- <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
- </service-ref>
-
- <service-ref>
- <service-ref-name>service2</service-ref-name>
- <service-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointService</service-interface>
- <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
- <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
- <port-component-ref>
- <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
- <enable-mtom>true</enable-mtom>
- </port-component-ref>
- </service-ref>
-
- </session>
- </enterprise-beans>
-
-</ejb-jar>
-
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml)
===================================================================
--- trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml (rev 0)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<ejb-jar version="3.0"
+ 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/javaee/ejb-jar_3_0.xsd">
+
+ <enterprise-beans>
+ <session>
+ <ejb-name>EJBClient</ejb-name>
+ <remote>org.jboss.test.ws.jaxws.samples.serviceref.EJBRemote</remote>
+ <ejb-class>org.jboss.test.ws.jaxws.samples.serviceref.EJBClient</ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+
+ <service-ref>
+ <service-ref-name>service1</service-ref-name>
+ <service-interface>javax.xml.ws.Service</service-interface>
+ <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
+ </service-ref>
+
+ <service-ref>
+ <service-ref-name>service2</service-ref-name>
+ <service-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointService</service-interface>
+ <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
+ <enable-mtom>true</enable-mtom>
+ </port-component-ref>
+ </service-ref>
+
+ </session>
+ </enterprise-beans>
+
+</ejb-jar>
+
Deleted: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,37 +0,0 @@
-<?xml version='1.0' encoding='UTF-8'?><java-wsdl-mapping version='1.1' xmlns='http://java.sun.com/xml/ns/j2ee' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd'>
- <package-mapping>
- <package-type>org.jboss.test.ws.jaxrpc.serviceref</package-type>
- <namespaceURI>http://org.jboss.ws/wsref/types</namespaceURI>
- </package-mapping>
- <service-interface-mapping>
- <service-interface>org.jboss.test.ws.jaxrpc.serviceref.TestEndpointService</service-interface>
- <wsdl-service-name xmlns:serviceNS='http://org.jboss.ws/wsref'>serviceNS:TestEndpointService</wsdl-service-name>
- <port-mapping>
- <port-name>TestEndpointPort</port-name>
- <java-port-name>TestEndpointPort</java-port-name>
- </port-mapping>
- </service-interface-mapping>
- <service-endpoint-interface-mapping>
- <service-endpoint-interface>org.jboss.test.ws.jaxrpc.serviceref.TestEndpoint</service-endpoint-interface>
- <wsdl-port-type xmlns:portTypeNS='http://org.jboss.ws/wsref'>portTypeNS:TestEndpoint</wsdl-port-type>
- <wsdl-binding xmlns:bindingNS='http://org.jboss.ws/wsref'>bindingNS:TestEndpointBinding</wsdl-binding>
- <service-endpoint-method-mapping>
- <java-method-name>echo</java-method-name>
- <wsdl-operation>echo</wsdl-operation>
- <method-param-parts-mapping>
- <param-position>0</param-position>
- <param-type>java.lang.String</param-type>
- <wsdl-message-mapping>
- <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.ws/wsref'>wsdlMsgNS:TestEndpoint_echo</wsdl-message>
- <wsdl-message-part-name>String_1</wsdl-message-part-name>
- <parameter-mode>IN</parameter-mode>
- </wsdl-message-mapping>
- </method-param-parts-mapping>
- <wsdl-return-value-mapping>
- <method-return-value>java.lang.String</method-return-value>
- <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.ws/wsref'>wsdlMsgNS:TestEndpoint_echoResponse</wsdl-message>
- <wsdl-message-part-name>result</wsdl-message-part-name>
- </wsdl-return-value-mapping>
- </service-endpoint-method-mapping>
- </service-endpoint-interface-mapping>
-</java-wsdl-mapping>
\ No newline at end of file
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml)
===================================================================
--- trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml (rev 0)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,37 @@
+<?xml version='1.0' encoding='UTF-8'?><java-wsdl-mapping version='1.1' xmlns='http://java.sun.com/xml/ns/j2ee' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd'>
+ <package-mapping>
+ <package-type>org.jboss.test.ws.jaxrpc.serviceref</package-type>
+ <namespaceURI>http://org.jboss.ws/wsref/types</namespaceURI>
+ </package-mapping>
+ <service-interface-mapping>
+ <service-interface>org.jboss.test.ws.jaxrpc.serviceref.TestEndpointService</service-interface>
+ <wsdl-service-name xmlns:serviceNS='http://org.jboss.ws/wsref'>serviceNS:TestEndpointService</wsdl-service-name>
+ <port-mapping>
+ <port-name>TestEndpointPort</port-name>
+ <java-port-name>TestEndpointPort</java-port-name>
+ </port-mapping>
+ </service-interface-mapping>
+ <service-endpoint-interface-mapping>
+ <service-endpoint-interface>org.jboss.test.ws.jaxrpc.serviceref.TestEndpoint</service-endpoint-interface>
+ <wsdl-port-type xmlns:portTypeNS='http://org.jboss.ws/wsref'>portTypeNS:TestEndpoint</wsdl-port-type>
+ <wsdl-binding xmlns:bindingNS='http://org.jboss.ws/wsref'>bindingNS:TestEndpointBinding</wsdl-binding>
+ <service-endpoint-method-mapping>
+ <java-method-name>echo</java-method-name>
+ <wsdl-operation>echo</wsdl-operation>
+ <method-param-parts-mapping>
+ <param-position>0</param-position>
+ <param-type>java.lang.String</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.ws/wsref'>wsdlMsgNS:TestEndpoint_echo</wsdl-message>
+ <wsdl-message-part-name>String_1</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <wsdl-return-value-mapping>
+ <method-return-value>java.lang.String</method-return-value>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.ws/wsref'>wsdlMsgNS:TestEndpoint_echoResponse</wsdl-message>
+ <wsdl-message-part-name>result</wsdl-message-part-name>
+ </wsdl-return-value-mapping>
+ </service-endpoint-method-mapping>
+ </service-endpoint-interface-mapping>
+</java-wsdl-mapping>
\ No newline at end of file
Deleted: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,14 +0,0 @@
-<?xml version='1.0' encoding='UTF-8' ?>
-<!DOCTYPE jboss-client PUBLIC "-//JBoss//DTD Application Client 5.0//EN" "http://www.jboss.org/j2ee/dtd/jboss-client_5_0.dtd">
-
-<jboss-client>
- <jndi-name>jbossws-client</jndi-name>
-
- <!--service-ref>
- <service-ref-name>service2</service-ref-name>
- <port-component-ref>
- <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
- <port-qname>{http://serviceref.samples.jaxws.ws.test.jboss.org/}TestEndpointPort</port-qname>
- </port-component-ref>
- </service-ref-->
-</jboss-client>
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml)
===================================================================
--- trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml (rev 0)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,14 @@
+<?xml version='1.0' encoding='UTF-8' ?>
+<!DOCTYPE jboss-client PUBLIC "-//JBoss//DTD Application Client 5.0//EN" "http://www.jboss.org/j2ee/dtd/jboss-client_5_0.dtd">
+
+<jboss-client>
+ <jndi-name>jbossws-client</jndi-name>
+
+ <!--service-ref>
+ <service-ref-name>service2</service-ref-name>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
+ <port-qname>{http://serviceref.samples.jaxws.ws.test.jboss.org/}TestEndpointPort</port-qname>
+ </port-component-ref>
+ </service-ref-->
+</jboss-client>
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl)
Deleted: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,32 +0,0 @@
-<definitions name='TestEndpointService' targetNamespace='http://serviceref.samples.jaxws.ws.test.jboss.org/' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://serviceref.samples.jaxws.ws.test.jboss.org/' xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
- <types></types>
- <message name='TestEndpoint_echoResponse'>
- <part name='return' type='xsd:string'/>
- </message>
- <message name='TestEndpoint_echo'>
- <part name='arg0' type='xsd:string'/>
- </message>
- <portType name='TestEndpoint'>
- <operation name='echo' parameterOrder='arg0'>
- <input message='tns:TestEndpoint_echo'/>
- <output message='tns:TestEndpoint_echoResponse'/>
- </operation>
- </portType>
- <binding name='TestEndpointBinding' type='tns:TestEndpoint'>
- <soap:binding style='rpc' transport='http://schemas.xmlsoap.org/soap/http'/>
- <operation name='echo'>
- <soap:operation soapAction=''/>
- <input>
- <soap:body namespace='http://serviceref.samples.jaxws.ws.test.jboss.org/' use='literal'/>
- </input>
- <output>
- <soap:body namespace='http://serviceref.samples.jaxws.ws.test.jboss.org/' use='literal'/>
- </output>
- </operation>
- </binding>
- <service name='TestEndpointService'>
- <port binding='tns:TestEndpointBinding' name='TestEndpointPort'>
- <soap:address location='http://@jboss.bind.address@:8080/jaxws-serviceref'/>
- </port>
- </service>
-</definitions>
\ No newline at end of file
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl)
===================================================================
--- trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl (rev 0)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,32 @@
+<definitions name='TestEndpointService' targetNamespace='http://serviceref.samples.jaxws.ws.test.jboss.org/' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://serviceref.samples.jaxws.ws.test.jboss.org/' xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
+ <types></types>
+ <message name='TestEndpoint_echoResponse'>
+ <part name='return' type='xsd:string'/>
+ </message>
+ <message name='TestEndpoint_echo'>
+ <part name='arg0' type='xsd:string'/>
+ </message>
+ <portType name='TestEndpoint'>
+ <operation name='echo' parameterOrder='arg0'>
+ <input message='tns:TestEndpoint_echo'/>
+ <output message='tns:TestEndpoint_echoResponse'/>
+ </operation>
+ </portType>
+ <binding name='TestEndpointBinding' type='tns:TestEndpoint'>
+ <soap:binding style='rpc' transport='http://schemas.xmlsoap.org/soap/http'/>
+ <operation name='echo'>
+ <soap:operation soapAction=''/>
+ <input>
+ <soap:body namespace='http://serviceref.samples.jaxws.ws.test.jboss.org/' use='literal'/>
+ </input>
+ <output>
+ <soap:body namespace='http://serviceref.samples.jaxws.ws.test.jboss.org/' use='literal'/>
+ </output>
+ </operation>
+ </binding>
+ <service name='TestEndpointService'>
+ <port binding='tns:TestEndpointBinding' name='TestEndpointPort'>
+ <soap:address location='http://@jboss.bind.address@:8080/jaxws-serviceref'/>
+ </port>
+ </service>
+</definitions>
\ No newline at end of file
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF)
Deleted: trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
-
- <servlet>
- <servlet-name>TestEndpoint</servlet-name>
- <servlet-class>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointImpl</servlet-class>
- </servlet>
-
- <servlet-mapping>
- <servlet-name>TestEndpoint</servlet-name>
- <url-pattern>/*</url-pattern>
- </servlet-mapping>
-</web-app>
\ No newline at end of file
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml)
===================================================================
--- trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml (rev 0)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
+
+ <servlet>
+ <servlet-name>TestEndpoint</servlet-name>
+ <servlet-class>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointImpl</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>TestEndpoint</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+</web-app>
\ No newline at end of file
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client)
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF)
Deleted: trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml 2007-07-13 10:05:26 UTC (rev 3873)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" 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>ServletClient</servlet-name>
- <servlet-class>org.jboss.test.ws.jaxws.samples.serviceref.ServletClient</servlet-class>
- </servlet>
-
- <servlet-mapping>
- <servlet-name>ServletClient</servlet-name>
- <url-pattern>/*</url-pattern>
- </servlet-mapping>
-
- <service-ref>
- <service-ref-name>service1</service-ref-name>
- <service-interface>javax.xml.ws.Service</service-interface>
- <wsdl-file>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
- <service-qname>{http://serviceref.samples.jaxws.ws.test.jboss.org/}TestEndpointService</service-qname>
- </service-ref>
-
- <service-ref>
- <service-ref-name>service2</service-ref-name>
- <service-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointService</service-interface>
- <wsdl-file>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
- <service-qname>{http://serviceref.samples.jaxws.ws.test.jboss.org/}TestEndpointService</service-qname>
- <port-component-ref>
- <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
- <enable-mtom>true</enable-mtom>
- </port-component-ref>
- </service-ref>
-
-</web-app>
\ No newline at end of file
Copied: trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml (from rev 3873, branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml)
===================================================================
--- trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml (rev 0)
+++ trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml 2007-07-13 11:55:00 UTC (rev 3879)
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" 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>ServletClient</servlet-name>
+ <servlet-class>org.jboss.test.ws.jaxws.samples.serviceref.ServletClient</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>ServletClient</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+
+ <service-ref>
+ <service-ref-name>service1</service-ref-name>
+ <service-interface>javax.xml.ws.Service</service-interface>
+ <wsdl-file>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname>{http://serviceref.samples.jaxws.ws.test.jboss.org/}TestEndpointService</service-qname>
+ </service-ref>
+
+ <service-ref>
+ <service-ref-name>service2</service-ref-name>
+ <service-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointService</service-interface>
+ <wsdl-file>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname>{http://serviceref.samples.jaxws.ws.test.jboss.org/}TestEndpointService</service-qname>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
+ <enable-mtom>true</enable-mtom>
+ </port-component-ref>
+ </service-ref>
+
+</web-app>
\ No newline at end of file
17 years, 6 months
JBossWS SVN: r3878 - branches/hbraun/trunk.
by jbossws-commits@lists.jboss.org
Author: heiko.braun(a)jboss.com
Date: 2007-07-13 07:44:50 -0400 (Fri, 13 Jul 2007)
New Revision: 3878
Added:
branches/hbraun/trunk/mergeinfo.txt
Log:
keep track of upstream merges
Added: branches/hbraun/trunk/mergeinfo.txt
===================================================================
--- branches/hbraun/trunk/mergeinfo.txt (rev 0)
+++ branches/hbraun/trunk/mergeinfo.txt 2007-07-13 11:44:50 UTC (rev 3878)
@@ -0,0 +1 @@
+ svn merge -r3849:3873 https://svn.jboss.org/repos/jbossws/branches/hbraun/trunk
Property changes on: branches/hbraun/trunk/mergeinfo.txt
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
17 years, 6 months
JBossWS SVN: r3877 - in branches/hbraun/trunk: testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client and 1 other directory.
by jbossws-commits@lists.jboss.org
Author: heiko.braun(a)jboss.com
Date: 2007-07-13 07:38:08 -0400 (Fri, 13 Jul 2007)
New Revision: 3877
Modified:
branches/hbraun/trunk/integration/sunri/src/test/resources/test-excludes.txt
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml
Log:
Fix serviceref test
Modified: branches/hbraun/trunk/integration/sunri/src/test/resources/test-excludes.txt
===================================================================
--- branches/hbraun/trunk/integration/sunri/src/test/resources/test-excludes.txt 2007-07-13 10:47:18 UTC (rev 3876)
+++ branches/hbraun/trunk/integration/sunri/src/test/resources/test-excludes.txt 2007-07-13 11:38:08 UTC (rev 3877)
@@ -18,5 +18,5 @@
org/jboss/test/ws/jaxws/samples/jaxr/**
# [JBWS-1674] Fix @WebServiceRef with SunRI
-#org/jboss/test/ws/jaxws/samples/retail/**
+org/jboss/test/ws/jaxws/samples/retail/**
org/jboss/test/ws/jaxws/samples/webserviceref/**
Modified: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml 2007-07-13 10:47:18 UTC (rev 3876)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml 2007-07-13 11:38:08 UTC (rev 3877)
@@ -18,7 +18,7 @@
-->
<service-ref>
<service-ref-name>service2</service-ref-name>
- <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
+ <service-qname>{http://org.jboss.ws/wsref}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -27,7 +27,7 @@
-->
<service-ref>
<service-ref-name>TestEndpointService3</service-ref-name>
- <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
+ <service-qname>{http://org.jboss.ws/wsref}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -36,7 +36,7 @@
-->
<service-ref>
<service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.ServletClient/service4</service-ref-name>
- <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
+ <service-qname>{http://org.jboss.ws/wsref}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -45,7 +45,7 @@
-->
<service-ref>
<service-ref-name>TestEndpointService5</service-ref-name>
- <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
+ <service-qname>{http://org.jboss.ws/wsref}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -54,7 +54,7 @@
-->
<service-ref>
<service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.ServletClient/service6</service-ref-name>
- <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
+ <service-qname>{http://org.jboss.ws/wsref}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -63,7 +63,7 @@
-->
<service-ref>
<service-ref-name>port1</service-ref-name>
- <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
+ <service-qname>{http://org.jboss.ws/wsref}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -72,7 +72,7 @@
-->
<service-ref>
<service-ref-name>Port2</service-ref-name>
- <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
+ <service-qname>{http://org.jboss.ws/wsref}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -81,7 +81,7 @@
-->
<service-ref>
<service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.ServletClient/port3</service-ref-name>
- <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
+ <service-qname>{http://org.jboss.ws/wsref}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
17 years, 6 months
JBossWS SVN: r3876 - in branches/hbraun/trunk: integration/xfire/src/test/resources and 1 other directories.
by jbossws-commits@lists.jboss.org
Author: heiko.braun(a)jboss.com
Date: 2007-07-13 06:47:18 -0400 (Fri, 13 Jul 2007)
New Revision: 3876
Modified:
branches/hbraun/trunk/integration/sunri/src/test/resources/test-excludes.txt
branches/hbraun/trunk/integration/xfire/src/test/resources/test-excludes.txt
branches/hbraun/trunk/jbossws-core/src/test/resources/test-excludes-jboss40.txt
branches/hbraun/trunk/jbossws-core/src/test/resources/test-excludes-jboss42.txt
Log:
Update exclude lists for Sun-RI and XFire to reflect service-ref changes
Modified: branches/hbraun/trunk/integration/sunri/src/test/resources/test-excludes.txt
===================================================================
--- branches/hbraun/trunk/integration/sunri/src/test/resources/test-excludes.txt 2007-07-13 10:42:45 UTC (rev 3875)
+++ branches/hbraun/trunk/integration/sunri/src/test/resources/test-excludes.txt 2007-07-13 10:47:18 UTC (rev 3876)
@@ -19,3 +19,4 @@
# [JBWS-1674] Fix @WebServiceRef with SunRI
#org/jboss/test/ws/jaxws/samples/retail/**
+org/jboss/test/ws/jaxws/samples/webserviceref/**
Modified: branches/hbraun/trunk/integration/xfire/src/test/resources/test-excludes.txt
===================================================================
--- branches/hbraun/trunk/integration/xfire/src/test/resources/test-excludes.txt 2007-07-13 10:42:45 UTC (rev 3875)
+++ branches/hbraun/trunk/integration/xfire/src/test/resources/test-excludes.txt 2007-07-13 10:47:18 UTC (rev 3876)
@@ -38,6 +38,9 @@
org/jboss/test/ws/jaxws/samples/retail/**
org/jboss/test/ws/jaxws/samples/webserviceref/**
+# ServiceRef Handling not yet implemented
+org/jboss/test/ws/jaxws/samples/serviceref/**
+
# [JBWS-1689] Add support for SwaRef
org/jboss/test/ws/jaxws/samples/swaref/**
Modified: branches/hbraun/trunk/jbossws-core/src/test/resources/test-excludes-jboss40.txt
===================================================================
--- branches/hbraun/trunk/jbossws-core/src/test/resources/test-excludes-jboss40.txt 2007-07-13 10:42:45 UTC (rev 3875)
+++ branches/hbraun/trunk/jbossws-core/src/test/resources/test-excludes-jboss40.txt 2007-07-13 10:47:18 UTC (rev 3876)
@@ -8,4 +8,4 @@
org/jboss/test/ws/jaxws/samples/handlerchain/HandlerChainClientTestCase*
org/jboss/test/ws/jaxws/samples/retail/**
org/jboss/test/ws/jaxws/samples/webserviceref/**
-org/jboss/test/ws/jaxws/serviceref/**
\ No newline at end of file
+org/jboss/test/ws/jaxws/samples/serviceref/**
\ No newline at end of file
Modified: branches/hbraun/trunk/jbossws-core/src/test/resources/test-excludes-jboss42.txt
===================================================================
--- branches/hbraun/trunk/jbossws-core/src/test/resources/test-excludes-jboss42.txt 2007-07-13 10:42:45 UTC (rev 3875)
+++ branches/hbraun/trunk/jbossws-core/src/test/resources/test-excludes-jboss42.txt 2007-07-13 10:47:18 UTC (rev 3876)
@@ -4,4 +4,4 @@
org/jboss/test/ws/jaxws/samples/handlerchain/HandlerChainClientTestCase*
org/jboss/test/ws/jaxws/samples/retail/**
org/jboss/test/ws/jaxws/samples/webserviceref/**
-#org/jboss/test/ws/jaxws/serviceref/**
+org/jboss/test/ws/jaxws/samples/serviceref/**
17 years, 6 months
JBossWS SVN: r3875 - in branches/hbraun/trunk/testsuite/src: resources/jaxws/samples/webserviceref/WEB-INF-client and 1 other directory.
by jbossws-commits@lists.jboss.org
Author: heiko.braun(a)jboss.com
Date: 2007-07-13 06:42:45 -0400 (Fri, 13 Jul 2007)
New Revision: 3875
Modified:
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/StubPropertyTestCase.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientTwo.java
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml
Log:
Remove dependencies on jbossws-native from webserviceref tests.
Modified: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/StubPropertyTestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/StubPropertyTestCase.java 2007-07-13 10:13:30 UTC (rev 3874)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/StubPropertyTestCase.java 2007-07-13 10:42:45 UTC (rev 3875)
@@ -23,6 +23,7 @@
import java.net.MalformedURLException;
import java.net.URL;
+import java.io.InputStream;
import javax.xml.namespace.QName;
import javax.xml.ws.BindingProvider;
@@ -31,8 +32,6 @@
import junit.framework.Test;
import org.jboss.ejb3.client.ClientLauncher;
-import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
-import org.jboss.ws.tools.wsdl.WSDLDefinitionsFactory;
import org.jboss.wsf.spi.test.JBossWSTest;
import org.jboss.wsf.spi.test.JBossWSTestSetup;
@@ -48,15 +47,17 @@
public static Test suite()
{
+ System.out.println("FIXME: Verif if stub properties may used across stacks, otherwise this test needs to be moved");
+
return new JBossWSTestSetup(StubPropertyTestCase.class, "jaxws-samples-webserviceref-secure.jar, jaxws-samples-webserviceref-secure-client.jar");
}
- public void testWSDLAccess() throws MalformedURLException
+ public void testWSDLAccess() throws Exception
{
URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
- WSDLDefinitionsFactory factory = WSDLDefinitionsFactory.newInstance();
- WSDLDefinitions wsdlDefinitions = factory.parse(wsdlURL);
- assertNotNull(wsdlDefinitions);
+ InputStream inputStream = wsdlURL.openStream();
+ assertNotNull(inputStream);
+ inputStream.close();
}
public void testDynamicProxy() throws Exception
Modified: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientTwo.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientTwo.java 2007-07-13 10:13:30 UTC (rev 3874)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientTwo.java 2007-07-13 10:42:45 UTC (rev 3875)
@@ -33,7 +33,7 @@
import javax.xml.ws.WebServiceRefs;
import org.jboss.logging.Logger;
-import org.jboss.ws.core.ConfigProvider;
+//import org.jboss.ws.core.ConfigProvider;
//Test on type
@WebServiceRef(name = "Service1")
@@ -103,7 +103,7 @@
Service service = (Service)iniCtx.lookup("java:comp/env/Service2");
TestEndpoint port = service.getPort(TestEndpoint.class);
- verifyConfig((ConfigProvider)port);
+ //verifyConfig((ConfigProvider)port);
return port.echo(reqStr);
}
@@ -131,11 +131,11 @@
{
TestEndpoint port = service4.getTestEndpointPort();
String resStr1 = port.echo(reqStr);
- verifyConfig((ConfigProvider)port);
+ //verifyConfig((ConfigProvider)port);
TestEndpointService service = (TestEndpointService)iniCtx.lookup("java:comp/env/Service4");
port = service.getTestEndpointPort();
- verifyConfig((ConfigProvider)port);
+ //verifyConfig((ConfigProvider)port);
String resStr2 = port.echo(reqStr);
@@ -148,7 +148,7 @@
public String testPort1(String reqStr) throws Exception
{
TestEndpoint port = (TestEndpoint)iniCtx.lookup("java:comp/env/Port1");
- verifyConfig((ConfigProvider)port);
+ //verifyConfig((ConfigProvider)port);
return port.echo(reqStr);
}
@@ -158,11 +158,11 @@
*/
public String testPort2(String reqStr) throws Exception
{
- verifyConfig((ConfigProvider)port2);
+ //verifyConfig((ConfigProvider)port2);
String resStr1 = port2.echo(reqStr);
TestEndpoint port = (TestEndpoint)iniCtx.lookup("java:comp/env/Port2");
- verifyConfig((ConfigProvider)port);
+ //verifyConfig((ConfigProvider)port);
String resStr2 = port.echo(reqStr);
@@ -196,12 +196,12 @@
throw new RuntimeException("Invalid password: " + password);
}
- private void verifyConfig(ConfigProvider cp)
+ /*private void verifyConfig(ConfigProvider cp)
{
if ("Custom Client".equals(cp.getConfigName()) == false)
throw new RuntimeException("Invalid config name: " + cp.getConfigName());
if ("META-INF/jbossws-client-config.xml".equals(cp.getConfigFile()) == false)
throw new RuntimeException("Invalid config file: " + cp.getConfigFile());
- }
+ } */
}
Modified: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml 2007-07-13 10:13:30 UTC (rev 3874)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml 2007-07-13 10:42:45 UTC (rev 3875)
@@ -18,6 +18,7 @@
-->
<service-ref>
<service-ref-name>service2</service-ref-name>
+ <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -26,6 +27,7 @@
-->
<service-ref>
<service-ref-name>TestEndpointService3</service-ref-name>
+ <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -34,6 +36,7 @@
-->
<service-ref>
<service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.ServletClient/service4</service-ref-name>
+ <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -42,6 +45,7 @@
-->
<service-ref>
<service-ref-name>TestEndpointService5</service-ref-name>
+ <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -50,6 +54,7 @@
-->
<service-ref>
<service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.ServletClient/service6</service-ref-name>
+ <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -58,6 +63,7 @@
-->
<service-ref>
<service-ref-name>port1</service-ref-name>
+ <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -66,6 +72,7 @@
-->
<service-ref>
<service-ref-name>Port2</service-ref-name>
+ <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
@@ -74,6 +81,7 @@
-->
<service-ref>
<service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.ServletClient/port3</service-ref-name>
+ <service-qname>{http://org.jboss.ws/wsref/}TestEndpointService</service-qname>
<wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
</service-ref>
17 years, 6 months
JBossWS SVN: r3874 - in branches/hbraun/trunk: jbossws-core/src/test/java/org/jboss/test/ws/jaxws/samples and 12 other directories.
by jbossws-commits@lists.jboss.org
Author: heiko.braun(a)jboss.com
Date: 2007-07-13 06:13:30 -0400 (Fri, 13 Jul 2007)
New Revision: 3874
Added:
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Client.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Remote.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpoint.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointClient.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointImpl.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointService.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/ServiceRefOverridesTestCase.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/ServletClient.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/StubPropertyTestCase.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientOne.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientTwo.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointImpl.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefClientTestCase.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefEJB3TestCase.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefServletTestCase.java
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/application-client.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/jboss-client.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/jbossws-client-config.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-secure/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-secure/application-client.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-secure/jboss-client.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/application-client.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/jboss-client.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/jboss.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/wsdl/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/wsdl/TestEndpoint.wsdl
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/web.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF/web.xml
Removed:
branches/hbraun/trunk/jbossws-core/src/test/java/org/jboss/test/ws/jaxws/samples/webserviceref/
branches/hbraun/trunk/jbossws-core/src/test/resources/jaxws/samples/webserviceref/
Modified:
branches/hbraun/trunk/jbossws-core/ant-import-tests/build-samples-jaxws.xml
branches/hbraun/trunk/testsuite/ant-import/build-jars-jaxws.xml
Log:
Move webserviceref samples to global test suite
Modified: branches/hbraun/trunk/jbossws-core/ant-import-tests/build-samples-jaxws.xml
===================================================================
--- branches/hbraun/trunk/jbossws-core/ant-import-tests/build-samples-jaxws.xml 2007-07-13 10:05:26 UTC (rev 3873)
+++ branches/hbraun/trunk/jbossws-core/ant-import-tests/build-samples-jaxws.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -18,95 +18,6 @@
<mkdir dir="${tests.output.dir}/libs"/>
- <!-- jaxws-webserviceref -->
- <war warfile="${tests.output.dir}/libs/jaxws-samples-webserviceref.war" webxml="${tests.output.dir}/resources/jaxws/samples/webserviceref/WEB-INF/web.xml">
- <classes dir="${tests.output.dir}/classes">
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointImpl.class"/>
- </classes>
- </war>
- <jar destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-client.jar">
- <fileset dir="${tests.output.dir}/classes">
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientOne.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.class"/>
- </fileset>
- <metainf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF">
- <include name="application-client.xml"/>
- <include name="jboss-client.xml"/>
- <include name="wsdl/**"/>
- </metainf>
- <manifest>
- <attribute name="main-class" value="org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpointClientOne"/>
- </manifest>
- </jar>
- <war destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-servlet-client.war"
- webxml="${tests.output.dir}/resources/jaxws/samples/webserviceref/WEB-INF-client/web.xml">
- <classes dir="${tests.output.dir}/classes">
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/ServletClient.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/EchoResponse.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/Echo.class"/>
- </classes>
- <webinf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF">
- <include name="wsdl/**"/>
- </webinf>
- <webinf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/WEB-INF-client">
- <include name="jboss-web.xml"/>
- </webinf>
- </war>
- <jar destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-ejb3-client.jar">
- <fileset dir="${tests.output.dir}/classes">
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Client.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Remote.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/EchoResponse.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/Echo.class"/>
- </fileset>
- <metainf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF">
- <include name="jboss.xml"/>
- <include name="wsdl/**"/>
- </metainf>
- </jar>
- <jar destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-secure.jar">
- <fileset dir="${tests.output.dir}/classes">
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointImpl.class"/>
- </fileset>
- </jar>
- <jar destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-secure-client.jar">
- <fileset dir="${tests.output.dir}/classes">
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointClient.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointService.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpoint.class"/>
- </fileset>
- <metainf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF-secure">
- <include name="application-client.xml"/>
- <include name="jboss-client.xml"/>
- </metainf>
- <manifest>
- <attribute name="main-class" value="org.jboss.test.ws.jaxws.samples.webserviceref.SecureEndpointClient"/>
- </manifest>
- </jar>
- <jar destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-override-client.jar">
- <fileset dir="${tests.output.dir}/classes">
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientTwo.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.class"/>
- <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.class"/>
- </fileset>
- <metainf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF-override">
- <include name="jbossws-client-config.xml"/>
- <include name="application-client.xml"/>
- <include name="jboss-client.xml"/>
- </metainf>
- <metainf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF">
- <include name="wsdl/**"/>
- </metainf>
- <manifest>
- <attribute name="main-class" value="org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpointClientTwo"/>
- </manifest>
- </jar>
-
<!-- jaxws-samples-wsaddressing -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-wsaddressing.war" webxml="${tests.output.dir}/resources/jaxws/samples/wsaddressing/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
Modified: branches/hbraun/trunk/testsuite/ant-import/build-jars-jaxws.xml
===================================================================
--- branches/hbraun/trunk/testsuite/ant-import/build-jars-jaxws.xml 2007-07-13 10:05:26 UTC (rev 3873)
+++ branches/hbraun/trunk/testsuite/ant-import/build-jars-jaxws.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -347,6 +347,95 @@
</fileset>
</jar>
+ <!-- jaxws-webserviceref -->
+ <war warfile="${tests.output.dir}/libs/jaxws-samples-webserviceref.war" webxml="${tests.output.dir}/resources/jaxws/samples/webserviceref/WEB-INF/web.xml">
+ <classes dir="${tests.output.dir}/classes">
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointImpl.class"/>
+ </classes>
+ </war>
+ <jar destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-client.jar">
+ <fileset dir="${tests.output.dir}/classes">
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientOne.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.class"/>
+ </fileset>
+ <metainf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF">
+ <include name="application-client.xml"/>
+ <include name="jboss-client.xml"/>
+ <include name="wsdl/**"/>
+ </metainf>
+ <manifest>
+ <attribute name="main-class" value="org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpointClientOne"/>
+ </manifest>
+ </jar>
+ <war destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-servlet-client.war"
+ webxml="${tests.output.dir}/resources/jaxws/samples/webserviceref/WEB-INF-client/web.xml">
+ <classes dir="${tests.output.dir}/classes">
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/ServletClient.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/EchoResponse.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/Echo.class"/>
+ </classes>
+ <webinf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF">
+ <include name="wsdl/**"/>
+ </webinf>
+ <webinf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/WEB-INF-client">
+ <include name="jboss-web.xml"/>
+ </webinf>
+ </war>
+ <jar destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-ejb3-client.jar">
+ <fileset dir="${tests.output.dir}/classes">
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Client.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Remote.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/EchoResponse.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/Echo.class"/>
+ </fileset>
+ <metainf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF">
+ <include name="jboss.xml"/>
+ <include name="wsdl/**"/>
+ </metainf>
+ </jar>
+ <jar destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-secure.jar">
+ <fileset dir="${tests.output.dir}/classes">
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointImpl.class"/>
+ </fileset>
+ </jar>
+ <jar destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-secure-client.jar">
+ <fileset dir="${tests.output.dir}/classes">
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointClient.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointService.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpoint.class"/>
+ </fileset>
+ <metainf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF-secure">
+ <include name="application-client.xml"/>
+ <include name="jboss-client.xml"/>
+ </metainf>
+ <manifest>
+ <attribute name="main-class" value="org.jboss.test.ws.jaxws.samples.webserviceref.SecureEndpointClient"/>
+ </manifest>
+ </jar>
+ <jar destfile="${tests.output.dir}/libs/jaxws-samples-webserviceref-override-client.jar">
+ <fileset dir="${tests.output.dir}/classes">
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientTwo.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.class"/>
+ <include name="org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.class"/>
+ </fileset>
+ <metainf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF-override">
+ <include name="jbossws-client-config.xml"/>
+ <include name="application-client.xml"/>
+ <include name="jboss-client.xml"/>
+ </metainf>
+ <metainf dir="${tests.output.dir}/resources/jaxws/samples/webserviceref/META-INF">
+ <include name="wsdl/**"/>
+ </metainf>
+ <manifest>
+ <attribute name="main-class" value="org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpointClientTwo"/>
+ </manifest>
+ </jar>
+
<!-- jaxws-samples-xop-doclit -->
<war jarfile="${tests.output.dir}/libs/jaxws-samples-xop-doclit.war" webxml="${tests.output.dir}/resources/jaxws/samples/xop/doclit/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Client.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Client.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Client.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,124 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import java.util.ArrayList;
+
+import javax.ejb.Remote;
+import javax.ejb.Stateless;
+import javax.naming.InitialContext;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.WebServiceRef;
+import javax.xml.ws.WebServiceRefs;
+
+import org.jboss.annotation.ejb.RemoteBinding;
+import org.jboss.logging.Logger;
+
+// standard EJB3 annotations
+(a)Remote(EJB3Remote.class)
+@RemoteBinding(jndiBinding = "/ejb3/EJB3Client")
+@Stateless
+
+// Test on type with wsdlLocation
+@WebServiceRef(name = "service1", value = TestEndpointService.class, wsdlLocation = "META-INF/wsdl/TestEndpoint.wsdl")
+
+// Test multiple on type
+@WebServiceRefs( {
+ @WebServiceRef(name = "service2", value = TestEndpointService.class),
+ @WebServiceRef(name = "port1", value = TestEndpointService.class, type = TestEndpoint.class) })
+public class EJB3Client implements EJB3Remote
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(EJB3Client.class);
+
+ // Test on field with name
+ @WebServiceRef(name = "TestEndpointService3")
+ public TestEndpointService service3;
+
+ // Test on field without name
+ @WebServiceRef
+ public TestEndpointService service4;
+
+ // Test on method with value
+ @WebServiceRef(name = "TestEndpointService5")
+ public void setService5(TestEndpointService service)
+ {
+ this.service5 = service;
+ }
+ private TestEndpointService service5;
+
+ // Test on method without name
+ @WebServiceRef
+ public void setService6(TestEndpointService service)
+ {
+ this.service6 = service;
+ }
+ private TestEndpointService service6;
+
+ // Test on field with name and value
+ @WebServiceRef(name = "Port2", value = TestEndpointService.class)
+ public TestEndpoint port2;
+
+ // Test on field with value
+ @WebServiceRef(value = TestEndpointService.class)
+ public TestEndpoint port3;
+
+ public String echo(String inStr)
+ {
+ log.info("echo: " + inStr);
+
+ ArrayList<TestEndpoint> ports = new ArrayList<TestEndpoint>();
+ try
+ {
+ InitialContext iniCtx = new InitialContext();
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp.ejb3/env/service1")).getTestEndpointPort());
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp.ejb3/env/service2")).getTestEndpointPort());
+ ports.add((TestEndpoint)service3.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp.ejb3/env/TestEndpointService3")).getTestEndpointPort());
+ ports.add((TestEndpoint)service4.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp.ejb3/env/" + getClass().getName() + "/service4")).getTestEndpointPort());
+ ports.add((TestEndpoint)service5.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp.ejb3/env/TestEndpointService5")).getTestEndpointPort());
+ ports.add((TestEndpoint)service6.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp.ejb3/env/" + getClass().getName() + "/service6")).getTestEndpointPort());
+ ports.add((TestEndpoint)iniCtx.lookup("java:comp.ejb3/env/port1"));
+ ports.add(port2);
+ ports.add((TestEndpoint)iniCtx.lookup("java:comp.ejb3/env/Port2"));
+ ports.add(port3);
+ ports.add((TestEndpoint)iniCtx.lookup("java:comp.ejb3/env/" + getClass().getName() + "/port3"));
+ }
+ catch (Exception ex)
+ {
+ log.error("Cannot add port", ex);
+ throw new WebServiceException(ex);
+ }
+
+ for (TestEndpoint port : ports)
+ {
+ String outStr = port.echo(inStr);
+ if (inStr.equals(outStr) == false)
+ throw new WebServiceException("Invalid echo return: " + inStr);
+ }
+
+ return inStr;
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Client.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Remote.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Remote.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Remote.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,27 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+public interface EJB3Remote
+{
+ String echo(String input);
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/EJB3Remote.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpoint.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpoint.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpoint.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,35 @@
+
+package org.jboss.test.ws.jaxws.samples.webserviceref;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebResult;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+import javax.jws.soap.SOAPBinding.Style;
+
+
+/**
+ * This class was generated by the JAXWS SI.
+ * JAX-WS RI 2.0-b26-ea3
+ * Generated source version: 2.0
+ *
+ */
+@WebService(name = "SecureEndpoint", targetNamespace = "http://org.jboss.ws/wsref", wsdlLocation = "http://localhost.localdomain:8080/jaxws-samples-webserviceref-secure/Secu...")
+@SOAPBinding(style = Style.RPC)
+public interface SecureEndpoint {
+
+
+ /**
+ *
+ * @param arg0
+ * @return
+ * returns java.lang.String
+ */
+ @WebMethod
+ @WebResult(targetNamespace = "http://org.jboss.ws/wsref", partName = "return")
+ public String echo(
+ @WebParam(name = "arg0", partName = "arg0")
+ String arg0);
+
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpoint.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointClient.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointClient.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointClient.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,82 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import javax.xml.ws.BindingProvider;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebServiceRef;
+
+import org.jboss.logging.Logger;
+
+public class SecureEndpointClient
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(SecureEndpointClient.class);
+
+ @WebServiceRef(name = "SecureService1")
+ static SecureEndpointService secureService1;
+
+ @WebServiceRef(name = "SecureService2")
+ static Service secureService2;
+
+ @WebServiceRef(name = "SecurePort1")
+ static SecureEndpoint securePort1;
+
+ static String retStr;
+
+ public static void main(String[] args)
+ {
+ String reqMsg = args[0];
+ log.info("echo: " + reqMsg);
+
+ String username = null;
+ if (args.length > 1)
+ username = args[1];
+
+ String password = null;
+ if (args.length > 2)
+ password = args[2];
+
+ SecureEndpoint port = secureService1.getSecureEndpointPort();
+ String retMsg = invokeEndpoint(port, reqMsg, username, password);
+
+ port = secureService2.getPort(SecureEndpoint.class);
+ retMsg += "|" + invokeEndpoint(port, reqMsg, username, password);
+
+ port = securePort1;
+ retMsg += "|" + invokeEndpoint(port, reqMsg, username, password);
+
+ retStr = retMsg;
+ }
+
+ private static String invokeEndpoint(SecureEndpoint port, String inStr, String username, String password)
+ {
+ if (username != null && password != null)
+ {
+ BindingProvider bindingProvider = (BindingProvider)port;
+ bindingProvider.getRequestContext().put(BindingProvider.USERNAME_PROPERTY, username);
+ bindingProvider.getRequestContext().put(BindingProvider.PASSWORD_PROPERTY, password);
+ }
+
+ return port.echo(inStr);
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointClient.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointImpl.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointImpl.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointImpl.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,53 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import javax.annotation.security.RolesAllowed;
+import javax.ejb.Stateless;
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+import javax.jws.soap.SOAPBinding.Style;
+
+import org.jboss.annotation.security.SecurityDomain;
+import org.jboss.logging.Logger;
+import org.jboss.wsf.spi.annotation.WebContext;
+
+@WebService(name = "SecureEndpoint", serviceName = "SecureEndpointService", targetNamespace = "http://org.jboss.ws/wsref")
+@Stateless(name = "SecureEndpoint")
+@SOAPBinding(style = Style.RPC)
+
+@WebContext(contextRoot="/jaxws-samples-webserviceref-secure", urlPattern="/*", authMethod = "BASIC", transportGuarantee = "NONE", secureWSDLAccess = false)
+@SecurityDomain("JBossWS")
+@RolesAllowed("friend")
+public class SecureEndpointImpl
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(SecureEndpointImpl.class);
+
+ @WebMethod
+ public String echo(String input)
+ {
+ log.info(input);
+ return input;
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointImpl.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointService.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointService.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointService.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,55 @@
+
+package org.jboss.test.ws.jaxws.samples.webserviceref;
+
+import java.net.MalformedURLException;
+import java.net.URL;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebEndpoint;
+import javax.xml.ws.WebServiceClient;
+
+/**
+ * This class was generated by the JAXWS SI.
+ * JAX-WS RI 2.0-b26-ea3
+ * Generated source version: 2.0
+ *
+ */
+@WebServiceClient(name = "SecureEndpointService", targetNamespace = "http://org.jboss.ws/wsref", wsdlLocation = "http://localhost.localdomain:8080/jaxws-samples-webserviceref-secure/Secu...")
+public class SecureEndpointService
+ extends Service
+{
+
+ private final static URL WSDL_LOCATION;
+ private final static QName SECUREENDPOINTSERVICE = new QName("http://org.jboss.ws/wsref", "SecureEndpointService");
+ private final static QName SECUREENDPOINTPORT = new QName("http://org.jboss.ws/wsref", "SecureEndpointPort");
+
+ static {
+ URL url = null;
+ try {
+ url = new URL("http://localhost.localdomain:8080/jaxws-samples-webserviceref-secure/Secu...");
+ } catch (MalformedURLException e) {
+ e.printStackTrace();
+ }
+ WSDL_LOCATION = url;
+ }
+
+ public SecureEndpointService(URL wsdlLocation, QName serviceName) {
+ super(wsdlLocation, serviceName);
+ }
+
+ public SecureEndpointService() {
+ super(WSDL_LOCATION, SECUREENDPOINTSERVICE);
+ }
+
+ /**
+ *
+ * @return
+ * returns SecureEndpoint
+ */
+ @WebEndpoint(name = "SecureEndpointPort")
+ public SecureEndpoint getSecureEndpointPort() {
+ return (SecureEndpoint)super.getPort(SECUREENDPOINTPORT, SecureEndpoint.class);
+ }
+
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/SecureEndpointService.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/ServiceRefOverridesTestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/ServiceRefOverridesTestCase.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/ServiceRefOverridesTestCase.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,100 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import junit.framework.Test;
+
+import org.jboss.ejb3.client.ClientLauncher;
+import org.jboss.wsf.spi.test.JBossWSTest;
+import org.jboss.wsf.spi.test.JBossWSTestSetup;
+
+/**
+ * Test @WebServiceRef overrides in jboss-client.xml
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 18-Jan-2007
+ */
+public class ServiceRefOverridesTestCase extends JBossWSTest
+{
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-samples-webserviceref";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(ServiceRefOverridesTestCase.class, "jaxws-samples-webserviceref.war, jaxws-samples-webserviceref-override-client.jar");
+ }
+
+ protected void setUp() throws Exception
+ {
+ super.setUp();
+
+ if (TestEndpointClientTwo.iniCtx == null)
+ TestEndpointClientTwo.iniCtx = getInitialContext();
+ }
+
+ public void testService1() throws Throwable
+ {
+ String resStr = invokeTest(getName());
+ assertEquals(getName(), resStr);
+ }
+
+ public void testService2() throws Throwable
+ {
+ String resStr = invokeTest(getName());
+ assertEquals(getName(), resStr);
+ }
+
+ public void testService3() throws Throwable
+ {
+ String resStr = invokeTest(getName());
+ assertEquals(getName() + getName(), resStr);
+ }
+
+ public void testService4() throws Throwable
+ {
+ String resStr = invokeTest(getName());
+ assertEquals(getName() + getName(), resStr);
+ }
+
+ public void testPort1() throws Throwable
+ {
+ String resStr = invokeTest(getName());
+ assertEquals(getName(), resStr);
+ }
+
+ public void testPort2() throws Throwable
+ {
+ String resStr = invokeTest(getName());
+ assertEquals(getName() + getName(), resStr);
+ }
+
+ public void testPort3() throws Throwable
+ {
+ String resStr = invokeTest(getName());
+ assertEquals(getName() + getName(), resStr);
+ }
+
+ private String invokeTest(String reqStr) throws Throwable
+ {
+ new ClientLauncher().launch(TestEndpointClientTwo.class.getName(), "jbossws-client", new String[] { reqStr });
+ return TestEndpointClientTwo.testResult.get(reqStr);
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/ServiceRefOverridesTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/ServletClient.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/ServletClient.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/ServletClient.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,123 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import java.io.IOException;
+import java.util.ArrayList;
+
+import javax.naming.InitialContext;
+import javax.servlet.ServletException;
+import javax.servlet.http.HttpServlet;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.WebServiceRef;
+import javax.xml.ws.WebServiceRefs;
+
+import org.jboss.logging.Logger;
+
+//Test on type with wsdlLocation
+@WebServiceRef(name = "service1", value = TestEndpointService.class, wsdlLocation = "WEB-INF/wsdl/TestEndpoint.wsdl")
+
+// Test multiple on type
+@WebServiceRefs( {
+ @WebServiceRef(name = "service2", value = TestEndpointService.class),
+ @WebServiceRef(name = "port1", value = TestEndpointService.class, type = TestEndpoint.class) })
+public class ServletClient extends HttpServlet
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(ServletClient.class);
+
+ // Test on field with name
+ @WebServiceRef(name = "TestEndpointService3")
+ public TestEndpointService service3;
+
+ // Test on field without name
+ @WebServiceRef
+ public TestEndpointService service4;
+
+ // Test on method with value
+ @WebServiceRef(name = "TestEndpointService5")
+ public void setService5(TestEndpointService service)
+ {
+ this.service5 = service;
+ }
+ private TestEndpointService service5;
+
+ // Test on method without name
+ @WebServiceRef
+ public void setService6(TestEndpointService service)
+ {
+ this.service6 = service;
+ }
+ private TestEndpointService service6;
+
+ // Test on field with name and value
+ @WebServiceRef(name = "Port2", value = TestEndpointService.class)
+ public TestEndpoint port2;
+
+ // Test on field with value
+ @WebServiceRef(value = TestEndpointService.class)
+ public TestEndpoint port3;
+
+ @Override
+ protected void doGet(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException
+ {
+ String inStr = req.getParameter("echo");
+ log.info("doGet: " + inStr);
+
+ ArrayList<TestEndpoint> ports = new ArrayList<TestEndpoint>();
+ try
+ {
+ InitialContext iniCtx = new InitialContext();
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/service1")).getTestEndpointPort());
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/service2")).getTestEndpointPort());
+ ports.add((TestEndpoint)service3.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/TestEndpointService3")).getTestEndpointPort());
+ ports.add((TestEndpoint)service4.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/" + getClass().getName() + "/service4")).getTestEndpointPort());
+ ports.add((TestEndpoint)service5.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/TestEndpointService5")).getTestEndpointPort());
+ ports.add((TestEndpoint)service6.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/" + getClass().getName() + "/service6")).getTestEndpointPort());
+ ports.add((TestEndpoint)iniCtx.lookup("java:comp/env/port1"));
+ ports.add(port2);
+ ports.add((TestEndpoint)iniCtx.lookup("java:comp/env/Port2"));
+ ports.add(port3);
+ ports.add((TestEndpoint)iniCtx.lookup("java:comp/env/" + getClass().getName() + "/port3"));
+ }
+ catch (Exception ex)
+ {
+ log.error("Cannot add port", ex);
+ throw new WebServiceException(ex);
+ }
+
+ for (TestEndpoint port : ports)
+ {
+ String outStr = port.echo(inStr);
+ if (inStr.equals(outStr) == false)
+ throw new WebServiceException("Invalid echo return: " + inStr);
+ }
+
+ res.getWriter().print(inStr);
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/ServletClient.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/StubPropertyTestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/StubPropertyTestCase.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/StubPropertyTestCase.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,91 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import java.net.MalformedURLException;
+import java.net.URL;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.BindingProvider;
+import javax.xml.ws.Service;
+
+import junit.framework.Test;
+
+import org.jboss.ejb3.client.ClientLauncher;
+import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
+import org.jboss.ws.tools.wsdl.WSDLDefinitionsFactory;
+import org.jboss.wsf.spi.test.JBossWSTest;
+import org.jboss.wsf.spi.test.JBossWSTestSetup;
+
+/**
+ * Test the JAXWS annotation: javax.xml.ws.WebServiceRef
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 23-Oct-2005
+ */
+public class StubPropertyTestCase extends JBossWSTest
+{
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-samples-webserviceref-secure";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(StubPropertyTestCase.class, "jaxws-samples-webserviceref-secure.jar, jaxws-samples-webserviceref-secure-client.jar");
+ }
+
+ public void testWSDLAccess() throws MalformedURLException
+ {
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ WSDLDefinitionsFactory factory = WSDLDefinitionsFactory.newInstance();
+ WSDLDefinitions wsdlDefinitions = factory.parse(wsdlURL);
+ assertNotNull(wsdlDefinitions);
+ }
+
+ public void testDynamicProxy() throws Exception
+ {
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ QName qname = new QName("http://org.jboss.ws/wsref", "SecureEndpointService");
+ Service service = Service.create(wsdlURL, qname);
+ SecureEndpoint port = (SecureEndpoint)service.getPort(SecureEndpoint.class);
+
+ BindingProvider bindingProvider = (BindingProvider)port;
+ bindingProvider.getRequestContext().put(BindingProvider.USERNAME_PROPERTY, "kermit");
+ bindingProvider.getRequestContext().put(BindingProvider.PASSWORD_PROPERTY, "thefrog");
+
+ String helloWorld = "Hello World";
+ Object retObj = port.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+ }
+
+ public void testUnconfiguredStub() throws Throwable
+ {
+ String reqMsg = "Hello World";
+ new ClientLauncher().launch(SecureEndpointClient.class.getName(), "jbossws-client", new String[] { reqMsg, "kermit", "thefrog" });
+ assertEquals("Hello World|Hello World|Hello World", SecureEndpointClient.retStr);
+ }
+
+ public void testConfiguredStub() throws Throwable
+ {
+ String reqMsg = "Hello World";
+ new ClientLauncher().launch(SecureEndpointClient.class.getName(), "jbossws-client", new String[] { reqMsg });
+ assertEquals("Hello World|Hello World|Hello World", SecureEndpointClient.retStr);
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/StubPropertyTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,35 @@
+
+package org.jboss.test.ws.jaxws.samples.webserviceref;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebResult;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+import javax.jws.soap.SOAPBinding.Style;
+
+
+/**
+ * This class was generated by the JAXWS SI.
+ * JAX-WS RI 2.0-b26-ea3
+ * Generated source version: 2.0
+ *
+ */
+@WebService(name = "TestEndpoint", targetNamespace = "http://org.jboss.ws/wsref", wsdlLocation = "http://localhost.localdomain:8080/jaxws-samples-webserviceref?wsdl")
+@SOAPBinding(style = Style.RPC)
+public interface TestEndpoint {
+
+
+ /**
+ *
+ * @param arg0
+ * @return
+ * returns java.lang.String
+ */
+ @WebMethod
+ @WebResult(targetNamespace = "http://org.jboss.ws/wsref", partName = "return")
+ public String echo(
+ @WebParam(name = "arg0", partName = "arg0")
+ String arg0);
+
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpoint.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientOne.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientOne.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientOne.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,129 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import java.util.ArrayList;
+
+import javax.naming.InitialContext;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.WebServiceRef;
+import javax.xml.ws.WebServiceRefs;
+
+import org.jboss.logging.Logger;
+
+// Test on type with wsdlLocation
+@WebServiceRef(name = "service1", value = TestEndpointService.class, wsdlLocation = "META-INF/wsdl/TestEndpoint.wsdl")
+
+// Test multiple on type
+@WebServiceRefs( {
+ @WebServiceRef(name = "service2", value = TestEndpointService.class),
+ @WebServiceRef(name = "port1", value = TestEndpointService.class, type = TestEndpoint.class) })
+public class TestEndpointClientOne
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(TestEndpointClientOne.class);
+
+ // Test on field with name
+ @WebServiceRef(name = "TestEndpointService3")
+ static TestEndpointService service3;
+
+ // Test on field without name
+ @WebServiceRef
+ static TestEndpointService service4;
+
+ // Test on method with name
+ @WebServiceRef(name = "TestEndpointService5")
+ static void setService5(TestEndpointService service)
+ {
+ TestEndpointClientOne.service5 = service;
+ }
+ private static TestEndpointService service5;
+
+ // Test on method without name
+ @WebServiceRef
+ static void setService6(TestEndpointService service)
+ {
+ TestEndpointClientOne.service6 = service;
+ }
+ private static TestEndpointService service6;
+
+ // Test on field with name and value
+ @WebServiceRef(name = "Port2", value = TestEndpointService.class)
+ static TestEndpoint port2;
+
+ // Test on field with value
+ @WebServiceRef(value = TestEndpointService.class)
+ static TestEndpoint port3;
+
+ // Test on field
+ @WebServiceRef
+ static TestEndpoint port4;
+
+ // Test on field with name
+ @WebServiceRef (name = "Port5")
+ static TestEndpoint port5;
+
+ static InitialContext iniCtx;
+ static String retStr;
+
+ public static void main(String[] args)
+ {
+ String inStr = args[0];
+ log.info("echo: " + inStr);
+
+ ArrayList<TestEndpoint> ports = new ArrayList<TestEndpoint>();
+ try
+ {
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/service1")).getTestEndpointPort());
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/service2")).getTestEndpointPort());
+ ports.add((TestEndpoint)service3.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/TestEndpointService3")).getTestEndpointPort());
+ ports.add((TestEndpoint)service4.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/" + TestEndpointClientOne.class.getName() + "/service4")).getTestEndpointPort());
+ ports.add((TestEndpoint)service5.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/TestEndpointService5")).getTestEndpointPort());
+ ports.add((TestEndpoint)service6.getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/" + TestEndpointClientOne.class.getName() + "/service6")).getTestEndpointPort());
+ ports.add((TestEndpoint)iniCtx.lookup("java:comp/env/port1"));
+ ports.add(port2);
+ ports.add((TestEndpoint)iniCtx.lookup("java:comp/env/Port2"));
+ ports.add(port3);
+ ports.add((TestEndpoint)iniCtx.lookup("java:comp/env/" + TestEndpointClientOne.class.getName() + "/port3"));
+ ports.add(port4);
+ ports.add(port5);
+ }
+ catch (Exception ex)
+ {
+ log.error("Cannot add port", ex);
+ throw new WebServiceException(ex);
+ }
+
+ for (TestEndpoint port : ports)
+ {
+ String outStr = port.echo(inStr);
+ if (inStr.equals(outStr) == false)
+ throw new WebServiceException("Invalid echo return: " + inStr);
+ }
+
+ retStr = inStr;
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientOne.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientTwo.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientTwo.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientTwo.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,207 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.naming.InitialContext;
+import javax.xml.ws.BindingProvider;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebServiceRef;
+import javax.xml.ws.WebServiceRefs;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.core.ConfigProvider;
+
+//Test on type
+@WebServiceRef(name = "Service1")
+// Test multiple on type
+@WebServiceRefs( { @WebServiceRef(name = "Service2"), @WebServiceRef(name = "Port1", type = TestEndpoint.class) })
+public class TestEndpointClientTwo
+{
+ // provide logging
+ private static final Logger log = Logger.getLogger(TestEndpointClientTwo.class);
+
+ // Test on field
+ @WebServiceRef(name = "Service3")
+ static Service service3;
+
+ // Test on field
+ @WebServiceRef(name = "Service4")
+ static TestEndpointService service4;
+
+ // Test on field
+ @WebServiceRef(name = "Port2")
+ static TestEndpoint port2;
+
+ // Test on field
+ @WebServiceRef(name = "Port3")
+ static TestEndpoint port3;
+
+ static InitialContext iniCtx;
+ static Map<String, String> testResult = new HashMap<String, String>();
+
+ public static void main(String[] args) throws Exception
+ {
+ String testName = args[0];
+ TestEndpointClientTwo client = new TestEndpointClientTwo();
+ Method method = TestEndpointClientTwo.class.getMethod(testName, new Class[] { String.class });
+ try
+ {
+ String retStr = (String)method.invoke(client, testName);
+ testResult.put(testName, retStr);
+ }
+ catch (InvocationTargetException ex)
+ {
+ log.error("Invocation error", ex);
+ testResult.put(testName, ex.getTargetException().toString());
+ }
+ catch (Exception ex)
+ {
+ log.error("Error", ex);
+ testResult.put(testName, ex.toString());
+ }
+ }
+
+ /**
+ * Customize service-class-name, service-qname
+ */
+ public String testService1(String reqStr) throws Exception
+ {
+ TestEndpointService service = (TestEndpointService)iniCtx.lookup("java:comp/env/Service1");
+ TestEndpoint port = service.getTestEndpointPort();
+ return port.echo(reqStr);
+ }
+
+ /**
+ * Customize config-name, config-file
+ */
+ public String testService2(String reqStr) throws Exception
+ {
+ Service service = (Service)iniCtx.lookup("java:comp/env/Service2");
+
+ TestEndpoint port = service.getPort(TestEndpoint.class);
+ verifyConfig((ConfigProvider)port);
+
+ return port.echo(reqStr);
+ }
+
+ /**
+ * Customize service-class-name, service-qname
+ */
+ public String testService3(String reqStr) throws Exception
+ {
+ TestEndpoint port = ((TestEndpointService)service3).getTestEndpointPort();
+ String resStr1 = port.echo(reqStr);
+
+ TestEndpointService service = (TestEndpointService)iniCtx.lookup("java:comp/env/Service3");
+ port = service.getTestEndpointPort();
+
+ String resStr2 = port.echo(reqStr);
+
+ return resStr1 + resStr2;
+ }
+
+ /**
+ * Customize config-name, config-file
+ */
+ public String testService4(String reqStr) throws Exception
+ {
+ TestEndpoint port = service4.getTestEndpointPort();
+ String resStr1 = port.echo(reqStr);
+ verifyConfig((ConfigProvider)port);
+
+ TestEndpointService service = (TestEndpointService)iniCtx.lookup("java:comp/env/Service4");
+ port = service.getTestEndpointPort();
+ verifyConfig((ConfigProvider)port);
+
+ String resStr2 = port.echo(reqStr);
+
+ return resStr1 + resStr2;
+ }
+
+ /**
+ * Customize port-info: port-qname, config-name, config-file
+ */
+ public String testPort1(String reqStr) throws Exception
+ {
+ TestEndpoint port = (TestEndpoint)iniCtx.lookup("java:comp/env/Port1");
+ verifyConfig((ConfigProvider)port);
+
+ return port.echo(reqStr);
+ }
+
+ /**
+ * Customize port-info: service-endpoint-interface, config-name, config-file
+ */
+ public String testPort2(String reqStr) throws Exception
+ {
+ verifyConfig((ConfigProvider)port2);
+ String resStr1 = port2.echo(reqStr);
+
+ TestEndpoint port = (TestEndpoint)iniCtx.lookup("java:comp/env/Port2");
+ verifyConfig((ConfigProvider)port);
+
+ String resStr2 = port.echo(reqStr);
+
+ return resStr1 + resStr2;
+ }
+
+ /**
+ * Customize port-info: service-endpoint-interface, port-qname, stub-property
+ */
+ public String testPort3(String reqStr) throws Exception
+ {
+ String resStr1 = port3.echo(reqStr);
+
+ BindingProvider bp = (BindingProvider)port3;
+ verifyProperties(bp.getRequestContext());
+
+ TestEndpoint port = (TestEndpoint)iniCtx.lookup("java:comp/env/Port3");
+ String resStr2 = port.echo(reqStr);
+
+ return resStr1 + resStr2;
+ }
+
+ private void verifyProperties(Map<String, Object> ctx)
+ {
+ String username = (String)ctx.get(BindingProvider.USERNAME_PROPERTY);
+ if ("kermit".equals(username) == false)
+ throw new RuntimeException("Invalid username: " + username);
+
+ String password = (String)ctx.get(BindingProvider.PASSWORD_PROPERTY);
+ if ("thefrog".equals(password) == false)
+ throw new RuntimeException("Invalid password: " + password);
+ }
+
+ private void verifyConfig(ConfigProvider cp)
+ {
+ if ("Custom Client".equals(cp.getConfigName()) == false)
+ throw new RuntimeException("Invalid config name: " + cp.getConfigName());
+
+ if ("META-INF/jbossws-client-config.xml".equals(cp.getConfigFile()) == false)
+ throw new RuntimeException("Invalid config file: " + cp.getConfigFile());
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointClientTwo.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointImpl.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointImpl.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointImpl.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,44 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+import javax.jws.soap.SOAPBinding.Style;
+
+import org.jboss.logging.Logger;
+
+@WebService(name = "TestEndpoint", serviceName = "TestEndpointService", targetNamespace = "http://org.jboss.ws/wsref")
+@SOAPBinding(style = Style.RPC)
+public class TestEndpointImpl
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(TestEndpointImpl.class);
+
+ @WebMethod
+ public String echo(String input)
+ {
+ log.info(input);
+ return input;
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointImpl.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,55 @@
+
+package org.jboss.test.ws.jaxws.samples.webserviceref;
+
+import java.net.MalformedURLException;
+import java.net.URL;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebEndpoint;
+import javax.xml.ws.WebServiceClient;
+
+/**
+ * This class was generated by the JAXWS SI.
+ * JAX-WS RI 2.0-b26-ea3
+ * Generated source version: 2.0
+ *
+ */
+@WebServiceClient(name = "TestEndpointService", targetNamespace = "http://org.jboss.ws/wsref", wsdlLocation = "file://bogus-location/jaxws-samples-webserviceref?wsdl")
+public class TestEndpointService
+ extends Service
+{
+
+ private final static URL WSDL_LOCATION;
+ private final static QName TESTENDPOINTSERVICE = new QName("http://org.jboss.ws/wsref", "TestEndpointService");
+ private final static QName TESTENDPOINTPORT = new QName("http://org.jboss.ws/wsref", "TestEndpointPort");
+
+ static {
+ URL url = null;
+ try {
+ url = new URL("file://bogus-location/jaxws-samples-webserviceref?wsdl");
+ } catch (MalformedURLException e) {
+ e.printStackTrace();
+ }
+ WSDL_LOCATION = url;
+ }
+
+ public TestEndpointService(URL wsdlLocation, QName serviceName) {
+ super(wsdlLocation, serviceName);
+ }
+
+ public TestEndpointService() {
+ super(WSDL_LOCATION, TESTENDPOINTSERVICE);
+ }
+
+ /**
+ *
+ * @return
+ * returns TestEndpoint
+ */
+ @WebEndpoint(name = "TestEndpointPort")
+ public TestEndpoint getTestEndpointPort() {
+ return (TestEndpoint)super.getPort(TESTENDPOINTPORT, TestEndpoint.class);
+ }
+
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/TestEndpointService.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefClientTestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefClientTestCase.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefClientTestCase.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,85 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import java.net.URL;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.BindingProvider;
+import javax.xml.ws.Service;
+
+import junit.framework.Test;
+
+import org.jboss.ejb3.client.ClientLauncher;
+import org.jboss.wsf.spi.test.JBossWSTest;
+import org.jboss.wsf.spi.test.JBossWSTestSetup;
+
+/**
+ * Test the JAXWS annotation: javax.xml.ws.WebServiceref
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 23-Oct-2005
+ */
+public class WebServiceRefClientTestCase extends JBossWSTest
+{
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-samples-webserviceref";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(WebServiceRefClientTestCase.class, "jaxws-samples-webserviceref.war, jaxws-samples-webserviceref-client.jar");
+ }
+
+ public void testGeneratedService() throws Exception
+ {
+ TestEndpointService service = new TestEndpointService();
+ TestEndpoint port = service.getTestEndpointPort();
+
+ // Set the target endpoint address, since the service could not be created from wsdl
+ BindingProvider provider = (BindingProvider)port;
+ provider.getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY, TARGET_ENDPOINT_ADDRESS);
+
+ String helloWorld = "Hello World!";
+ Object retObj = port.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+ }
+
+ public void testDynamicProxy() throws Exception
+ {
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ QName qname = new QName("http://org.jboss.ws/wsref", "TestEndpointService");
+ Service service = Service.create(wsdlURL, qname);
+ TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
+
+ String helloWorld = "Hello World!";
+ Object retObj = port.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+ }
+
+ public void testApplicationClient() throws Throwable
+ {
+ String helloWorld = "Hello World!";
+ TestEndpointClientOne.iniCtx = getInitialContext();
+
+ new ClientLauncher().launch(TestEndpointClientOne.class.getName(), "jbossws-client", new String[] { helloWorld });
+ assertEquals(helloWorld, TestEndpointClientOne.retStr);
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefClientTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefEJB3TestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefEJB3TestCase.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefEJB3TestCase.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,79 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import java.net.URL;
+
+import javax.naming.InitialContext;
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+
+import junit.framework.Test;
+
+import org.jboss.wsf.spi.test.JBossWSTest;
+import org.jboss.wsf.spi.test.JBossWSTestSetup;
+
+/**
+ * Test the JAXWS annotation: javax.xml.ws.WebServiceref
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 23-Oct-2005
+ */
+public class WebServiceRefEJB3TestCase extends JBossWSTest
+{
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-samples-webserviceref";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(WebServiceRefEJB3TestCase.class, "jaxws-samples-webserviceref.war");
+ }
+
+ public void testDynamicProxy() throws Exception
+ {
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ QName qname = new QName("http://org.jboss.ws/wsref", "TestEndpointService");
+ Service service = Service.create(wsdlURL, qname);
+ TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
+
+ String helloWorld = "Hello World!";
+ Object retObj = port.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+ }
+
+ public void testEJB3Client() throws Exception
+ {
+ deploy("jaxws-samples-webserviceref-ejb3-client.jar");
+ try
+ {
+ InitialContext iniCtx = getInitialContext();
+ EJB3Remote ejb3Remote = (EJB3Remote)iniCtx.lookup("/ejb3/EJB3Client");
+
+ String helloWorld = "Hello World!";
+ Object retObj = ejb3Remote.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+ }
+ finally
+ {
+ undeploy("jaxws-samples-webserviceref-ejb3-client.jar");
+ }
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefEJB3TestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefServletTestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefServletTestCase.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefServletTestCase.java 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,78 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.webserviceref;
+
+import java.io.BufferedReader;
+import java.io.InputStreamReader;
+import java.net.URL;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+
+import junit.framework.Test;
+
+import org.jboss.wsf.spi.test.JBossWSTest;
+import org.jboss.wsf.spi.test.JBossWSTestSetup;
+
+/**
+ * Test the JAXWS annotation: javax.xml.ws.WebServiceref
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 23-Oct-2005
+ */
+public class WebServiceRefServletTestCase extends JBossWSTest
+{
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-samples-webserviceref";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(WebServiceRefServletTestCase.class, "jaxws-samples-webserviceref.war");
+ }
+
+ public void testDynamicProxy() throws Exception
+ {
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ QName qname = new QName("http://org.jboss.ws/wsref", "TestEndpointService");
+ Service service = Service.create(wsdlURL, qname);
+ TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
+
+ String helloWorld = "Hello World!";
+ Object retObj = port.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+ }
+
+ public void testServletClient() throws Exception
+ {
+ deploy("jaxws-samples-webserviceref-servlet-client.war");
+ try
+ {
+ URL url = new URL(TARGET_ENDPOINT_ADDRESS + "-servlet-client?echo=HelloWorld");
+ BufferedReader br = new BufferedReader(new InputStreamReader(url.openStream()));
+ String retStr = br.readLine();
+ assertEquals("HelloWorld", retStr);
+ }
+ finally
+ {
+ undeploy("jaxws-samples-webserviceref-servlet-client.war");
+ }
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/webserviceref/WebServiceRefServletTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/application-client.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/application-client.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/application-client.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<application-client version="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/javaee/application-client_5.xsd">
+
+ <display-name>TestEndpointService</display-name>
+
+</application-client>
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/application-client.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/jboss-client.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/jboss-client.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/jboss-client.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,96 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE jboss-client PUBLIC "-//JBoss//DTD Application Client 5.0//EN" "http://www.jboss.org/j2ee/dtd/jboss-client_5_0.dtd">
+
+<jboss-client>
+ <jndi-name>jbossws-client</jndi-name>
+
+ <!--
+ @WebServiceRef(name = "service1", value = TestEndpointService.class, wsdlLocation = "META-INF/wsdl/TestEndpoint.wsdl")
+ <service-ref>
+ <service-ref-name>service1</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+ -->
+
+ <!--
+ @WebServiceRef(name = "service2", value = TestEndpointService.class)
+ -->
+ <service-ref>
+ <service-ref-name>service2</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "TestEndpointService3")
+ -->
+ <service-ref>
+ <service-ref-name>TestEndpointService3</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef
+ -->
+ <service-ref>
+ <service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpointClientOne/service4</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "TestEndpointService5")
+ -->
+ <service-ref>
+ <service-ref-name>TestEndpointService5</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef
+ -->
+ <service-ref>
+ <service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpointClientOne/service6</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "port1", value = TestEndpointService.class, type = TestEndpoint.class)
+ -->
+ <service-ref>
+ <service-ref-name>port1</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "Port2", value = TestEndpointService.class)
+ -->
+ <service-ref>
+ <service-ref-name>Port2</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(value = TestEndpointService.class)
+ -->
+ <service-ref>
+ <service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpointClientOne/port3</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef
+ -->
+ <service-ref>
+ <service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpointClientOne/port4</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "Port5")
+ -->
+ <service-ref>
+ <service-ref-name>Port5</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+</jboss-client>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/jboss-client.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/jboss.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/jboss.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/jboss.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE jboss PUBLIC "-//JBoss//DTD JBOSS 5.0//EN" "http://www.jboss.org/j2ee/dtd/jboss_5_0.dtd">
+
+<jboss>
+
+ <!-- [JBWS-1339] @Security domain vs. <security-domain> -->
+ <security-domain>java:/jaas/JBossWS</security-domain>
+
+ <enterprise-beans>
+ <session>
+ <ejb-name>EJB3Client</ejb-name>
+
+ <!--
+ @WebServiceRef(name = "service1", value = TestEndpointService.class, wsdlLocation = "META-INF/wsdl/TestEndpoint.wsdl")
+ <service-ref>
+ <service-ref-name>service1</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+ -->
+
+ <!--
+ @WebServiceRef(name = "service2", value = TestEndpointService.class)
+ -->
+ <service-ref>
+ <service-ref-name>service2</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "TestEndpointService3")
+ -->
+ <service-ref>
+ <service-ref-name>TestEndpointService3</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef
+ -->
+ <service-ref>
+ <service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.EJB3Client/service4</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "TestEndpointService5")
+ -->
+ <service-ref>
+ <service-ref-name>TestEndpointService5</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef
+ -->
+ <service-ref>
+ <service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.EJB3Client/service6</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "port1", value = TestEndpointService.class, type = TestEndpoint.class)
+ -->
+ <service-ref>
+ <service-ref-name>port1</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "Port2", value = TestEndpointService.class)
+ -->
+ <service-ref>
+ <service-ref-name>Port2</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(value = TestEndpointService.class)
+ -->
+ <service-ref>
+ <service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.EJB3Client/port3</service-ref-name>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+ </session>
+ </enterprise-beans>
+
+</jboss>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/jboss.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/wsdl/TestEndpoint.wsdl
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/wsdl/TestEndpoint.wsdl (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/wsdl/TestEndpoint.wsdl 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,39 @@
+<!--
+ wsimport -d ../../../java -keep -p org.jboss.test.ws.jaxws.webserviceref META-INF/wsdl/TestEndpoint.wsdl
+-->
+<definitions name='TestEndpointService' targetNamespace='http://org.jboss.ws/wsref' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://org.jboss.ws/wsref' xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
+
+ <message name='TestEndpoint_echo'>
+ <part name='arg0' type='xsd:string'/>
+ </message>
+ <message name='TestEndpoint_echoResponse'>
+ <part name='return' type='xsd:string'/>
+ </message>
+
+ <portType name='TestEndpoint'>
+ <operation name='echo' parameterOrder='arg0'>
+ <input message='tns:TestEndpoint_echo'/>
+ <output message='tns:TestEndpoint_echoResponse'/>
+ </operation>
+ </portType>
+
+ <binding name='TestEndpointBinding' type='tns:TestEndpoint'>
+ <soap:binding style='rpc' transport='http://schemas.xmlsoap.org/soap/http'/>
+ <operation name='echo'>
+ <soap:operation soapAction=''/>
+ <input>
+ <soap:body namespace='http://org.jboss.ws/wsref' use='literal'/>
+ </input>
+ <output>
+ <soap:body namespace='http://org.jboss.ws/wsref' use='literal'/>
+ </output>
+ </operation>
+ </binding>
+
+ <service name='TestEndpointService'>
+ <port binding='tns:TestEndpointBinding' name='TestEndpointPort'>
+ <soap:address location='http://@jboss.bind.address@:8080/jaxws-samples-webserviceref'/>
+ </port>
+ </service>
+
+</definitions>
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF/wsdl/TestEndpoint.wsdl
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/application-client.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/application-client.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/application-client.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<application-client version="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/javaee/application-client_5.xsd">
+
+ <display-name>TestEndpointService</display-name>
+
+</application-client>
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/application-client.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/jboss-client.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/jboss-client.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/jboss-client.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,97 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE jboss-client PUBLIC "-//JBoss//DTD Application Client 5.0//EN" "http://www.jboss.org/j2ee/dtd/jboss-client_5_0.dtd">
+
+<jboss-client>
+ <jndi-name>jbossws-client</jndi-name>
+
+ <!--
+ @WebServiceRef(name = "Service1")
+ -->
+ <service-ref>
+ <service-ref-name>Service1</service-ref-name>
+ <service-impl-class>org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpointService</service-impl-class>
+ <service-qname>{http://org.jboss.ws/wsref}TestEndpointService</service-qname>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "Service2")
+ -->
+ <service-ref>
+ <service-ref-name>Service2</service-ref-name>
+ <config-name>Custom Client</config-name>
+ <config-file>META-INF/jbossws-client-config.xml</config-file>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "Service3")
+ -->
+ <service-ref>
+ <service-ref-name>Service3</service-ref-name>
+ <service-impl-class>org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpointService</service-impl-class>
+ <service-qname>{http://org.jboss.ws/wsref}TestEndpointService</service-qname>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "Service4")
+ -->
+ <service-ref>
+ <service-ref-name>Service4</service-ref-name>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpoint</service-endpoint-interface>
+ <config-name>Custom Client</config-name>
+ <config-file>META-INF/jbossws-client-config.xml</config-file>
+ </port-component-ref>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "Port1", type = TestEndpoint.class)
+ -->
+ <service-ref>
+ <service-ref-name>Port1</service-ref-name>
+ <port-component-ref>
+ <port-qname>{http://org.jboss.ws/wsref}TestEndpointPort</port-qname>
+ <config-name>Custom Client</config-name>
+ <config-file>META-INF/jbossws-client-config.xml</config-file>
+ </port-component-ref>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "Port2")
+ -->
+ <service-ref>
+ <service-ref-name>Port2</service-ref-name>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpoint</service-endpoint-interface>
+ <config-name>Custom Client</config-name>
+ <config-file>META-INF/jbossws-client-config.xml</config-file>
+ </port-component-ref>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "Port3")
+ -->
+ <service-ref>
+ <service-ref-name>Port3</service-ref-name>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpoint</service-endpoint-interface>
+ <port-qname>{http://org.jboss.ws/wsref}TestEndpointPort</port-qname>
+ <stub-property>
+ <prop-name>javax.xml.ws.security.auth.username</prop-name>
+ <prop-value>kermit</prop-value>
+ </stub-property>
+ <stub-property>
+ <prop-name>javax.xml.ws.security.auth.password</prop-name>
+ <prop-value>thefrog</prop-value>
+ </stub-property>
+ </port-component-ref>
+ <wsdl-override>META-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+</jboss-client>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/jboss-client.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/jbossws-client-config.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/jbossws-client-config.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/jbossws-client-config.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!-- $Id$ -->
+
+<jaxrpc-config xmlns="urn:jboss:jaxrpc-config:2.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
+ xsi:schemaLocation="urn:jboss:jaxrpc-config:2.0 jaxrpc-config_2_0.xsd">
+
+ <client-config>
+ <config-name>Custom Client</config-name>
+ </client-config>
+
+</jaxrpc-config>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-override/jbossws-client-config.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-secure/application-client.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-secure/application-client.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-secure/application-client.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<application-client version="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/javaee/application-client_5.xsd">
+
+ <display-name>SecureEndpointService</display-name>
+
+</application-client>
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-secure/application-client.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-secure/jboss-client.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-secure/jboss-client.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-secure/jboss-client.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE jboss-client PUBLIC "-//JBoss//DTD Application Client 5.0//EN" "http://www.jboss.org/j2ee/dtd/jboss-client_5_0.dtd">
+
+<jboss-client>
+ <jndi-name>jbossws-client</jndi-name>
+
+ <service-ref>
+ <service-ref-name>SecureService1</service-ref-name>
+ <service-impl-class>org.jboss.test.ws.jaxws.samples.webserviceref.SecureEndpointService</service-impl-class>
+ <service-qname>{http://org.jboss.ws/wsref}SecureEndpointService</service-qname>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.webserviceref.SecureEndpoint</service-endpoint-interface>
+ <port-qname>{http://org.jboss.ws/wsref}SecureEndpointPort</port-qname>
+ <stub-property>
+ <prop-name>javax.xml.ws.security.auth.username</prop-name>
+ <prop-value>kermit</prop-value>
+ </stub-property>
+ <stub-property>
+ <prop-name>javax.xml.ws.security.auth.password</prop-name>
+ <prop-value>thefrog</prop-value>
+ </stub-property>
+ </port-component-ref>
+ <wsdl-override>http://@jboss.bind.address@:8080/jaxws-samples-webserviceref-secure/SecureEndpointImpl?wsdl</wsdl-override>
+ </service-ref>
+
+ <service-ref>
+ <service-ref-name>SecureService2</service-ref-name>
+ <port-component-ref>
+ <port-qname>{http://org.jboss.ws/wsref}SecureEndpointPort</port-qname>
+ <stub-property>
+ <prop-name>javax.xml.ws.security.auth.username</prop-name>
+ <prop-value>kermit</prop-value>
+ </stub-property>
+ <stub-property>
+ <prop-name>javax.xml.ws.security.auth.password</prop-name>
+ <prop-value>thefrog</prop-value>
+ </stub-property>
+ </port-component-ref>
+ <wsdl-override>http://@jboss.bind.address@:8080/jaxws-samples-webserviceref-secure/SecureEndpointImpl?wsdl</wsdl-override>
+ </service-ref>
+
+ <service-ref>
+ <service-ref-name>SecurePort1</service-ref-name>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.webserviceref.SecureEndpoint</service-endpoint-interface>
+ <stub-property>
+ <prop-name>javax.xml.ws.security.auth.username</prop-name>
+ <prop-value>kermit</prop-value>
+ </stub-property>
+ <stub-property>
+ <prop-name>javax.xml.ws.security.auth.password</prop-name>
+ <prop-value>thefrog</prop-value>
+ </stub-property>
+ </port-component-ref>
+ <wsdl-override>http://@jboss.bind.address@:8080/jaxws-samples-webserviceref-secure/SecureEndpointImpl?wsdl</wsdl-override>
+ </service-ref>
+
+</jboss-client>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/META-INF-secure/jboss-client.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF/web.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF/web.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF/web.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
+
+ <servlet>
+ <servlet-name>TestEndpoint</servlet-name>
+ <servlet-class>org.jboss.test.ws.jaxws.samples.webserviceref.TestEndpointImpl</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>TestEndpoint</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+</web-app>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF/web.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,80 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE jboss-web PUBLIC "-//JBoss//DTD Web Application 5.0//EN" "http://www.jboss.org/j2ee/dtd/jboss-web_5_0.dtd">
+
+<jboss-web>
+
+
+ <!--
+ @WebServiceRef(name = "service1", value = TestEndpointService.class, wsdlLocation = "WEB-INF/wsdl/TestEndpoint.wsdl")
+ <service-ref>
+ <service-ref-name>service1</service-ref-name>
+ <wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+ -->
+
+ <!--
+ @WebServiceRef(name = "service2", value = TestEndpointService.class)
+ -->
+ <service-ref>
+ <service-ref-name>service2</service-ref-name>
+ <wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "TestEndpointService3")
+ -->
+ <service-ref>
+ <service-ref-name>TestEndpointService3</service-ref-name>
+ <wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef
+ -->
+ <service-ref>
+ <service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.ServletClient/service4</service-ref-name>
+ <wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "TestEndpointService5")
+ -->
+ <service-ref>
+ <service-ref-name>TestEndpointService5</service-ref-name>
+ <wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef
+ -->
+ <service-ref>
+ <service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.ServletClient/service6</service-ref-name>
+ <wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "port1", value = TestEndpointService.class, type = TestEndpoint.class)
+ -->
+ <service-ref>
+ <service-ref-name>port1</service-ref-name>
+ <wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(name = "Port2", value = TestEndpointService.class)
+ -->
+ <service-ref>
+ <service-ref-name>Port2</service-ref-name>
+ <wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+ <!--
+ @WebServiceRef(value = TestEndpointService.class)
+ -->
+ <service-ref>
+ <service-ref-name>org.jboss.test.ws.jaxws.samples.webserviceref.ServletClient/port3</service-ref-name>
+ <wsdl-override>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-override>
+ </service-ref>
+
+</jboss-web>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/jboss-web.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/web.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/web.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/web.xml 2007-07-13 10:13:30 UTC (rev 3874)
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
+
+ <servlet>
+ <servlet-name>ServletClient</servlet-name>
+ <servlet-class>org.jboss.test.ws.jaxws.samples.webserviceref.ServletClient</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>ServletClient</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+</web-app>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/webserviceref/WEB-INF-client/web.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
17 years, 6 months
JBossWS SVN: r3873 - in branches/hbraun/trunk/testsuite: src/java/org/jboss/test/ws/jaxws/samples and 8 other directories.
by jbossws-commits@lists.jboss.org
Author: heiko.braun(a)jboss.com
Date: 2007-07-13 06:05:26 -0400 (Fri, 13 Jul 2007)
New Revision: 3873
Added:
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java
branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/
branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml
Modified:
branches/hbraun/trunk/testsuite/ant-import/build-jars-jaxws.xml
Log:
Really move serviceref to samples
Modified: branches/hbraun/trunk/testsuite/ant-import/build-jars-jaxws.xml
===================================================================
--- branches/hbraun/trunk/testsuite/ant-import/build-jars-jaxws.xml 2007-07-13 09:37:29 UTC (rev 3872)
+++ branches/hbraun/trunk/testsuite/ant-import/build-jars-jaxws.xml 2007-07-13 10:05:26 UTC (rev 3873)
@@ -27,7 +27,7 @@
<include name="org/jboss/test/ws/jaxws/samples/asynchronous/TestEndpointBean.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-context -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-context.war" webxml="${tests.output.dir}/resources/jaxws/samples/context/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -45,7 +45,7 @@
<include name="jboss.xml"/>
</metainf>
</jar>
-
+
<!-- jaxws-samples-eardeployment -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-eardeployment.war" webxml="${tests.output.dir}/resources/jaxws/samples/eardeployment/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -92,7 +92,7 @@
<include name="org/jboss/test/ws/jaxws/samples/exception/server/UserException.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-handlerchain -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-handlerchain.war" webxml="${tests.output.dir}/resources/jaxws/samples/handlerchain/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -102,7 +102,7 @@
<include name="org/jboss/test/ws/jaxws/samples/handlerchain/jaxws-handlers-server.xml"/>
</classes>
</war>
-
+
<!-- jaxws-samples-httpbinding -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-httpbinding-jaxb.war" webxml="${tests.output.dir}/resources/jaxws/samples/httpbinding/jaxb/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -124,7 +124,7 @@
<include name="wsdl/HttpBinding.wsdl"/>
</webinf>
</war>
-
+
<!-- jaxws-samples-logicalhandler -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-logicalhandler-source.war"
webxml="${tests.output.dir}/resources/jaxws/samples/logicalhandler/WEB-INF/web-source.xml">
@@ -153,14 +153,14 @@
<include name="org/jboss/test/ws/jaxws/samples/logicalhandler/jaxws-server-jaxb-handlers.xml"/>
</classes>
</war>
-
+
<!-- jaxws-samples-oneway -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-oneway.war" webxml="${tests.output.dir}/resources/jaxws/samples/oneway/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
<include name="org/jboss/test/ws/jaxws/samples/oneway/PingEndpointImpl.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-provider -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-provider-jaxb.war" webxml="${tests.output.dir}/resources/jaxws/samples/provider/jaxb/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -190,7 +190,7 @@
<include name="wsdl/Provider.wsdl"/>
</webinf>
</war>
-
+
<!-- jaxws-samples-retail -->
<jar jarfile="${tests.output.dir}/libs/jaxws-samples-retail.jar">
<fileset dir="${tests.output.dir}/classes">
@@ -277,7 +277,7 @@
<include name="org/jboss/test/ws/jaxws/samples/swaref/DocumentPayload*.class"/>
</fileset>
</jar>
-
+
<!-- jaxws-samples-webmethod -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-webmethod.war" webxml="${tests.output.dir}/resources/jaxws/samples/webmethod/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -285,7 +285,7 @@
<include name="org/jboss/test/ws/jaxws/samples/webmethod/TestEndpointImpl.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-webparam -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-webparam.war" webxml="${tests.output.dir}/resources/jaxws/samples/webparam/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -294,7 +294,7 @@
<include name="org/jboss/test/ws/jaxws/samples/webparam/SecurityHeader.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-webresult -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-webresult.war" webxml="${tests.output.dir}/resources/jaxws/samples/webresult/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -303,7 +303,7 @@
<include name="org/jboss/test/ws/jaxws/samples/webresult/USAddress.class"/>
</classes>
</war>
-
+
<!-- jaxws-samples-webservice -->
<war warfile="${tests.output.dir}/libs/jaxws-samples-webservice01-jse.war" webxml="${tests.output.dir}/resources/jaxws/samples/webservice/WEB-INF01/web.xml">
<classes dir="${tests.output.dir}/classes">
@@ -346,7 +346,7 @@
<include name="org/jboss/test/ws/jaxws/samples/webservice/EndpointInterface03.class"/>
</fileset>
</jar>
-
+
<!-- jaxws-samples-xop-doclit -->
<war jarfile="${tests.output.dir}/libs/jaxws-samples-xop-doclit.war" webxml="${tests.output.dir}/resources/jaxws/samples/xop/doclit/WEB-INF/web.xml">
<classes dir="${tests.output.dir}/classes">
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,81 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import org.jboss.annotation.ejb.RemoteBinding;
+import org.jboss.logging.Logger;
+
+import javax.ejb.Remote;
+import javax.ejb.Stateless;
+import javax.naming.InitialContext;
+import javax.xml.ws.BindingProvider;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.soap.SOAPBinding;
+import java.rmi.RemoteException;
+import java.util.ArrayList;
+
+(a)Remote(EJBRemote.class)
+@RemoteBinding(jndiBinding = "/ejb/EJBClient")
+@Stateless
+
+public class EJBClient
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(EJBClient.class);
+
+ public String echo(String inStr) throws RemoteException
+ {
+ log.info("echo: " + inStr);
+
+ ArrayList ports = new ArrayList(2);
+
+ try
+ {
+ InitialContext iniCtx = new InitialContext();
+ ports.add((TestEndpoint)((Service)iniCtx.lookup("java:comp/env/service1")).getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/service2")).getTestEndpointPort());
+ }
+ catch (Exception ex)
+ {
+ throw new WebServiceException(ex);
+ }
+
+ for (int i = 0; i < ports.size(); i++)
+ {
+ TestEndpoint port = (TestEndpoint)ports.get(i);
+
+ BindingProvider bp = (BindingProvider)port;
+ boolean mtomEnabled = ((SOAPBinding)bp.getBinding()).isMTOMEnabled();
+ boolean expectedSetting = (i==0) ? false : true;
+
+ //if(mtomEnabled != expectedSetting)
+ // throw new WebServiceException("MTOM settings (enabled="+expectedSetting+") not overridden through service-ref" );
+
+ String outStr = port.echo(inStr);
+ if (inStr.equals(outStr) == false)
+ throw new WebServiceException("Invalid echo return: " + inStr);
+ }
+
+ return inStr;
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBClient.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,28 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+
+public interface EJBRemote
+{
+ String echo(String input);
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/EJBRemote.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,91 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import junit.framework.Test;
+import org.jboss.wsf.spi.test.JBossWSTest;
+import org.jboss.wsf.spi.test.JBossWSTestSetup;
+
+import javax.naming.InitialContext;
+import javax.xml.namespace.QName;
+import javax.xml.ws.BindingProvider;
+import javax.xml.ws.Service;
+import java.io.File;
+import java.io.InputStream;
+import java.net.URL;
+
+/**
+ * Test the JAXWS <service-ref>
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 123-Mar-2007
+ */
+public class ServiceRefClientTestCase extends JBossWSTest
+{
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-serviceref";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(ServiceRefClientTestCase.class, "jaxws-serviceref.war, jaxws-serviceref-client.jar");
+ }
+
+ public void testWSDLAccess() throws Exception
+ {
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ InputStream inputStream = wsdlURL.openStream();
+ assertNotNull(inputStream);
+ inputStream.close();
+ }
+
+ public void testDynamicProxy() throws Exception
+ {
+ URL wsdlURL = new File("resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl").toURL();
+ QName qname = new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService");
+ Service service = Service.create(wsdlURL, qname);
+ TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
+
+ String request = "testDynamicProxy";
+ String response = port.echo(request);
+ assertEquals(request, response);
+ }
+
+ public void testApplicationClient() throws Exception
+ {
+ InitialContext iniCtx = getInitialContext("jbossws-client");
+ Service service = (Service) iniCtx.lookup("java:comp/env/service2");
+ TestEndpoint port = service.getPort(TestEndpoint.class);
+ assertNotNull(port);
+
+ BindingProvider bp = (BindingProvider)port;
+
+ System.out.println("FIXME [JBWS-1736]: MTOM property at service-ref level");
+
+ //boolean mtomEnabled = ((SOAPBinding)bp.getBinding()).isMTOMEnabled();
+ //assertTrue("MTOM should be enabled on port", mtomEnabled);
+
+ String request = "testApplicationClient";
+ String response = port.echo(request);
+ assertEquals(response, request);
+
+ }
+
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefClientTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,82 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import junit.framework.Test;
+import org.jboss.wsf.spi.test.JBossWSTest;
+import org.jboss.wsf.spi.test.JBossWSTestSetup;
+
+import javax.naming.InitialContext;
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import java.io.File;
+import java.io.InputStream;
+import java.net.URL;
+
+/**
+ * Test the JAXRPC <service-ref>
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 23-Oct-2005
+ */
+public class ServiceRefEJBTestCase extends JBossWSTest
+{
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-serviceref";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(ServiceRefEJBTestCase.class, "jaxws-serviceref.war, jaxws-serviceref-ejb-client.jar");
+ }
+
+ public void testWSDLAccess() throws Exception
+ {
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ InputStream inputStream = wsdlURL.openStream();
+ assertNotNull(inputStream);
+ inputStream.close();
+ }
+
+
+ public void testDynamicProxy() throws Exception
+ {
+ URL wsdlURL = new File("resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl").toURL();
+ QName qname = new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService");
+ Service service = Service.create(wsdlURL, qname);
+ TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
+
+ String helloWorld = "testDynamicProxy";
+ Object retObj = port.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+ }
+
+
+ public void testEJBClient() throws Exception
+ {
+ InitialContext iniCtx = getInitialContext();
+ EJBRemote ejbRemote = (EJBRemote)iniCtx.lookup("/ejb/EJBClient");
+
+ String helloWorld = "Hello World!";
+ Object retObj = ejbRemote.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefEJBTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,78 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import junit.framework.Test;
+import org.jboss.wsf.spi.test.JBossWSTest;
+import org.jboss.wsf.spi.test.JBossWSTestSetup;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.InputStreamReader;
+import java.io.InputStream;
+import java.net.URL;
+
+/**
+ * Test the jaxws <service-ref>
+ *
+ * @author Thomas.Diesler(a)jboss.com
+ * @since 23-Oct-2005
+ */
+public class ServiceRefServletTestCase extends JBossWSTest
+{
+ public final String TARGET_ENDPOINT_ADDRESS = "http://" + getServerHost() + ":8080/jaxws-serviceref";
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(ServiceRefServletTestCase.class, "jaxws-serviceref.war, jaxws-serviceref-servlet-client.war");
+ }
+
+ public void testWSDLAccess() throws Exception
+ {
+ URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
+ InputStream inputStream = wsdlURL.openStream();
+ assertNotNull(inputStream);
+ inputStream.close();
+ }
+
+ public void testDynamicProxy() throws Exception
+ {
+ URL wsdlURL = new File("resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl").toURL();
+ QName qname = new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService");
+ Service service = Service.create(wsdlURL, qname);
+ TestEndpoint port = (TestEndpoint)service.getPort(TestEndpoint.class);
+
+ String helloWorld = "Hello World!";
+ Object retObj = port.echo(helloWorld);
+ assertEquals(helloWorld, retObj);
+ }
+
+ public void testServletClient() throws Exception
+ {
+ URL url = new URL(TARGET_ENDPOINT_ADDRESS + "-servlet-client?echo=HelloWorld");
+ BufferedReader br = new BufferedReader(new InputStreamReader(url.openStream()));
+ String retStr = br.readLine();
+ assertEquals("HelloWorld", retStr);
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServiceRefServletTestCase.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,80 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import java.io.IOException;
+import java.util.ArrayList;
+
+import javax.naming.InitialContext;
+import javax.servlet.ServletException;
+import javax.servlet.http.HttpServlet;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebServiceException;
+import javax.xml.ws.BindingProvider;
+import javax.xml.ws.soap.SOAPBinding;
+
+import org.jboss.logging.Logger;
+
+public class ServletClient extends HttpServlet
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(ServletClient.class);
+
+ protected void doGet(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException
+ {
+ String inStr = req.getParameter("echo");
+ log.info("doGet: " + inStr);
+
+ ArrayList ports = new ArrayList();
+ try
+ {
+ InitialContext iniCtx = new InitialContext();
+ ports.add((TestEndpoint)((Service)iniCtx.lookup("java:comp/env/service1")).getPort(TestEndpoint.class));
+ ports.add(((TestEndpointService)iniCtx.lookup("java:comp/env/service2")).getTestEndpointPort());
+ }
+ catch (Exception ex)
+ {
+ log.error("Cannot add port", ex);
+ throw new WebServiceException(ex);
+ }
+
+ for (int i = 0; i < ports.size(); i++)
+ {
+ TestEndpoint port = (TestEndpoint)ports.get(i);
+
+ BindingProvider bp = (BindingProvider)port;
+ boolean mtomEnabled = ((SOAPBinding)bp.getBinding()).isMTOMEnabled();
+ boolean expectedSetting = (i==0) ? false : true;
+
+ //if(mtomEnabled != expectedSetting)
+ // throw new WebServiceException("MTOM settings (enabled="+expectedSetting+") not overridden through service-ref" );
+
+ String outStr = port.echo(inStr);
+ if (inStr.equals(outStr) == false)
+ throw new WebServiceException("Invalid echo return: " + inStr);
+ }
+
+ res.getWriter().print(inStr);
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/ServletClient.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,40 @@
+
+package org.jboss.test.ws.jaxws.samples.serviceref;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebResult;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+
+/**
+ * JBossWS Generated Source
+ *
+ * Generation Date: Mon Mar 12 15:09:39 CET 2007
+ *
+ * This generated source code represents a derivative work of the input to
+ * the generator that produced it. Consult the input for the copyright and
+ * terms of use that apply to this source code.
+ *
+ * JAX-WS Version: 2.0
+ *
+ */
+@WebService(name = "TestEndpoint", targetNamespace = "http://serviceref.samples.jaxws.ws.test.jboss.org/")
+@SOAPBinding(style = SOAPBinding.Style.RPC)
+public interface TestEndpoint {
+
+
+ /**
+ *
+ * @param arg0
+ * @return
+ * returns java.lang.String
+ */
+ @WebMethod
+ @WebResult(partName = "return")
+ public String echo(
+ @WebParam(name = "arg0", partName = "arg0")
+ String arg0);
+
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpoint.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.samples.serviceref;
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+import org.jboss.logging.Logger;
+
+/**
+ * Test the jaxws <service-ref>
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 12-Mar-2007
+ */
+
+@WebService (name = "TestEndpoint")
+@SOAPBinding(style = SOAPBinding.Style.RPC)
+public class TestEndpointImpl
+{
+ // Provide logging
+ private static Logger log = Logger.getLogger(TestEndpointImpl.class);
+
+ @WebMethod
+ public String echo(String input)
+ {
+ log.info(input);
+ return input;
+ }
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointImpl.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java
===================================================================
--- branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java (rev 0)
+++ branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,59 @@
+
+package org.jboss.test.ws.jaxws.samples.serviceref;
+
+import java.net.MalformedURLException;
+import java.net.URL;
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebEndpoint;
+import javax.xml.ws.WebServiceClient;
+
+
+/**
+ * JBossWS Generated Source
+ *
+ * Generation Date: Mon Mar 12 15:09:39 CET 2007
+ *
+ * This generated source code represents a derivative work of the input to
+ * the generator that produced it. Consult the input for the copyright and
+ * terms of use that apply to this source code.
+ *
+ * JAX-WS Version: 2.0
+ *
+ */
+@WebServiceClient(name = "TestEndpointService", targetNamespace = "http://serviceref.samples.jaxws.ws.test.jboss.org/", wsdlLocation = "http://tddell:8080/jaxws-serviceref?wsdl")
+public class TestEndpointService
+ extends Service
+{
+
+ private final static URL TESTENDPOINTSERVICE_WSDL_LOCATION;
+
+ static {
+ URL url = null;
+ try {
+ url = new URL("http://tddell:8080/jaxws-serviceref?wsdl");
+ } catch (MalformedURLException e) {
+ e.printStackTrace();
+ }
+ TESTENDPOINTSERVICE_WSDL_LOCATION = url;
+ }
+
+ public TestEndpointService(URL wsdlLocation, QName serviceName) {
+ super(wsdlLocation, serviceName);
+ }
+
+ public TestEndpointService() {
+ super(TESTENDPOINTSERVICE_WSDL_LOCATION, new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointService"));
+ }
+
+ /**
+ *
+ * @return
+ * returns TestEndpoint
+ */
+ @WebEndpoint(name = "TestEndpointPort")
+ public TestEndpoint getTestEndpointPort() {
+ return (TestEndpoint)super.getPort(new QName("http://serviceref.samples.jaxws.ws.test.jboss.org/", "TestEndpointPort"), TestEndpoint.class);
+ }
+
+}
Property changes on: branches/hbraun/trunk/testsuite/src/java/org/jboss/test/ws/jaxws/samples/serviceref/TestEndpointService.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<application-client version="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/javaee/application-client_5.xsd">
+
+ <display-name>jaxws simple tests</display-name>
+
+ <service-ref>
+ <service-ref-name>service1</service-ref-name>
+ <service-interface>javax.xml.ws.Service</service-interface>
+ <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
+ </service-ref>
+
+ <service-ref>
+ <service-ref-name>service2</service-ref-name>
+ <service-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointService</service-interface>
+ <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
+ <enable-mtom>true</enable-mtom>
+ </port-component-ref>
+ </service-ref>
+
+</application-client>
+
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/application-client.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<ejb-jar version="3.0"
+ 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/javaee/ejb-jar_3_0.xsd">
+
+ <enterprise-beans>
+ <session>
+ <ejb-name>EJBClient</ejb-name>
+ <remote>org.jboss.test.ws.jaxws.samples.serviceref.EJBRemote</remote>
+ <ejb-class>org.jboss.test.ws.jaxws.samples.serviceref.EJBClient</ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+
+ <service-ref>
+ <service-ref-name>service1</service-ref-name>
+ <service-interface>javax.xml.ws.Service</service-interface>
+ <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
+ </service-ref>
+
+ <service-ref>
+ <service-ref-name>service2</service-ref-name>
+ <service-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointService</service-interface>
+ <wsdl-file>META-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname xmlns:ns1="http://serviceref.samples.jaxws.ws.test.jboss.org/">ns1:TestEndpointService</service-qname>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
+ <enable-mtom>true</enable-mtom>
+ </port-component-ref>
+ </service-ref>
+
+ </session>
+ </enterprise-beans>
+
+</ejb-jar>
+
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/ejb-jar.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,37 @@
+<?xml version='1.0' encoding='UTF-8'?><java-wsdl-mapping version='1.1' xmlns='http://java.sun.com/xml/ns/j2ee' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd'>
+ <package-mapping>
+ <package-type>org.jboss.test.ws.jaxrpc.serviceref</package-type>
+ <namespaceURI>http://org.jboss.ws/wsref/types</namespaceURI>
+ </package-mapping>
+ <service-interface-mapping>
+ <service-interface>org.jboss.test.ws.jaxrpc.serviceref.TestEndpointService</service-interface>
+ <wsdl-service-name xmlns:serviceNS='http://org.jboss.ws/wsref'>serviceNS:TestEndpointService</wsdl-service-name>
+ <port-mapping>
+ <port-name>TestEndpointPort</port-name>
+ <java-port-name>TestEndpointPort</java-port-name>
+ </port-mapping>
+ </service-interface-mapping>
+ <service-endpoint-interface-mapping>
+ <service-endpoint-interface>org.jboss.test.ws.jaxrpc.serviceref.TestEndpoint</service-endpoint-interface>
+ <wsdl-port-type xmlns:portTypeNS='http://org.jboss.ws/wsref'>portTypeNS:TestEndpoint</wsdl-port-type>
+ <wsdl-binding xmlns:bindingNS='http://org.jboss.ws/wsref'>bindingNS:TestEndpointBinding</wsdl-binding>
+ <service-endpoint-method-mapping>
+ <java-method-name>echo</java-method-name>
+ <wsdl-operation>echo</wsdl-operation>
+ <method-param-parts-mapping>
+ <param-position>0</param-position>
+ <param-type>java.lang.String</param-type>
+ <wsdl-message-mapping>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.ws/wsref'>wsdlMsgNS:TestEndpoint_echo</wsdl-message>
+ <wsdl-message-part-name>String_1</wsdl-message-part-name>
+ <parameter-mode>IN</parameter-mode>
+ </wsdl-message-mapping>
+ </method-param-parts-mapping>
+ <wsdl-return-value-mapping>
+ <method-return-value>java.lang.String</method-return-value>
+ <wsdl-message xmlns:wsdlMsgNS='http://org.jboss.ws/wsref'>wsdlMsgNS:TestEndpoint_echoResponse</wsdl-message>
+ <wsdl-message-part-name>result</wsdl-message-part-name>
+ </wsdl-return-value-mapping>
+ </service-endpoint-method-mapping>
+ </service-endpoint-interface-mapping>
+</java-wsdl-mapping>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jaxrpc-mapping.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,14 @@
+<?xml version='1.0' encoding='UTF-8' ?>
+<!DOCTYPE jboss-client PUBLIC "-//JBoss//DTD Application Client 5.0//EN" "http://www.jboss.org/j2ee/dtd/jboss-client_5_0.dtd">
+
+<jboss-client>
+ <jndi-name>jbossws-client</jndi-name>
+
+ <!--service-ref>
+ <service-ref-name>service2</service-ref-name>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
+ <port-qname>{http://serviceref.samples.jaxws.ws.test.jboss.org/}TestEndpointPort</port-qname>
+ </port-component-ref>
+ </service-ref-->
+</jboss-client>
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/jboss-client.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,32 @@
+<definitions name='TestEndpointService' targetNamespace='http://serviceref.samples.jaxws.ws.test.jboss.org/' xmlns='http://schemas.xmlsoap.org/wsdl/' xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' xmlns:tns='http://serviceref.samples.jaxws.ws.test.jboss.org/' xmlns:xsd='http://www.w3.org/2001/XMLSchema'>
+ <types></types>
+ <message name='TestEndpoint_echoResponse'>
+ <part name='return' type='xsd:string'/>
+ </message>
+ <message name='TestEndpoint_echo'>
+ <part name='arg0' type='xsd:string'/>
+ </message>
+ <portType name='TestEndpoint'>
+ <operation name='echo' parameterOrder='arg0'>
+ <input message='tns:TestEndpoint_echo'/>
+ <output message='tns:TestEndpoint_echoResponse'/>
+ </operation>
+ </portType>
+ <binding name='TestEndpointBinding' type='tns:TestEndpoint'>
+ <soap:binding style='rpc' transport='http://schemas.xmlsoap.org/soap/http'/>
+ <operation name='echo'>
+ <soap:operation soapAction=''/>
+ <input>
+ <soap:body namespace='http://serviceref.samples.jaxws.ws.test.jboss.org/' use='literal'/>
+ </input>
+ <output>
+ <soap:body namespace='http://serviceref.samples.jaxws.ws.test.jboss.org/' use='literal'/>
+ </output>
+ </operation>
+ </binding>
+ <service name='TestEndpointService'>
+ <port binding='tns:TestEndpointBinding' name='TestEndpointPort'>
+ <soap:address location='http://@jboss.bind.address@:8080/jaxws-serviceref'/>
+ </port>
+ </service>
+</definitions>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/META-INF/wsdl/TestEndpoint.wsdl
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
+
+ <servlet>
+ <servlet-name>TestEndpoint</servlet-name>
+ <servlet-class>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointImpl</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>TestEndpoint</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+</web-app>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/WEB-INF/web.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Added: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml
===================================================================
--- branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml (rev 0)
+++ branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml 2007-07-13 10:05:26 UTC (rev 3873)
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" 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>ServletClient</servlet-name>
+ <servlet-class>org.jboss.test.ws.jaxws.samples.serviceref.ServletClient</servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>ServletClient</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+
+ <service-ref>
+ <service-ref-name>service1</service-ref-name>
+ <service-interface>javax.xml.ws.Service</service-interface>
+ <wsdl-file>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname>{http://serviceref.samples.jaxws.ws.test.jboss.org/}TestEndpointService</service-qname>
+ </service-ref>
+
+ <service-ref>
+ <service-ref-name>service2</service-ref-name>
+ <service-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpointService</service-interface>
+ <wsdl-file>WEB-INF/wsdl/TestEndpoint.wsdl</wsdl-file>
+ <service-qname>{http://serviceref.samples.jaxws.ws.test.jboss.org/}TestEndpointService</service-qname>
+ <port-component-ref>
+ <service-endpoint-interface>org.jboss.test.ws.jaxws.samples.serviceref.TestEndpoint</service-endpoint-interface>
+ <enable-mtom>true</enable-mtom>
+ </port-component-ref>
+ </service-ref>
+
+</web-app>
\ No newline at end of file
Property changes on: branches/hbraun/trunk/testsuite/src/resources/jaxws/samples/serviceref/servlet-client/WEB-INF/web.xml
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
17 years, 6 months