Author: thomas.diesler(a)jboss.com
Date: 2007-01-29 08:02:19 -0500 (Mon, 29 Jan 2007)
New Revision: 2175
Added:
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceEndpointInvokerEJB21.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/CallImpl.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/HandlerRegistryImpl.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/PortProxy.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceExt.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceFactoryImpl.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceImpl.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceObjectFactory.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceProxy.java
Removed:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/HandlerRegistryImpl.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/PortProxy.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceExt.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceFactoryImpl.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceImpl.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceObjectFactory.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceProxy.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceReferenceable.java
Modified:
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ApplicationMetaDataAdaptor.java
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ServiceEndpointInvokerEJB21.java
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ServiceEndpointPublisher.java
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/WebServiceClientDeployer.java
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/AbstractDeployerEJB.java
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ApplicationMetaDataAdaptor.java
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceEndpointPublisher.java
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceRefHandler.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceReferenceable.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/jaxrpc/ServiceFactoryImpl.java
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/common/binding/SOAPBindingTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/common/soap/attachment/GenericAttachmentTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1093/JBWS1093TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1107/JBWS1107TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1124/JBWS1124TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1186/JBWS1186TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1378/JBWS1378TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1386/JBWS1386TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1427/JBWS1427TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws950/JBWS950TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws956/JBWS956TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/marshall/MarshallRpcLitDIITestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/docstyle/bare/TrivialServiceDocBareTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/docstyle/wrapped/TrivialServiceDocWrappedTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/dynamichandler/DynamicHandlerTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/exception/ExceptionTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderClientTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderDIITestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderProxyTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/holder/HolderTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcDIIConfiguredCallTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcDIIUnconfiguredCallTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcProxyTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/DocJSETestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcDIIConfiguredCallTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcDIIUnconfiguredCallTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcJSETestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcProxyTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/message/MessageTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/mtom/MTOMTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/oneway/OneWayTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/rpcstyle/TrivialServiceRpcTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/swa/AttachmentProxyTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/SimpleEncryptTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/SimpleSignTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/StorePassEncryptTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefClientTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefEJBTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefServletTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jbws1178/JBWS1178TestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/complex/client/JSR181ComplexTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/webparam/JSR181WebParamTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/webresult/JSR181WebResultTestCase.java
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/samples/jsr181pojo/JSR181WebServiceJSETestCase.java
Log:
Resurect EJB2.1 endpoints/clients
Modified:
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ApplicationMetaDataAdaptor.java
===================================================================
---
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ApplicationMetaDataAdaptor.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ApplicationMetaDataAdaptor.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -104,7 +104,7 @@
{
ubmd.setEjbName(bmd.getEjbName());
ubmd.setEjbClass(bmd.getEjbClass());
- ubmd.setServiceEndpoint(bmd.getServiceEndpoint());
+ ubmd.setServiceEndpointInterface(bmd.getServiceEndpoint());
ubmd.setHome(bmd.getHome());
ubmd.setLocalHome(bmd.getLocalHome());
ubmd.setJndiName(bmd.getJndiName());
Modified:
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ServiceEndpointInvokerEJB21.java
===================================================================
---
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ServiceEndpointInvokerEJB21.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ServiceEndpointInvokerEJB21.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -94,7 +94,7 @@
String seiName = epMetaData.getServiceEndpointInterfaceName();
if (epMetaData.getType() == Type.JAXRPC && seiName != null)
{
- String bmdSEI = beanMetaData.getServiceEndpoint();
+ String bmdSEI = beanMetaData.getServiceEndpointInterface();
if (seiName.equals(bmdSEI) == false)
throw new WSException("Endpoint meta data defines SEI '" +
seiName + "', <service-endpoint> in ejb-jar.xml defines '" +
bmdSEI + "'");
}
Modified:
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ServiceEndpointPublisher.java
===================================================================
---
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ServiceEndpointPublisher.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/ServiceEndpointPublisher.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -65,7 +65,16 @@
public String destroyServiceEndpoint(UnifiedDeploymentInfo udi) throws Exception
{
- getMainDeployer().undeploy(udi.webappURL);
+ URL warURL = udi.webappURL;
+ if (warURL == null)
+ {
+ log.error("Cannot obtain waURL for: " + udi.name);
+ return "FAIL";
+ }
+
+ log.debug("destroyServiceEndpoint: " + warURL);
+
+ getMainDeployer().undeploy(warURL);
return "OK";
}
Modified:
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/WebServiceClientDeployer.java
===================================================================
---
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/WebServiceClientDeployer.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/integration-jboss42/src/main/java/org/jboss/ws/integration/jboss42/WebServiceClientDeployer.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -37,7 +37,7 @@
import org.jboss.system.ServiceMBeanSupport;
import org.jboss.webservice.metadata.serviceref.ServiceRefMetaData;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.jaxrpc.ServiceReferenceable;
+import org.jboss.ws.core.jaxrpc.client.ServiceReferenceable;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
import org.jboss.ws.metadata.builder.jaxrpc.JAXRPCClientDeployment;
import org.jboss.ws.metadata.j2ee.UnifiedServiceRefMetaData;
Modified:
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/AbstractDeployerEJB.java
===================================================================
---
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/AbstractDeployerEJB.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/AbstractDeployerEJB.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -62,14 +62,13 @@
protected void destroyServiceEndpoint(UnifiedDeploymentInfo udi, DeploymentUnit unit)
{
// Destroy the webapp
- URL warURL = unit.getAttachment(ServiceEndpointWebApp.class).getWarURL();
try
{
getServiceEndpointPublisher().destroyServiceEndpoint(udi);
}
catch (Exception ex)
{
- log.error("Cannot destroy service endpoint: " + warURL, ex);
+ log.error("Cannot destroy service endpoint", ex);
}
// Destroy the service endpoint
Modified:
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ApplicationMetaDataAdaptor.java
===================================================================
---
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ApplicationMetaDataAdaptor.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ApplicationMetaDataAdaptor.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -152,7 +152,7 @@
{
ubmd.setEjbName(bmd.getEjbName());
ubmd.setEjbClass(bmd.getEjbClass());
- ubmd.setServiceEndpoint(bmd.getServiceEndpoint());
+ ubmd.setServiceEndpointInterface(bmd.getServiceEndpoint());
ubmd.setHome(bmd.getHome());
ubmd.setLocalHome(bmd.getLocalHome());
ubmd.setJndiName(bmd.getJndiName());
Added:
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceEndpointInvokerEJB21.java
===================================================================
---
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceEndpointInvokerEJB21.java
(rev 0)
+++
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceEndpointInvokerEJB21.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -0,0 +1,195 @@
+/*
+ * 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.integration.jboss50;
+
+// $Id$
+
+import java.lang.reflect.Method;
+import java.security.Principal;
+
+import javax.management.MBeanServer;
+import javax.management.ObjectName;
+
+import org.jboss.invocation.Invocation;
+import org.jboss.invocation.InvocationKey;
+import org.jboss.invocation.InvocationType;
+import org.jboss.invocation.PayloadKey;
+import org.jboss.logging.Logger;
+import org.jboss.mx.util.MBeanServerLocator;
+import org.jboss.security.SecurityAssociation;
+import org.jboss.ws.WSException;
+import org.jboss.ws.core.CommonMessageContext;
+import org.jboss.ws.core.EndpointInvocation;
+import org.jboss.ws.core.jaxrpc.handler.SOAPMessageContextJAXRPC;
+import org.jboss.ws.core.server.AbstractServiceEndpointInvoker;
+import org.jboss.ws.core.server.ServiceEndpointInfo;
+import org.jboss.ws.core.server.ServiceEndpointInvoker;
+import org.jboss.ws.core.soap.MessageContextAssociation;
+import org.jboss.ws.core.utils.ObjectNameFactory;
+import org.jboss.ws.metadata.j2ee.UnifiedApplicationMetaData;
+import org.jboss.ws.metadata.j2ee.UnifiedBeanMetaData;
+import org.jboss.ws.metadata.umdm.ServerEndpointMetaData;
+import org.jboss.ws.metadata.umdm.EndpointMetaData.Type;
+import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
+
+/**
+ * Handles invocations on EJB2.1 endpoints.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 19-Jan-2005
+ */
+public class ServiceEndpointInvokerEJB21 extends AbstractServiceEndpointInvoker
implements ServiceEndpointInvoker
+{
+ // provide logging
+ private Logger log = Logger.getLogger(ServiceEndpointInvokerEJB21.class);
+
+ private String jndiName;
+ private MBeanServer server;
+ private ObjectName objectName;
+
+ public ServiceEndpointInvokerEJB21()
+ {
+ server = MBeanServerLocator.locateJBoss();
+ }
+
+ /** Initialize the service endpoint */
+ @Override
+ public void initServiceEndpoint(ServiceEndpointInfo seInfo)
+ {
+ super.initServiceEndpoint(seInfo);
+
+ ServerEndpointMetaData epMetaData = seInfo.getServerEndpointMetaData();
+ String ejbName = epMetaData.getLinkName();
+ if (ejbName == null)
+ throw new WSException("Cannot obtain ejb-link from port component");
+
+ UnifiedApplicationMetaData applMetaData =
(UnifiedApplicationMetaData)seInfo.getUnifiedDeploymentInfo().metaData;
+ UnifiedBeanMetaData beanMetaData =
(UnifiedBeanMetaData)applMetaData.getBeanByEjbName(ejbName);
+ if (beanMetaData == null)
+ throw new WSException("Cannot obtain ejb meta data for: " + ejbName);
+
+ // verify the service endpoint
+ String seiName = epMetaData.getServiceEndpointInterfaceName();
+ if (epMetaData.getType() == Type.JAXRPC && seiName != null)
+ {
+ String bmdSEI = beanMetaData.getServiceEndpointInterface();
+ if (seiName.equals(bmdSEI) == false)
+ throw new WSException("Endpoint meta data defines SEI '" +
seiName + "', <service-endpoint> in ejb-jar.xml defines '" +
bmdSEI + "'");
+ }
+
+ // get the bean's JNDI name
+ jndiName = beanMetaData.getContainerObjectNameJndiName();
+ if (jndiName == null)
+ throw new WSException("Cannot obtain JNDI name for: " + ejbName);
+
+ objectName = ObjectNameFactory.create("jboss.j2ee:jndiName=" + jndiName +
",service=EJB");
+ }
+
+ /** Load the SEI implementation bean if necessary
+ */
+ public Class loadServiceEndpoint(ServiceEndpointInfo seInfo)
+ {
+ if (server.isRegistered(objectName) == false)
+ throw new WSException("Cannot find service endpoint target: " +
objectName);
+
+ return null;
+ }
+
+ /** Create an instance of the SEI implementation bean if necessary */
+ public Object createServiceEndpoint(ServiceEndpointInfo seInfo, Object
endpointContext, Class seiImplClass)
+ {
+ return null;
+ }
+
+ /** Invoke an instance of the SEI implementation bean */
+ public void invokeServiceEndpoint(ServiceEndpointInfo seInfo, Object seiImpl,
EndpointInvocation epInv) throws Exception
+ {
+ log.debug("invokeServiceEndpoint: " + epInv.getJavaMethod().getName());
+
+ // these are provided by the ServerLoginHandler
+ Principal principal = SecurityAssociation.getPrincipal();
+ Object credential = SecurityAssociation.getCredential();
+
+ CommonMessageContext msgContext = MessageContextAssociation.peekMessageContext();
+
+ // invoke on the container
+ try
+ {
+ // setup the invocation
+ Method method = epInv.getJavaMethod();
+ Object[] args = epInv.getRequestPayload();
+ Invocation inv = new Invocation(null, method, args, null, principal,
credential);
+
+ // EJB2.1 endpoints will only get an JAXRPC context
+ if ((msgContext instanceof javax.xml.rpc.handler.MessageContext) == false)
+ msgContext = new SOAPMessageContextJAXRPC(msgContext);
+
+ inv.setValue(InvocationKey.SOAP_MESSAGE_CONTEXT, msgContext);
+ inv.setValue(InvocationKey.SOAP_MESSAGE, msgContext.getSOAPMessage());
+ inv.setType(InvocationType.SERVICE_ENDPOINT);
+
+ // Set the handler callback and endpoint invocation
+ inv.setValue(EndpointInvocation.class.getName(), epInv, PayloadKey.TRANSIENT);
+
+ String[] sig = { Invocation.class.getName() };
+ Object retObj = server.invoke(objectName, "invoke", new Object[] { inv
}, sig);
+ epInv.setReturnValue(retObj);
+ }
+ catch (Exception e)
+ {
+ handleInvocationException(e);
+ }
+ }
+
+ /** Create an instance of the SEI implementation bean if necessary */
+ public void destroyServiceEndpoint(ServiceEndpointInfo seInfo, Object seiImpl)
+ {
+ // do nothing
+ }
+
+ /** Handlers are beeing called through the HandlerCallback from the EJB interceptor
*/
+ public boolean callRequestHandlerChain(ServiceEndpointInfo seInfo, HandlerType type)
+ {
+ if (type == HandlerType.PRE)
+ return handlerDelegate.callRequestHandlerChain(seInfo, type);
+ else
+ return true;
+ }
+
+ /** Handlers are beeing called through the HandlerCallback from the EJB interceptor
*/
+ public boolean callResponseHandlerChain(ServiceEndpointInfo seInfo, HandlerType type)
+ {
+ if (type == HandlerType.PRE)
+ return handlerDelegate.callResponseHandlerChain(seInfo, type);
+ else
+ return true;
+ }
+
+ /** Handlers are beeing called through the HandlerCallback from the EJB interceptor
*/
+ public boolean callFaultHandlerChain(ServiceEndpointInfo seInfo, HandlerType type,
Exception ex)
+ {
+ if (type == HandlerType.PRE)
+ return handlerDelegate.callFaultHandlerChain(seInfo, type, ex);
+ else
+ return true;
+ }
+}
Property changes on:
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceEndpointInvokerEJB21.java
___________________________________________________________________
Name: svn:keywords
+ Id Revision
Name: svn:eol-style
+ LF
Modified:
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceEndpointPublisher.java
===================================================================
---
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceEndpointPublisher.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceEndpointPublisher.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -79,8 +79,14 @@
public String destroyServiceEndpoint(UnifiedDeploymentInfo udi) throws Exception
{
URL warURL = udi.webappURL;
+ if (warURL == null)
+ {
+ log.error("Cannot obtain waURL for: " + udi.name);
+ return "FAIL";
+ }
+
log.debug("destroyServiceEndpoint: " + warURL);
-
+
DeploymentContext context = contextMap.get(warURL.toExternalForm());
if (context != null)
{
Modified:
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceRefHandler.java
===================================================================
---
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceRefHandler.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/integration-jboss50/src/main/java/org/jboss/ws/integration/jboss50/ServiceRefHandler.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -39,7 +39,7 @@
import org.jboss.virtual.VirtualFile;
import org.jboss.webservice.metadata.serviceref.ServiceRefMetaData;
import org.jboss.ws.WSException;
-import org.jboss.ws.core.jaxrpc.ServiceReferenceable;
+import org.jboss.ws.core.jaxrpc.client.ServiceReferenceable;
import org.jboss.ws.metadata.builder.jaxrpc.JAXRPCClientDeployment;
import org.jboss.ws.metadata.j2ee.UnifiedServiceRefMetaData;
import org.jboss.ws.metadata.jaxrpcmapping.JavaWsdlMapping;
Deleted:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -1,626 +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;
-
-// $Id$
-
-import java.rmi.RemoteException;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.LinkedHashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import javax.xml.namespace.QName;
-import javax.xml.rpc.Call;
-import javax.xml.rpc.JAXRPCException;
-import javax.xml.rpc.ParameterMode;
-import javax.xml.rpc.ServiceException;
-import javax.xml.rpc.Stub;
-import javax.xml.rpc.encoding.SerializerFactory;
-import javax.xml.rpc.soap.SOAPFaultException;
-import javax.xml.soap.SOAPException;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.Constants;
-import org.jboss.ws.core.CommonClient;
-import org.jboss.ws.core.CommonMessageContext;
-import org.jboss.ws.core.WSTimeoutException;
-import org.jboss.ws.core.jaxrpc.binding.JBossXBDeserializerFactory;
-import org.jboss.ws.core.jaxrpc.binding.JBossXBSerializerFactory;
-import org.jboss.ws.core.jaxrpc.handler.HandlerChainBaseImpl;
-import org.jboss.ws.core.jaxrpc.handler.SOAPMessageContextJAXRPC;
-import org.jboss.ws.core.soap.MessageContextAssociation;
-import org.jboss.ws.core.utils.JavaUtils;
-import org.jboss.ws.extensions.xop.XOPContext;
-import org.jboss.ws.metadata.umdm.EndpointMetaData;
-import org.jboss.ws.metadata.umdm.OperationMetaData;
-import org.jboss.ws.metadata.umdm.ParameterMetaData;
-import org.jboss.ws.metadata.umdm.ServiceMetaData;
-import org.jboss.ws.metadata.umdm.TypesMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
-import org.jboss.ws.metadata.wsdl.xmlschema.JBossXSModel;
-
-/** Provides support for the dynamic invocation of a service endpoint.
- * The javax.xml.rpc.Service interface acts as a factory for the creation of Call
instances.
- *
- * Once a Call instance is created, various setter and getter methods may be used to
configure this Call instance.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 10-Oct-2004
- */
-public class CallImpl extends CommonClient implements Call
-{
- // provide logging
- private static Logger log = Logger.getLogger(CallImpl.class);
-
- // The service that created this call
- private ServiceImpl jaxrpcService;
- // The port type name
- private QName portType;
- // A Map<String,Object> of Call properties
- private Map<String, Object> properties = new HashMap<String, Object>();
-
- // The set of supported properties
- private static final Set<String> standardProperties = new
HashSet<String>();
- static
- {
- standardProperties.add(Call.ENCODINGSTYLE_URI_PROPERTY);
- standardProperties.add(Call.OPERATION_STYLE_PROPERTY);
- standardProperties.add(Call.SESSION_MAINTAIN_PROPERTY);
- standardProperties.add(Call.SOAPACTION_URI_PROPERTY);
- standardProperties.add(Call.SOAPACTION_USE_PROPERTY);
- standardProperties.add(Call.USERNAME_PROPERTY);
- standardProperties.add(Call.PASSWORD_PROPERTY);
-
- standardProperties.add(Stub.ENDPOINT_ADDRESS_PROPERTY);
- standardProperties.add(Stub.SESSION_MAINTAIN_PROPERTY);
- standardProperties.add(Stub.USERNAME_PROPERTY);
- standardProperties.add(Stub.PASSWORD_PROPERTY);
- }
-
- /** Create a call that needs to be configured manually
- */
- CallImpl(ServiceImpl service)
- {
- super(service.getServiceMetaData());
- this.jaxrpcService = service;
-
- if (epMetaData != null)
- setTargetEndpointAddress(epMetaData.getEndpointAddress());
- }
-
- /** Create a call for a known WSDL endpoint.
- *
- * @param epMetaData A WSDLEndpoint
- */
- CallImpl(ServiceImpl service, EndpointMetaData epMetaData)
- {
- super(epMetaData);
- this.jaxrpcService = service;
-
- setTargetEndpointAddress(epMetaData.getEndpointAddress());
- }
-
- /** Create a call for a known WSDL endpoint.
- *
- * @param portName Qualified name for the target service endpoint
- * @throws ServiceException
- */
- CallImpl(ServiceImpl service, QName portName, QName opName) throws ServiceException
- {
- super(service.getServiceMetaData(), portName, opName);
- this.jaxrpcService = service;
-
- if (epMetaData != null)
- setTargetEndpointAddress(epMetaData.getEndpointAddress());
- }
-
- public ServiceImpl getServiceImpl()
- {
- return jaxrpcService;
- }
-
- @Override
- protected Map<String, Object> getRequestContext()
- {
- return properties;
- }
-
- /** Gets the address of a target service endpoint.
- */
- public String getTargetEndpointAddress()
- {
- return (String)properties.get(Stub.ENDPOINT_ADDRESS_PROPERTY);
- }
-
- /** Sets the address of the target service endpoint. This address must correspond to
the transport
- * specified in the binding for this Call instance.
- *
- * @param address Address of the target service endpoint; specified as an URI
- */
- public void setTargetEndpointAddress(String address)
- {
- this.properties.put(Stub.ENDPOINT_ADDRESS_PROPERTY, address);
- }
-
- /** Adds a parameter type and mode for a specific operation.
- */
- public void addParameter(String paramName, QName xmlType, ParameterMode
parameterMode)
- {
- TypeMappingImpl typeMapping =
getEndpointMetaData().getServiceMetaData().getTypeMapping();
- Class javaType = typeMapping.getJavaType(xmlType);
-
- // CTS
com/sun/ts/tests/jaxrpc/api/javax_xml_rpc/Call/AddGetRemoveAllParametersTest1
- // tests addParameter/getParameter without giving the javaType for a custom
parameter
- // IMHO, this flavour of addParameter should only be used for standard types,
where
- // the javaType can be derived from the xmlType
- if (javaType == null)
- {
- log.warn("Register unqualified call parameter for: " + xmlType);
- javaType = new UnqualifiedCallParameter(xmlType).getClass();
- typeMapping.register(javaType, xmlType, null, null);
- }
-
- addParameter(paramName, xmlType, javaType, parameterMode);
- }
-
- /** Adds a parameter type and mode for a specific operation.
- */
- public void addParameter(String paramName, QName xmlType, Class javaType,
ParameterMode mode)
- {
- QName xmlName = new QName(paramName);
- addParameter(xmlName, xmlType, javaType, mode, false);
- }
-
- /** Add a parameter to the current operation description.
- * This is a propriatary extension that gives full control over the parameter
configuration.
- */
- public void addParameter(QName xmlName, QName xmlType, Class javaType, ParameterMode
mode, boolean inHeader)
- {
- if (xmlType == null || javaType == null)
- throw new IllegalArgumentException("Invalid null parameter");
-
- OperationMetaData opMetaData = getOperationMetaData();
- ParameterMetaData paramMetaData = new ParameterMetaData(opMetaData, xmlName,
xmlType, javaType.getName());
- paramMetaData.setMode(mode);
- paramMetaData.setInHeader(inHeader);
- paramMetaData.setIndex(opMetaData.getParameters().size());
- opMetaData.addParameter(paramMetaData);
-
- registerParameterType(xmlType, javaType);
- }
-
- /** Removes all specified parameters from this Call instance. Note that this method
removes only the parameters and
- * not the return type. The setReturnType(null) is used to remove the return type.
- *
- * @throws javax.xml.rpc.JAXRPCException This exception may be thrown If this method
is called when the method isParameterAndReturnSpecRequired returns false for this
Call's operation.
- */
- public void removeAllParameters()
- {
- OperationMetaData opMetaData = getOperationMetaData();
- opMetaData.removeAllParameters();
- }
-
- /** Sets the return type for a specific operation. Invoking setReturnType(null)
removes the return type for this Call object.
- */
- public void setReturnType(QName xmlType)
- {
- Class javaType =
getEndpointMetaData().getServiceMetaData().getTypeMapping().getJavaType(xmlType);
- setReturnType(xmlType, javaType);
- }
-
- /** Sets the return type for a specific operation.
- */
- public void setReturnType(QName xmlType, Class javaType)
- {
- if (xmlType == null || javaType == null)
- throw new IllegalArgumentException("Invalid null parameter");
-
- OperationMetaData opMetaData = getOperationMetaData();
- QName xmlName = new QName(Constants.DEFAULT_RPC_RETURN_NAME);
- String javaTypeName = javaType.getName();
- ParameterMetaData retMetaData = new ParameterMetaData(opMetaData, xmlName, xmlType,
javaTypeName);
- opMetaData.setReturnParameter(retMetaData);
-
- registerParameterType(xmlType, javaType);
- }
-
- /** Invokes a remote method using the one-way interaction mode.
- */
- public void invokeOneWay(Object[] inputParams)
- {
- try
- {
- invokeInternal(operationName, inputParams, true);
- }
- catch (RemoteException ex)
- {
- throw new JAXRPCException(ex);
- }
- }
-
- /** Invokes a specific operation using a synchronous request-response interaction
mode.
- */
- public Object invoke(Object[] inputParams) throws RemoteException
- {
- return invokeInternal(operationName, inputParams, false);
- }
-
- /** Invokes a specific operation using a synchronous request-response interaction
mode.
- */
- public Object invoke(QName operationName, Object[] inputParams) throws
RemoteException
- {
- return invokeInternal(operationName, inputParams, false);
- }
-
- protected CommonMessageContext processPivot(CommonMessageContext requestContext) {
- log.debug("Begin response processing");
- return requestContext;
- }
-
- /** Returns a List values for the output parameters of the last invoked operation.
- *
- * @return java.util.List Values for the output parameters. An empty List is returned
if there are no output values.
- * @throws JAXRPCException If this method is invoked for a one-way operation or is
invoked before any invoke method has been called.
- */
- public List getOutputValues()
- {
- if (epInv == null)
- throw new JAXRPCException("Output params not available");
-
- try
- {
- OperationMetaData opMetaData = getOperationMetaData();
-
- List<Object> objPayload = new ArrayList<Object>();
- for (QName xmlName : epInv.getResponseParamNames())
- {
- Object paramValue = epInv.getResponseParamValue(xmlName);
- if (opMetaData.isDocumentWrapped())
- {
- objPayload = Arrays.asList((Object[])paramValue);
- break;
- }
- else
- {
- objPayload.add(paramValue);
- }
- }
- return objPayload;
- }
- catch (SOAPException ex)
- {
- throw new JAXRPCException("Cannot obtain response payload", ex);
- }
- }
-
- /** Returns a Map of {name, value} for the output parameters of the last invoked
operation.
- * The parameter names in the returned Map are of type java.lang.String.
- *
- * @return Map Output parameters for the last Call.invoke(). Empty Map is returned if
there are no output parameters.
- * @throws JAXRPCException If this method is invoked for a one-way operation or is
invoked before any invoke method has been called.
- */
- public Map getOutputParams()
- {
- if (epInv == null)
- throw new JAXRPCException("Output params not available");
-
- try
- {
- Map<String, Object> outMap = new LinkedHashMap<String, Object>();
- for (QName xmlName : epInv.getResponseParamNames())
- {
- Object value = epInv.getResponseParamValue(xmlName);
- outMap.put(xmlName.getLocalPart(), value);
- }
- return outMap;
- }
- catch (SOAPException ex)
- {
- throw new JAXRPCException("Cannot obtain response payload", ex);
- }
- }
-
- /**
- * Gets the qualified name of the port type.
- *
- * @return Qualified name of the port type
- */
- public QName getPortTypeName()
- {
- if (portType != null)
- {
- return portType;
- }
-
- /* This code could be used to derive the portType from the endpoint meta data.
- * However, it breaks CTS
com/sun/ts/tests/jaxrpc/api/javax_xml_rpc/Call/Client.java#SetGetPortTypeNameTest2
- if (epMetaData != null)
- {
- ServiceMetaData serviceMetaData = epMetaData.getServiceMetaData();
- WSDLDefinitions wsdlDefinitions = serviceMetaData.getWsdlDefinitions();
- WSDLService wsdlService = wsdlDefinitions.getService(new
NCName(serviceMetaData.getName().getLocalPart()));
- WSDLEndpoint wsdlEndpoint = wsdlService.getEndpoint(epMetaData.getName());
- WSDLInterface wsdlInterface = wsdlEndpoint.getInterface();
- return wsdlInterface.getQName();
- }
- */
-
- // CTS
com/sun/ts/tests/jaxrpc/api/javax_xml_rpc/Call/Client.java#SetGetPortTypeNameTest2
- return new QName("");
- }
-
- /**
- * Gets the return type for a specific operation
- *
- * @return Returns the XML type for the return value
- */
- public QName getReturnType()
- {
- QName retType = null;
- if (operationName != null)
- {
- OperationMetaData opDesc = getOperationMetaData();
- ParameterMetaData retMetaData = opDesc.getReturnParameter();
- if (retMetaData != null)
- retType = retMetaData.getXmlType();
- }
- return retType;
- }
-
- /**
- * Sets the qualified name of the interface.
- *
- * @param portType - Qualified name of the port type
- */
- public void setPortTypeName(QName portType)
- {
- this.portType = portType;
- }
-
- /**
- * Indicates whether addParameter and setReturnType methods are to be invoked to
specify the parameter and return
- * type specification for a specific operation.
- *
- * @param opName Qualified name of the operation
- * @return Returns true if the Call implementation class requires addParameter and
setReturnType to be invoked in the client code for the specified operation. This method
returns false otherwise.
- * @throws IllegalArgumentException If invalid operation name is specified
- */
- public boolean isParameterAndReturnSpecRequired(QName opName)
- {
- setOperationName(opName);
- OperationMetaData opMetaData = getOperationMetaData();
- return opMetaData.getParameters().size() == 0 &&
opMetaData.getReturnParameter() == null;
- }
-
- /** Gets the names of configurable properties supported by this Call object.
- * @return Iterator for the property names
- */
- public Iterator getPropertyNames()
- {
- return standardProperties.iterator();
- }
-
- /** Gets the value of a named property.
- */
- public Object getProperty(String name)
- {
- if (null == name)
- throw new JAXRPCException("Unsupported property: " + name);
- // CTS:
com/sun/ts/tests/jaxrpc/api/javax_xml_rpc/Call/Client.java#SetGetPropertyTest2
- if (name.startsWith("javax.xml.rpc") &&
standardProperties.contains(name) == false)
- throw new JAXRPCException("Unsupported property: " + name);
-
- return properties.get(name);
- }
-
- /** Sets the value for a named property.
- */
- public void setProperty(String name, Object value)
- {
- if (null == name)
- throw new JAXRPCException("Unsupported property: " + name);
- // CTS:
com/sun/ts/tests/jaxrpc/api/javax_xml_rpc/Call/Client.java#SetGetPropertyTest2
- if (name.startsWith("javax.xml.rpc") &&
standardProperties.contains(name) == false)
- throw new JAXRPCException("Unsupported property: " + name);
-
- properties.put(name, value);
- }
-
- /** Removes a named property.
- */
- public void removeProperty(String name)
- {
- properties.remove(name);
- }
-
- /** Gets the XML type of a parameter by name.
- */
- public QName getParameterTypeByName(String paramName)
- {
- OperationMetaData opMetaData = getOperationMetaData();
- ParameterMetaData paramMetaData = opMetaData.getParameter(new QName(paramName));
- if (paramMetaData != null)
- return paramMetaData.getXmlType();
- else return null;
- }
-
- @Override
- protected void setInboundContextProperties()
- {
- }
-
- @Override
- protected void setOutboundContextProperties()
- {
- }
-
- private Object invokeInternal(QName opName, Object[] inputParams, boolean forceOneway)
throws RemoteException
- {
- if (opName.equals(operationName) == false)
- setOperationName(opName);
-
- OperationMetaData opMetaData = getOperationMetaData();
-
- // Check or generate the the schema if this call is unconfigured
- generateOrUpdateSchemas(opMetaData);
-
- // Associate a message context with the current thread
- SOAPMessageContextJAXRPC msgContext = new SOAPMessageContextJAXRPC();
- MessageContextAssociation.pushMessageContext(msgContext);
- Object retObj = null;
- try
- {
- retObj = super.invoke(opName, inputParams, properties, forceOneway);
- return retObj;
- }
- catch (SOAPFaultException ex)
- {
- log.error("Call invocation failed", ex);
- String faultCode = ex.getFaultCode().getLocalPart();
- throw new RemoteException("Call invocation failed with code [" +
faultCode + "] because of: " + ex.getFaultString(), ex);
- }
- catch (RemoteException rex)
- {
- throw rex;
- }
- catch (WSTimeoutException toex)
- {
- throw toex;
- }
- catch (Exception ex)
- {
- throw new RemoteException("Call invocation failed", ex);
- }
- finally
- {
- // Reset the message context association
- MessageContextAssociation.popMessageContext();
- }
- }
-
- @Override
- protected boolean callRequestHandlerChain(QName portName, HandlerType type)
- {
- SOAPMessageContextJAXRPC msgContext =
(SOAPMessageContextJAXRPC)MessageContextAssociation.peekMessageContext();
- HandlerChainBaseImpl handlerChain =
(HandlerChainBaseImpl)jaxrpcService.getHandlerChain(portName);
- boolean status = (handlerChain != null ? handlerChain.handleRequest(msgContext,
type) : true);
-
- if (type == HandlerType.ENDPOINT)
- XOPContext.visitAndRestoreXOPData();
-
- return status;
- }
-
- @Override
- protected boolean callResponseHandlerChain(QName portName, HandlerType type)
- {
- SOAPMessageContextJAXRPC msgContext =
(SOAPMessageContextJAXRPC)MessageContextAssociation.peekMessageContext();
- HandlerChainBaseImpl handlerChain =
(HandlerChainBaseImpl)jaxrpcService.getHandlerChain(portName);
-
- boolean status = true;
- if (handlerChain != null)
- {
- status = handlerChain.handleResponse(msgContext, type);
- }
- return status;
- }
-
- /** Generate or update the XSD schema for all parameters and the return.
- * This should only be done when the Call is unconfigured, hence there is no WSDL
- */
- private void generateOrUpdateSchemas(OperationMetaData opMetaData)
- {
- ServiceMetaData serviceMetaData =
opMetaData.getEndpointMetaData().getServiceMetaData();
- if (serviceMetaData.getWsdlLocation() == null)
- {
- TypesMetaData typesMetaData = serviceMetaData.getTypesMetaData();
- for (ParameterMetaData paramMetaData : opMetaData.getParameters())
- {
- generateOrUpdateParameterSchema(typesMetaData, paramMetaData);
- }
-
- ParameterMetaData retMetaData = opMetaData.getReturnParameter();
- if (retMetaData != null)
- {
- generateOrUpdateParameterSchema(typesMetaData, retMetaData);
- }
- }
- }
-
- /** Generate or update the XSD schema for a given parameter
- * This should only be done if the parameter is not an attachment
- */
- private void generateOrUpdateParameterSchema(TypesMetaData typesMetaData,
ParameterMetaData paramMetaData)
- {
- if (paramMetaData.isSwA() == false)
- {
- QName xmlType = paramMetaData.getXmlType();
- Class javaType = paramMetaData.getJavaType();
-
- ServiceMetaData serviceMetaData = getEndpointMetaData().getServiceMetaData();
- TypeMappingImpl typeMapping = serviceMetaData.getTypeMapping();
- SerializerFactory serFactory = typeMapping.getSerializer(javaType, xmlType);
- if (serFactory instanceof JBossXBSerializerFactory)
- {
- SchemaGenerator xsdGenerator = new SchemaGenerator();
- JBossXSModel model = xsdGenerator.generateXSDSchema(xmlType, javaType);
- typesMetaData.addSchemaModel(model);
- }
- }
- }
-
- private void registerParameterType(QName xmlType, Class javaType)
- {
- ServiceMetaData serviceMetaData = getEndpointMetaData().getServiceMetaData();
-
- String nsURI = xmlType.getNamespaceURI();
- if (Constants.NS_ATTACHMENT_MIME_TYPE.equals(nsURI) == false)
- {
- TypeMappingImpl typeMapping = serviceMetaData.getTypeMapping();
- Class regJavaType = typeMapping.getJavaType(xmlType);
- if (regJavaType == null)
- {
- typeMapping.register(javaType, xmlType, new JBossXBSerializerFactory(), new
JBossXBDeserializerFactory());
- }
- else if (regJavaType != null && JavaUtils.isAssignableFrom(regJavaType,
javaType) == false)
- {
- throw new IllegalArgumentException("Different java type already
registered: " + regJavaType.getName());
- }
- }
- }
-
- @Override
- public void setConfigName(String configName, String configFile)
- {
- EndpointMetaData epMetaData = getEndpointMetaData();
- epMetaData.setConfigName(configName, configFile);
-
- // Reinitialize the client handler chain
- jaxrpcService.setupHandlerChain(epMetaData);
- }
-}
Deleted:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/HandlerRegistryImpl.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/HandlerRegistryImpl.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/HandlerRegistryImpl.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -1,119 +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;
-
-// $Id$
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import javax.xml.namespace.QName;
-import javax.xml.rpc.handler.HandlerChain;
-import javax.xml.rpc.handler.HandlerInfo;
-import javax.xml.rpc.handler.HandlerRegistry;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.core.jaxrpc.handler.ClientHandlerChain;
-import org.jboss.ws.metadata.umdm.EndpointMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaDataJAXRPC;
-import org.jboss.ws.metadata.umdm.ServiceMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
-
-/**
- * Provides support for the programmatic configuration of
- * handlers in a HandlerRegistry.
- *
- * A handler chain is registered per service endpoint, as indicated by the
- * qualified name of a port. The getHandlerChain returns the handler chain
- * (as a java.util.List) for the specified service endpoint. The returned
- * handler chain is configured using the java.util.List interface. Each element
- * in this list is required to be of the Java type
- * javax.xml.rpc.handler.HandlerInfo.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 20-Jul-2005
- */
-public class HandlerRegistryImpl implements HandlerRegistry
-{
- // provide logging
- private static Logger log = Logger.getLogger(HandlerRegistryImpl.class);
-
- // Map<QName,HandlerChain> the endpoint name to a HandlerChain
- private Map<QName, HandlerChain> handlerChains = new HashMap<QName,
HandlerChain>();
- // Maps the port name to a list of HandlerInfo objects
- private Map<QName, List<HandlerInfo>> handlerInfos = new HashMap<QName,
List<HandlerInfo>>();
- // The service this registry is associated with
- private ServiceMetaData serviceMetaData;
-
- public HandlerRegistryImpl(ServiceMetaData serviceMetaData)
- {
- this.serviceMetaData = serviceMetaData;
- }
-
- public List getHandlerChain(QName portName)
- {
- List<HandlerInfo> list = handlerInfos.get(portName);
- if (list == null)
- list = new ArrayList<HandlerInfo>();
-
- return new ArrayList(list);
- }
-
- public void setHandlerChain(QName portName, List chain)
- {
- registerClientHandlerChain(portName, chain, null);
- }
-
- /** Get the handler chain for the given endpoint name, maybe null.
- */
- HandlerChain getHandlerChainInstance(QName portName)
- {
- HandlerChain handlerChain = handlerChains.get(portName);
- return handlerChain;
- }
-
- /** Register a handler chain for the given endpoint name
- */
- void registerClientHandlerChain(QName portName, List<HandlerInfo> infos,
Set<String> roles)
- {
- ClientHandlerChain chain = new ClientHandlerChain(infos, roles);
- handlerChains.put(portName, chain);
- handlerInfos.put(portName, infos);
-
- EndpointMetaData epMetaData = serviceMetaData.getEndpoint(portName);
- if (epMetaData == null)
- throw new IllegalStateException("Cannot obtain endpoint meta data for:
" + portName);
-
- epMetaData.clearHandlers();
- for (HandlerInfo info : infos)
- {
- HandlerMetaDataJAXRPC handler = new HandlerMetaDataJAXRPC(epMetaData,
HandlerType.ENDPOINT);
- handler.setHandlerClassName(info.getHandlerClass().getName());
- handler.setSoapRoles(roles);
- log.debug("Add handler to: " + portName + handler);
- epMetaData.addHandler(handler);
- }
- }
-}
Deleted:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/PortProxy.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/PortProxy.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/PortProxy.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -1,216 +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;
-
-// $Id$
-
-import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.Method;
-import java.rmi.RemoteException;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import javax.xml.namespace.QName;
-import javax.xml.rpc.JAXRPCException;
-import javax.xml.rpc.Stub;
-import javax.xml.rpc.handler.HandlerInfo;
-import javax.xml.rpc.soap.SOAPFaultException;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.WSException;
-import org.jboss.ws.core.StubExt;
-import org.jboss.ws.core.utils.JavaUtils;
-import org.jboss.ws.metadata.umdm.EndpointMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaDataJAXRPC;
-import org.jboss.ws.metadata.umdm.OperationMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerInitParam;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
-
-/**
- * The dynamic proxy that delegates to the underlying Call implementation
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 07-Jan-2005
- */
-public class PortProxy implements InvocationHandler
-{
- // provide logging
- private static final Logger log = Logger.getLogger(PortProxy.class);
-
- // The underlying Call
- private CallImpl call;
- // List<Method> of the Stub methods
- private List stubMethods;
- // List<Method> of the Object methods
- private List objectMethods;
-
- // The set of standard properties
- private static final Set<String> standardProperties = new
HashSet<String>();
- static
- {
- standardProperties.add(Stub.ENDPOINT_ADDRESS_PROPERTY);
- standardProperties.add(Stub.SESSION_MAINTAIN_PROPERTY);
- standardProperties.add(Stub.USERNAME_PROPERTY);
- standardProperties.add(Stub.PASSWORD_PROPERTY);
- }
-
- // The map of jboss-ws4ee supported properties
- private static final Map<String,String> legacyPropertyMap = new
HashMap<String,String>();
- static
- {
- legacyPropertyMap.put("org.jboss.webservice.client.timeout",
StubExt.PROPERTY_CLIENT_TIMEOUT);
- legacyPropertyMap.put("org.jboss.webservice.keyStore",
StubExt.PROPERTY_KEY_STORE);
- legacyPropertyMap.put("org.jboss.webservice.keyStorePassword",
StubExt.PROPERTY_KEY_STORE_PASSWORD);
- legacyPropertyMap.put("org.jboss.webservice.keyStoreType",
StubExt.PROPERTY_KEY_STORE_TYPE);
- legacyPropertyMap.put("org.jboss.webservice.trustStore",
StubExt.PROPERTY_TRUST_STORE);
- legacyPropertyMap.put("org.jboss.webservice.trustStorePassword",
StubExt.PROPERTY_TRUST_STORE_PASSWORD);
- legacyPropertyMap.put("org.jboss.webservice.trustStoreType",
StubExt.PROPERTY_TRUST_STORE_TYPE);
- }
-
- public PortProxy(CallImpl call)
- {
- this.call = call;
- this.stubMethods = new ArrayList(Arrays.asList(StubExt.class.getMethods()));
- this.stubMethods.addAll(Arrays.asList(Stub.class.getMethods()));
- this.objectMethods = Arrays.asList(Object.class.getMethods());
- }
-
- /** Processes a method invocation on a proxy instance and returns the result.
- */
- public Object invoke(Object proxy, Method method, Object[] args) throws Throwable
- {
- // An invocation on the Stub interface
- String methodName = method.getName();
- if (stubMethods.contains(method))
- {
- if (methodName.equals("_getPropertyNames"))
- {
- return call.getPropertyNames();
- }
- else if (methodName.equals("_getProperty"))
- {
- return getProperty((String)args[0]);
- }
- else if (methodName.equals("_setProperty"))
- {
- setProperty((String)args[0], args[1]);
- return null;
- }
- else
- {
- Method callMethod = CallImpl.class.getMethod(methodName,
method.getParameterTypes());
- return callMethod.invoke(call, args);
- }
- }
-
- // An invocation on proxy's Object class
- else if (objectMethods.contains(method))
- {
- Method callMethod = CallImpl.class.getMethod(methodName,
method.getParameterTypes());
- return callMethod.invoke(call, args);
- }
-
- // An invocation on the service endpoint interface
- else
- {
- EndpointMetaData epMetaData = call.getEndpointMetaData();
- OperationMetaData opMetaData = epMetaData.getOperation(method);
- if (opMetaData == null)
- throw new WSException("Cannot obtain operation meta data for: " +
methodName);
-
- call.setOperationName(opMetaData.getQName());
-
- try
- {
- if (opMetaData.isOneWay())
- {
- call.invokeOneWay(args);
- return null;
- }
- else
- {
- Object retObj = call.invoke(args);
- if (retObj != null)
- {
- Class retType = method.getReturnType();
- if (retType == null)
- throw new WSException("Return value not supported by: " +
opMetaData);
-
- if (JavaUtils.isPrimitive(retType))
- retObj = JavaUtils.getPrimitiveValueArray(retObj);
- }
- return retObj;
- }
- }
- catch (Exception ex)
- {
- handleException(ex);
- return null;
- }
- }
- }
-
- private Object getProperty(String name)
- {
- name = assertPropertyName(name);
- return call.getProperty(name);
- }
-
- private void setProperty(String name, Object value)
- {
- name = assertPropertyName(name);
- call.setProperty(name, value);
- }
-
- private String assertPropertyName(String name)
- {
- if (name != null && name.startsWith("javax.xml.rpc") &&
standardProperties.contains(name) == false)
- throw new JAXRPCException("Unsupported property: " + name);
-
- if (legacyPropertyMap.keySet().contains(name))
- {
- String jbosswsName = legacyPropertyMap.get(name);
- log.warn("Legacy propery '" + name + "' mapped to
'" + jbosswsName + "'");
- name = jbosswsName;
- }
-
- return name;
- }
-
- private void handleException(Exception ex) throws Throwable
- {
- Throwable th = ex;
- if (ex instanceof RemoteException && ex.getCause() instanceof
SOAPFaultException)
- {
- SOAPFaultException faultEx = (SOAPFaultException)ex.getCause();
- if (faultEx.getCause() != null)
- th = faultEx.getCause();
- }
- throw th;
- }
-}
Deleted:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceExt.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceExt.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceExt.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -1,42 +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;
-
-//$Id$
-
-import javax.xml.rpc.Service;
-import javax.xml.rpc.handler.HandlerRegistry;
-
-/**
- * Extends the JAXRPC Service with JBoss propriatary behaviour
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 27-Jan-2005
- */
-public interface ServiceExt extends Service
-{
- /**
- * Get a HandlerRegistry that can be used to dynamically
- * change the client side handler chain
- */
- HandlerRegistry getDynamicHandlerRegistry();
-}
Deleted:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceFactoryImpl.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceFactoryImpl.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceFactoryImpl.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -1,160 +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;
-
-// $Id$
-
-import java.net.URL;
-import java.util.Properties;
-
-import javax.xml.namespace.QName;
-import javax.xml.rpc.Service;
-import javax.xml.rpc.ServiceException;
-import javax.xml.rpc.ServiceFactory;
-
-import org.jboss.logging.Logger;
-import org.jboss.util.NotImplementedException;
-
-/**
- * Service class acts as a factory for:
- * <ul>
- * <li>Dynamic proxy for the target service endpoint.
- * <li>Instance of the type javax.xml.rpc.Call for the dynamic invocation of a
remote operation on the target service endpoint.
- * <li>Instance of a generated stub class
- * </ul>
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 10-Oct-2004
- */
-public class ServiceFactoryImpl extends ServiceFactory
-{
- // provide logging
- private final Logger log = Logger.getLogger(ServiceFactoryImpl.class);
-
- /**
- * Create an instance of the generated service implementation class for a given
service interface, if available.
- *
- * @param serviceInterface Service interface
- * @return A Service
- * @throws ServiceException If there is any error while creating the specified
service, including the case where a
- * generated service implementation class cannot be located
- */
- public Service loadService(Class serviceInterface) throws ServiceException
- {
- throw new NotImplementedException();
- }
-
- /**
- * Create an instance of the generated service implementation class for a given
service interface, if available.
- * An implementation may use the provided wsdlDocumentLocation and properties to help
locate the generated implementation class.
- * If no such class is present, a ServiceException will be thrown.
- *
- * @param wsdlDocumentLocation URL for the WSDL document location for the service or
null
- * @param serviceInterface Service interface
- * @param props A set of implementation-specific properties to help
locate the generated service implementation class
- * @return A Service
- * @throws ServiceException If there is any error while creating the specified
service, including the case where a
- * generated service implementation class cannot be located
- */
- public Service loadService(URL wsdlDocumentLocation, Class serviceInterface,
Properties props) throws ServiceException
- {
- throw new NotImplementedException();
- }
-
- /**
- * Create an instance of the generated service implementation class for a given
service, if available.
- * The service is uniquely identified by the wsdlDocumentLocation and serviceName
arguments.
- * An implementation may use the provided properties to help locate the generated
implementation class.
- * If no such class is present, a ServiceException will be thrown.
- *
- * @param wsdlDocumentLocation URL for the WSDL document location for the service or
null
- * @param serviceName Qualified name for the service
- * @param props A set of implementation-specific properties to help
locate the generated service implementation class
- * @return A Service
- * @throws ServiceException If there is any error while creating the specified
service, including the case where a generated service implementation class cannot be
located
- */
- public Service loadService(URL wsdlDocumentLocation, QName serviceName, Properties
props) throws ServiceException
- {
- throw new NotImplementedException();
- }
-
- /**
- * Create a <code>Service</code> instance.
- *
- * @param serviceName QName for the service
- * @return Service.
- * @throws ServiceException If any error in creation of the specified service
- */
- public Service createService(QName serviceName) throws ServiceException
- {
- return new ServiceImpl(serviceName);
- }
-
- /**
- * Create a <code>Service</code> instance.
- *
- * @param wsdlURL URL for the WSDL document location
- * @param serviceName QName for the service.
- * @return Service.
- * @throws ServiceException If any error in creation of the specified service
- */
- public Service createService(URL wsdlURL, QName serviceName) throws ServiceException
- {
- ClassLoader cl = Thread.currentThread().getContextClassLoader();
-
- URL mappingURL = cl.getResource("META-INF/jaxrpc-mapping.xml");
- if (mappingURL != null)
- log.info("Use jaxrpc-mapping from: " + mappingURL);
-
- return createService(wsdlURL, serviceName, mappingURL, null);
- }
-
- /**
- * Create a <code>Service</code> instance.
- *
- * @param wsdlURL URL for the WSDL document location
- * @param serviceName QName for the service.
- * @param mappingURL URL for the jaxrpc-mapping.xml document location
- * @return Service.
- * @throws ServiceException If any error in creation of the specified service
- */
- public Service createService(URL wsdlURL, QName serviceName, URL mappingURL) throws
ServiceException
- {
- return createService(wsdlURL, serviceName, mappingURL, null);
- }
-
- /**
- * Create a <code>Service</code> instance.
- *
- * @param wsdlURL URL for the WSDL document location
- * @param serviceName QName for the service.
- * @param mappingURL URL for the jaxrpc-mapping.xml document location
- * @param securityURL URL for the jboss-ws-security.xml file
- * @return Service.
- * @throws ServiceException If any error in creation of the specified service
- */
- public Service createService(URL wsdlURL, QName serviceName, URL mappingURL, URL
securityURL) throws ServiceException
- {
- ServiceImpl service = new ServiceImpl(serviceName, wsdlURL, mappingURL,
securityURL);
- return service;
- }
-}
Deleted:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceImpl.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceImpl.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceImpl.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -1,451 +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;
-
-// $Id$
-
-import java.lang.reflect.Proxy;
-import java.net.URL;
-import java.rmi.Remote;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-
-import javax.xml.namespace.QName;
-import javax.xml.rpc.Call;
-import javax.xml.rpc.ServiceException;
-import javax.xml.rpc.Stub;
-import javax.xml.rpc.encoding.TypeMappingRegistry;
-import javax.xml.rpc.handler.HandlerChain;
-import javax.xml.rpc.handler.HandlerInfo;
-import javax.xml.rpc.handler.HandlerRegistry;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.core.StubExt;
-import org.jboss.ws.metadata.builder.jaxrpc.JAXRPCClientMetaDataBuilder;
-import org.jboss.ws.metadata.j2ee.UnifiedServiceRefMetaData;
-import org.jboss.ws.metadata.jaxrpcmapping.JavaWsdlMapping;
-import org.jboss.ws.metadata.umdm.EndpointMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaDataJAXRPC;
-import org.jboss.ws.metadata.umdm.OperationMetaData;
-import org.jboss.ws.metadata.umdm.ResourceLoaderAdapter;
-import org.jboss.ws.metadata.umdm.ServiceMetaData;
-import org.jboss.ws.metadata.umdm.UnifiedMetaData;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerInitParam;
-import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
-import org.jboss.ws.metadata.wsse.WSSecurityConfiguration;
-
-/**
- * Service class acts as a factory for:
- * <ul>
- * <li>Dynamic proxy for the target service endpoint.
- * <li>Instance of the type javax.xml.rpc.Call for the dynamic invocation of a
- * remote operation on the target service endpoint.
- * <li>Instance of a generated stub class
- * </ul>
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 10-Oct-2004
- */
-public class ServiceImpl implements ServiceExt
-{
- // provide logging
- private static final Logger log = Logger.getLogger(ServiceImpl.class);
-
- // The service meta data that is associated with this JAXRPC Service
- private ServiceMetaData serviceMetaData;
-
- // The optional WSDL location
- private URL wsdlLocation;
-
- // The handler registry
- private HandlerRegistryImpl handlerRegistry;
-
- /**
- * Construct a Service without WSDL meta data
- */
- ServiceImpl(QName serviceName)
- {
- UnifiedMetaData wsMetaData = new UnifiedMetaData(new ResourceLoaderAdapter());
- serviceMetaData = new ServiceMetaData(wsMetaData, serviceName);
- handlerRegistry = new HandlerRegistryImpl(serviceMetaData);
- }
-
- /**
- * Construct a Service that has access to some WSDL meta data
- */
- ServiceImpl(QName serviceName, URL wsdlURL, URL mappingURL, URL securityURL)
- {
- this.wsdlLocation = wsdlURL;
- JAXRPCClientMetaDataBuilder builder = new JAXRPCClientMetaDataBuilder();
-
- ClassLoader ctxClassLoader = Thread.currentThread().getContextClassLoader();
-
- serviceMetaData = builder.buildMetaData(serviceName, wsdlURL, mappingURL,
securityURL, null, ctxClassLoader);
- handlerRegistry = new HandlerRegistryImpl(serviceMetaData);
- }
-
- /**
- * Construct a Service that has access to some WSDL meta data
- */
- ServiceImpl(QName serviceName, URL wsdlURL, JavaWsdlMapping mappingURL,
WSSecurityConfiguration securityConfig, UnifiedServiceRefMetaData serviceRefMetaData)
- {
- this.wsdlLocation = wsdlURL;
- JAXRPCClientMetaDataBuilder builder = new JAXRPCClientMetaDataBuilder();
-
- ClassLoader ctxClassLoader = Thread.currentThread().getContextClassLoader();
-
- serviceMetaData = builder.buildMetaData(serviceName, wsdlURL, mappingURL,
securityConfig, serviceRefMetaData, ctxClassLoader);
- handlerRegistry = new HandlerRegistryImpl(serviceMetaData);
- }
-
- public ServiceMetaData getServiceMetaData()
- {
- return serviceMetaData;
- }
-
- /**
- * Gets the location of the WSDL document for this Service.
- *
- * @return URL for the location of the WSDL document for this service
- */
- public URL getWSDLDocumentLocation()
- {
- return wsdlLocation;
- }
-
- /**
- * Gets the name of this service.
- *
- * @return Qualified name of this service
- */
- public QName getServiceName()
- {
- return serviceMetaData.getServiceName();
- }
-
- /**
- * Creates a Call instance.
- *
- * @param portName
- * Qualified name for the target service endpoint
- * @return Call instance
- * @throws javax.xml.rpc.ServiceException
- * If any error in the creation of the Call object
- */
- public Call createCall(QName portName) throws ServiceException
- {
- String nsURI = portName.getNamespaceURI();
- serviceMetaData.assertTargetNamespace(nsURI);
- return new CallImpl(this, portName, null);
- }
-
- /**
- * Creates a Call instance.
- *
- * @param portName
- * Qualified name for the target service endpoint
- * @param operationName
- * Name of the operation for which this Call object is to be
- * created.
- * @return Call instance
- * @throws javax.xml.rpc.ServiceException
- * If any error in the creation of the Call object
- */
- public Call createCall(QName portName, String operationName) throws ServiceException
- {
- String nsURI = portName.getNamespaceURI();
- serviceMetaData.assertTargetNamespace(nsURI);
- QName opName = new QName(nsURI, operationName);
- return new CallImpl(this, portName, opName);
- }
-
- /**
- * Creates a Call instance.
- *
- * @param portName
- * Qualified name for the target service endpoint
- * @param opName
- * Qualified name of the operation for which this Call object is
- * to be created.
- * @return Call instance
- * @throws javax.xml.rpc.ServiceException
- * If any error in the creation of the Call object
- */
- public Call createCall(QName portName, QName opName) throws ServiceException
- {
- serviceMetaData.assertTargetNamespace(portName.getNamespaceURI());
- serviceMetaData.assertTargetNamespace(opName.getNamespaceURI());
- return new CallImpl(this, portName, opName);
- }
-
- /**
- * Creates a Call object not associated with specific operation or target
- * service endpoint. This Call object needs to be configured using the
- * setter methods on the Call interface.
- *
- * @return Call object
- * @throws javax.xml.rpc.ServiceException
- * If any error in the creation of the Call object
- */
- public Call createCall() throws ServiceException
- {
- return new CallImpl(this);
- }
-
- /**
- * Gets an array of preconfigured Call objects for invoking operations on
- * the specified port. There is one Call object per operation that can be
- * invoked on the specified port. Each Call object is pre-configured and
- * does not need to be configured using the setter methods on Call
- * interface. <p/> Each invocation of the getCalls method returns a new
- * array of preconfigured Call objects <p/> This method requires the Service
- * implementation class to have access to the WSDL related metadata.
- *
- * @param portName
- * Qualified name for the target service endpoint
- * @return Call[] Array of pre-configured Call objects
- * @throws javax.xml.rpc.ServiceException
- * If this Service class does not have access to the required
- * WSDL metadata or if an illegal endpointName is specified.
- */
- public Call[] getCalls(QName portName) throws ServiceException
- {
- EndpointMetaData epMetaData = serviceMetaData.getEndpoint(portName);
- if (epMetaData == null)
- throw new ServiceException("Cannot find endpoint for name: " +
portName);
-
- List<Call> calls = new ArrayList<Call>();
- for (OperationMetaData opMetaData : epMetaData.getOperations())
- {
- Call call = createCall(portName, opMetaData.getQName());
- calls.add(call);
- }
-
- Call[] callArr = new Call[calls.size()];
- calls.toArray(callArr);
-
- return callArr;
- }
-
- /**
- * J2EE components should not use the getHandlerRegistry() method. A
- * container provider must throw a java.lang.UnsupportedOperationException
- * from the getHandlerRegistry() method of the Service Interface. Handler
- * support is documented in Chapter 6 Handlers.
- */
- public HandlerRegistry getHandlerRegistry()
- {
- throw new UnsupportedOperationException("Components should not use the
getHandlerRegistry() method.");
- }
-
- /**
- * Get a HandlerRegistry that can be used to dynamically change the client
- * side handler chain associated with a given endpoint.
- */
- public HandlerRegistry getDynamicHandlerRegistry()
- {
- return handlerRegistry;
- }
-
- /**
- * J2EE components should not use the getTypeMappingRegistry() method. A
- * container provider must throw a java.lang.UnsupportedOperationException
- * from the getTypeMappingRegistry() method of the Service Interface.
- */
- public TypeMappingRegistry getTypeMappingRegistry()
- {
- throw new UnsupportedOperationException("Components should not use the
getTypeMappingRegistry() method.");
- }
-
- /**
- * Returns an Iterator for the list of QNames of service endpoints grouped
- * by this service
- *
- * @return Returns java.util.Iterator with elements of type
- * javax.xml.namespace.QName
- * @throws javax.xml.rpc.ServiceException
- * If this Service class does not have access to the required
- * WSDL metadata
- */
- public Iterator getPorts() throws ServiceException
- {
- ArrayList<QName> list = new ArrayList<QName>();
- if (serviceMetaData != null)
- {
- for (EndpointMetaData epMetaData : serviceMetaData.getEndpoints())
- {
- list.add(epMetaData.getPortName());
- }
- }
- return list.iterator();
- }
-
- /**
- * The getPort method returns either an instance of a generated stub
- * implementation class or a dynamic proxy. The parameter
- * serviceEndpointInterface specifies the service endpoint interface that is
- * supported by the returned stub or proxy. In the implementation of this
- * method, the JAX-RPC runtime system takes the responsibility of selecting
- * a protocol binding (and a port) and configuring the stub accordingly. The
- * returned Stub instance should not be reconfigured by the client.
- */
- public Remote getPort(Class seiClass) throws ServiceException
- {
- if (seiClass == null)
- throw new IllegalArgumentException("SEI class cannot be null");
-
- String seiName = seiClass.getName();
- if (Remote.class.isAssignableFrom(seiClass) == false)
- throw new ServiceException("SEI does not implement java.rmi.Remote: "
+ seiName);
-
- if (serviceMetaData == null)
- throw new ServiceException("Service meta data not available");
-
- try
- {
- EndpointMetaData epMetaData =
serviceMetaData.getEndpointByServiceEndpointInterface(seiName);
- if (epMetaData == null && serviceMetaData.getEndpoints().size() == 1)
- {
- epMetaData = serviceMetaData.getEndpoints().get(0);
- epMetaData.setServiceEndpointInterfaceName(seiName);
- }
-
- if (epMetaData == null)
- throw new ServiceException("Cannot find endpoint meta data for: " +
seiName);
-
- return createProxy(seiClass, epMetaData);
- }
- catch (ServiceException ex)
- {
- throw ex;
- }
- catch (Exception ex)
- {
- throw new ServiceException("Cannot create proxy", ex);
- }
- }
-
- /**
- * The getPort method returns either an instance of a generated stub
- * implementation class or a dynamic proxy. A service client uses this
- * dynamic proxy to invoke operations on the target service endpoint. The
- * serviceEndpointInterface specifies the service endpoint interface that is
- * supported by the created dynamic proxy or stub instance.
- */
- public Remote getPort(QName portName, Class seiClass) throws ServiceException
- {
- if (seiClass == null)
- throw new IllegalArgumentException("SEI class cannot be null");
-
- if (serviceMetaData == null)
- throw new ServiceException("Service meta data not available");
-
- String seiName = seiClass.getName();
- if (Remote.class.isAssignableFrom(seiClass) == false)
- throw new ServiceException("SEI does not implement java.rmi.Remote: "
+ seiName);
-
- EndpointMetaData epMetaData = serviceMetaData.getEndpoint(portName);
- if (epMetaData == null)
- throw new ServiceException("Cannot obtain endpoint meta data for: " +
portName);
-
- try
- {
- if (epMetaData.getServiceEndpointInterfaceName() == null)
- epMetaData.setServiceEndpointInterfaceName(seiName);
-
- return createProxy(seiClass, epMetaData);
- }
- catch (ServiceException ex)
- {
- throw ex;
- }
- catch (Exception ex)
- {
- throw new ServiceException("Cannot create proxy", ex);
- }
- }
-
- private Remote createProxy(Class seiClass, EndpointMetaData epMetaData) throws
Exception
- {
- CallImpl call = new CallImpl(this, epMetaData);
-
- PortProxy handler = new PortProxy(call);
- ClassLoader cl = epMetaData.getClassLoader();
- Remote proxy = (Remote)Proxy.newProxyInstance(cl, new Class[] { seiClass,
Stub.class, StubExt.class }, handler);
-
- return proxy;
- }
-
- /**
- * Get the handler chain for the given endpoint name, maybe null.
- */
- public HandlerChain getHandlerChain(QName portName)
- {
- return handlerRegistry.getHandlerChainInstance(portName);
- }
-
- /**
- * Register a handler chain for the given endpoint name
- */
- public void registerHandlerChain(QName portName, List infos, Set roles)
- {
- handlerRegistry.registerClientHandlerChain(portName, infos, roles);
- }
-
- void setupHandlerChain(EndpointMetaData epMetaData)
- {
- QName portName = epMetaData.getPortName();
- Set<String> handlerRoles = new HashSet<String>();
- ArrayList handlerInfos = new ArrayList();
- for (HandlerMetaData handlerMetaData :
epMetaData.getHandlerMetaData(HandlerType.ALL))
- {
- HandlerMetaDataJAXRPC jaxrpcMetaData = (HandlerMetaDataJAXRPC)handlerMetaData;
- handlerRoles.addAll(jaxrpcMetaData.getSoapRoles());
-
- HashMap hConfig = new HashMap();
- for (HandlerInitParam param : jaxrpcMetaData.getInitParams())
- {
- hConfig.put(param.getParamName(), param.getParamValue());
- }
-
- Set<QName> headers = jaxrpcMetaData.getSoapHeaders();
- QName[] headerArr = new QName[headers.size()];
- headers.toArray(headerArr);
-
- Class hClass = jaxrpcMetaData.getHandlerClass();
- hConfig.put(HandlerType.class.getName(), jaxrpcMetaData.getHandlerType());
- HandlerInfo info = new HandlerInfo(hClass, hConfig, headerArr);
-
- log.debug("Adding client side handler to endpoint '" + portName +
"': " + info);
- handlerInfos.add(info);
-
- // register the handlers with the client engine
- if (handlerInfos.size() > 0)
- registerHandlerChain(portName, handlerInfos, handlerRoles);
- }
- }
-}
Deleted:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceObjectFactory.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceObjectFactory.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceObjectFactory.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -1,242 +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.
- */
-// $Id$
-package org.jboss.ws.core.jaxrpc;
-
-// $Id$
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.Constants;
-import org.jboss.ws.WSException;
-import org.jboss.ws.core.server.ServiceEndpoint;
-import org.jboss.ws.core.server.ServiceEndpointManager;
-import org.jboss.ws.core.server.ServiceEndpointManagerFactory;
-import org.jboss.ws.metadata.j2ee.UnifiedPortComponentRefMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedServiceRefMetaData;
-import org.jboss.ws.metadata.jaxrpcmapping.JavaWsdlMapping;
-import org.jboss.ws.metadata.umdm.EndpointMetaData;
-import org.jboss.ws.metadata.umdm.ServiceMetaData;
-import org.jboss.ws.metadata.wsse.WSSecurityConfiguration;
-
-import javax.naming.*;
-import javax.naming.spi.ObjectFactory;
-import javax.xml.namespace.QName;
-import javax.xml.rpc.JAXRPCException;
-import javax.xml.rpc.Service;
-import java.io.*;
-import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.Proxy;
-import java.net.URL;
-import java.net.URLEncoder;
-import java.rmi.Remote;
-import java.util.Hashtable;
-import java.util.List;
-
-/**
- * This ServiceObjectFactory reconstructs a javax.xml.rpc.Service
- * for a given WSDL when the webservice client does a JNDI lookup
- * <p/>
- * It uses the information provided by the service-ref element in application-client.xml
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 15-April-2004
- */
-public class ServiceObjectFactory implements ObjectFactory
-{
- // provide logging
- private static final Logger log = Logger.getLogger(ServiceObjectFactory.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;
-
- // Unmarshall the ServiceRefMetaData
- UnifiedServiceRefMetaData serviceRefMetaData = null;
- RefAddr metaRefAddr = ref.get(ServiceReferenceable.SERVICE_REF_META_DATA);
- ByteArrayInputStream bais = new
ByteArrayInputStream((byte[])metaRefAddr.getContent());
- try
- {
- ObjectInputStream ois = new ObjectInputStream(bais);
- serviceRefMetaData = (UnifiedServiceRefMetaData)ois.readObject();
- ois.close();
- }
- catch (IOException ex)
- {
- NamingException ne = new NamingException("Cannot unmarshall service ref
meta data");
- ne.setRootCause(ex);
- throw ne;
- }
-
- // Unmarshall the WSSecurityConfiguration
- WSSecurityConfiguration securityConfig = null;
- RefAddr wsseRefAddr = ref.get(ServiceReferenceable.SECURITY_CONFIG);
- if (wsseRefAddr != null)
- {
- bais = new ByteArrayInputStream((byte[])wsseRefAddr.getContent());
- try
- {
- ObjectInputStream ois = new ObjectInputStream(bais);
- securityConfig = (WSSecurityConfiguration)ois.readObject();
- ois.close();
- }
- catch (IOException e)
- {
- throw new NamingException("Cannot unmarshall security config, cause:
" + e.toString());
- }
- }
-
- ServiceImpl jaxrpcService = null;
- URL wsdlLocation = serviceRefMetaData.getWsdlLocation();
- if (wsdlLocation != null)
- {
- log.debug("Create jaxrpc service from wsdl");
-
- // Create the actual service object
- QName serviceName = serviceRefMetaData.getServiceQName();
- JavaWsdlMapping javaWsdlMapping =
(JavaWsdlMapping)serviceRefMetaData.getJavaWsdlMapping();
- jaxrpcService = new ServiceImpl(serviceName, wsdlLocation, javaWsdlMapping,
securityConfig, serviceRefMetaData);
- }
- else
- {
- log.debug("Create jaxrpc service with no wsdl");
- jaxrpcService = new ServiceImpl(new QName(Constants.NS_JBOSSWS_URI,
"AnonymousService"));
- }
-
- // Set any service level properties
- ServiceMetaData serviceMetaData = jaxrpcService.getServiceMetaData();
- serviceMetaData.setProperties(serviceRefMetaData.getCallProperties());
-
- // The web service client using a port-component-link, the contet is the URL to
- // the PortComponentLinkServlet that will return the actual endpoint address
- RefAddr pcLinkRef = ref.get(ServiceReferenceable.PORT_COMPONENT_LINK);
- if (pcLinkRef != null)
- {
- String pcLink = (String)pcLinkRef.getContent();
- log.debug("Resolving port-component-link: " + pcLink);
-
- // First try to obtain the endpoint address loacally
- String endpointAddress = null;
- try
- {
- ServiceEndpointManagerFactory factory =
ServiceEndpointManagerFactory.getInstance();
- ServiceEndpointManager epManager = factory.getServiceEndpointManager();
- ServiceEndpoint serviceEndpoint =
epManager.resolvePortComponentLink(pcLink);
- if (serviceEndpoint == null)
- throw new WSException("Cannot resolve port-component-link: "
+ pcLink);
-
- endpointAddress =
serviceEndpoint.getServiceEndpointInfo().getServerEndpointMetaData().getEndpointAddress();
- }
- catch (Exception ex)
- {
- // ignore, we are probably a remote client
- }
-
- // We may be remote in the esoteric case where an appclient uses the
port-comonent-link feature
- if (endpointAddress == null)
- {
- String servletPath =
(String)ref.get(ServiceReferenceable.PORT_COMPONENT_LINK_SERVLET).getContent();
- servletPath += "?pcLink=" + URLEncoder.encode(pcLink,
"UTF-8");
- InputStream is = new URL(servletPath).openStream();
- BufferedReader br = new BufferedReader(new InputStreamReader(is));
- endpointAddress = br.readLine();
- is.close();
- }
-
- log.debug("Resolved to: " + endpointAddress);
- if (serviceMetaData.getEndpoints().size() == 1)
- {
- EndpointMetaData epMetaData = serviceMetaData.getEndpoints().get(0);
- epMetaData.setEndpointAddress(endpointAddress);
- }
- else
- {
- log.warn("Cannot set endpoint address for port-component-link,
unsuported number of endpoints");
- }
- }
-
- /********************************************************
- * Setup the Proxy that implements the service-interface
- ********************************************************/
-
- // load the service interface class
- ClassLoader contextCL = Thread.currentThread().getContextClassLoader();
- Class siClass = contextCL.loadClass(serviceRefMetaData.getServiceInterface());
- if (Service.class.isAssignableFrom(siClass) == false)
- throw new JAXRPCException("The service interface does not implement
javax.xml.rpc.Service: " + siClass.getName());
-
- // load all service endpoint interface classes
- UnifiedPortComponentRefMetaData[] pcrArray =
serviceRefMetaData.getPortComponentRefs();
- for (int i = 0; i < pcrArray.length; i++)
- {
- UnifiedPortComponentRefMetaData pcr = pcrArray[i];
- Class seiClass = contextCL.loadClass(pcr.getServiceEndpointInterface());
- if (Remote.class.isAssignableFrom(seiClass) == false)
- throw new IllegalArgumentException("The SEI does not implement
java.rmi.Remote: " + seiClass.getName());
- }
-
- // Setup the handler chain
- setupHandlerChain(jaxrpcService);
-
- InvocationHandler handler = new ServiceProxy(jaxrpcService, siClass);
- return Proxy.newProxyInstance(contextCL, new Class[] { siClass, ServiceExt.class
}, handler);
- }
- catch (Exception ex)
- {
- log.error("Cannot create service", ex);
- throw ex;
- }
- }
-
- /**
- * Setup the handler chain(s) for this service
- */
- private void setupHandlerChain(ServiceImpl jaxrpcService) throws Exception
- {
- List<EndpointMetaData> endpoints =
jaxrpcService.getServiceMetaData().getEndpoints();
- for (EndpointMetaData epMetaData : endpoints)
- {
- jaxrpcService.setupHandlerChain(epMetaData);
- }
- }
-}
Deleted:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceProxy.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceProxy.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceProxy.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -1,162 +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.
-*/
-// $Id$
-package org.jboss.ws.core.jaxrpc;
-
-// $Id$
-
-import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.rmi.Remote;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import javax.xml.rpc.JAXRPCException;
-import javax.xml.rpc.Service;
-
-import org.jboss.logging.Logger;
-
-/**
- * This is the proxy that implements the service interface .
- * <p/>
- * Additionally it handles some ws4ee functionality that is not part of jaxrpc
behaviour.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 15-May-2004
- */
-public class ServiceProxy implements InvocationHandler
-{
- // provide logging
- private static final Logger log = Logger.getLogger(ServiceProxy.class);
-
- // The underlying jaxrpc service
- private ServiceImpl jaxrpcService;
-
- // The methods from java.lang.Object
- private List objectMethods = new ArrayList();
- // The methods from javax.xml.rpc.Service
- private List jaxrpcServiceMethods = new ArrayList();
- // The methods from the service interface, in case of javax.xml.rpc.Service it is
empty
- private List serviceInterfaceMethods = new ArrayList();
-
- // The cached getPort method
- private Method getPortMethod;
-
- /**
- * Construct a client side service proxy.
- * <p/>
- * This proxy implements the (generated) service interface.
- *
- * @param service The underlying {@link javax.xml.rpc.Service}
- * @param siClass The service interface, a subclass of {@link javax.xml.rpc.Service}
- */
- public ServiceProxy(ServiceImpl service, Class siClass)
- {
- this.jaxrpcService = service;
-
- // initialize java.lang.Object methods
- objectMethods.addAll(Arrays.asList(Object.class.getMethods()));
-
- // initialize javax.xml.rpc.Service methods
- jaxrpcServiceMethods.addAll(Arrays.asList(ServiceExt.class.getMethods()));
-
- // initialize SI methods
- if (siClass.getName().equals("javax.xml.rpc.Service") == false)
- serviceInterfaceMethods.addAll(Arrays.asList(siClass.getDeclaredMethods()));
-
- // initialize special ws4ee methods
- try
- {
- getPortMethod = Service.class.getMethod("getPort", new
Class[]{Class.class});
- }
- catch (NoSuchMethodException e)
- {
- throw new JAXRPCException(e.toString());
- }
- }
-
- /**
- * Processes a method invocation on a proxy instance and returns
- * the result.
- */
- public Object invoke(Object proxy, Method method, Object[] args) throws Throwable
- {
- String methodName = method.getName();
-
- try
- {
- Object retObj = null;
- if (jaxrpcServiceMethods.contains(method))
- {
- log.debug("Invoke on jaxrpc service: " + methodName);
-
- if (method.getName().equals("getPort"))
- {
- Remote port = (Remote)method.invoke(jaxrpcService, args);
- return port;
- }
- else
- {
- retObj = method.invoke(jaxrpcService, args);
- return retObj;
- }
- }
- if (serviceInterfaceMethods.contains(method))
- {
- log.debug("Invoke on service interface: " + methodName);
-
- Class seiClass = method.getReturnType();
- retObj = getPortMethod.invoke(jaxrpcService, new Object[]{seiClass});
- return retObj;
- }
- if (objectMethods.contains(method))
- {
- log.debug("Invoke on object: " + methodName);
-
- retObj = method.invoke(jaxrpcService, args);
- return retObj;
- }
-
- throw new JAXRPCException("Don't know how to invoke: " + method);
- }
- catch (Exception e)
- {
- handleException(e);
- return null;
- }
- }
-
- /**
- * Log the client side exception
- */
- private void handleException(Exception ex) throws Throwable
- {
- Throwable th = ex;
- if (ex instanceof InvocationTargetException)
- th = ((InvocationTargetException)ex).getTargetException();
-
- log.error("Service error", th);
- throw th;
- }
-}
\ No newline at end of file
Deleted:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceReferenceable.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceReferenceable.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceReferenceable.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -1,193 +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.
- */
-// $Id$
-package org.jboss.ws.core.jaxrpc;
-
-// $Id$
-
-import java.io.ByteArrayOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.ObjectOutputStream;
-import java.net.URL;
-
-import javax.naming.BinaryRefAddr;
-import javax.naming.NamingException;
-import javax.naming.Reference;
-import javax.naming.Referenceable;
-import javax.naming.StringRefAddr;
-
-import org.jboss.logging.Logger;
-import org.jboss.ws.core.server.ServiceEndpointManager;
-import org.jboss.ws.core.server.ServiceEndpointManagerFactory;
-import org.jboss.ws.core.server.UnifiedDeploymentInfo;
-import org.jboss.ws.metadata.j2ee.UnifiedPortComponentRefMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedServiceRefMetaData;
-import org.jboss.ws.metadata.j2ee.UnifiedWebMetaData;
-import org.jboss.ws.metadata.wsse.WSSecurityConfiguration;
-import org.jboss.ws.metadata.wsse.WSSecurityOMFactory;
-
-/**
- * A JNDI reference to a javax.xml.rpc.Service
- * <p/>
- * It holds the information to reconstrut the javax.xml.rpc.Service
- * when the client does a JNDI lookup.
- *
- * @author Thomas.Diesler(a)jboss.org
- * @since 15-April-2004
- */
-public class ServiceReferenceable implements Referenceable
-{
- // provide logging
- private static Logger log = Logger.getLogger(ServiceReferenceable.class);
-
- public static final String SERVICE_REF_META_DATA = "SERVICE_REF_META_DATA";
- public static final String DEPLOYMENT_URL = "DEPLOYMENT_URL";
- public static final String SECURITY_CONFIG = "SECURITY_CONFIG";
- public static final String DESCRIPTOR_LOC = "DESCRIPTOR_LOC";
- public static final String PORT_COMPONENT_LINK = "PORT_COMPONENT_LINK";
- public static final String PORT_COMPONENT_LINK_SERVLET =
"PORT_COMPONENT_LINK_SERVLET";
-
- private UnifiedServiceRefMetaData refMetaData;
- private UnifiedDeploymentInfo udi;
-
- /**
- * A service referenceable for a WSDL document that is part of the deployment
- *
- * @param refMetaData The service-ref meta data
- * @param udi The client DeploymentInfo
- */
- public ServiceReferenceable(UnifiedServiceRefMetaData refMetaData,
UnifiedDeploymentInfo udi)
- {
- this.refMetaData = refMetaData;
- this.udi = udi;
- }
-
- /**
- * 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(ServiceReferenceable.class.getName(),
ServiceObjectFactory.class.getName(), null);
-
- // The deployment URL of the web service client deployment
- // Add a reference to the client deployment URL
- String deploymentID = udi.name;
- myRef.add(new StringRefAddr(DEPLOYMENT_URL, deploymentID));
-
- // Add a reference to the ServiceRefMetaData and WSDLDefinitions
- myRef.add(new BinaryRefAddr(SERVICE_REF_META_DATA, marshallServiceRef()));
-
- // FIXME: JBWS-1431 Merge ws-security config with jaxrpc/jaxws config
- if (getSecurityConfig() != null)
- myRef.add(new BinaryRefAddr(SECURITY_CONFIG, marshallSecurityConfig()));
-
- // Add references to port component links
- UnifiedPortComponentRefMetaData[] pcrArr = refMetaData.getPortComponentRefs();
- for (int i = 0; i < pcrArr.length; i++)
- {
- UnifiedPortComponentRefMetaData pcr = pcrArr[i];
- String pcLink = pcr.getPortComponentLink();
- if (pcLink != null)
- {
- myRef.add(new StringRefAddr(PORT_COMPONENT_LINK, pcLink));
- try
- {
- ServiceEndpointManagerFactory factory =
ServiceEndpointManagerFactory.getInstance();
- ServiceEndpointManager epManager = factory.getServiceEndpointManager();
- String host = epManager.getWebServiceHost();
- int port = epManager.getWebServicePort();
-
- String servletURL = "http://" + host + ":" + port +
"/jbossws/pclink";
- myRef.add(new StringRefAddr(PORT_COMPONENT_LINK_SERVLET, servletURL));
- }
- catch (Exception ex)
- {
- throw new NamingException("Cannot obtain path to
PortComponentLinkServlet: " + ex);
- }
- }
- }
-
- return myRef;
- }
-
- /** Marshall the ServiceRefMetaData to an byte array
- */
- private byte[] marshallServiceRef() throws NamingException
- {
- refMetaData.getJavaWsdlMapping();
-
- ByteArrayOutputStream baos = new ByteArrayOutputStream(512);
- try
- {
- ObjectOutputStream oos = new ObjectOutputStream(baos);
- oos.writeObject(refMetaData);
- oos.close();
- }
- catch (IOException e)
- {
- throw new NamingException("Cannot marshall service ref meta data, cause:
" + e.toString());
- }
- return baos.toByteArray();
- }
-
- /** Marshall the WSSecurityConfiguration to an byte array
- */
- private byte[] marshallSecurityConfig() throws NamingException
- {
- ByteArrayOutputStream baos = new ByteArrayOutputStream(512);
- try
- {
- ObjectOutputStream oos = new ObjectOutputStream(baos);
- URL vfConfig = getSecurityConfig();
- WSSecurityConfiguration securityConfig =
WSSecurityOMFactory.newInstance().parse(vfConfig);
- oos.writeObject(securityConfig);
- oos.close();
- }
- catch (IOException e)
- {
- throw new NamingException("Cannot marshall security config, cause: " +
e.toString());
- }
- return baos.toByteArray();
- }
-
- private URL getSecurityConfig()
- {
- String descriptorPath = udi.metaData instanceof UnifiedWebMetaData ?
"WEB-INF" : "META-INF";
- descriptorPath = descriptorPath + "/" +
WSSecurityOMFactory.CLIENT_RESOURCE_NAME;
- try
- {
- URL vfConfig = udi.getMetaDataFileURL(descriptorPath);
- InputStream inputStream = vfConfig.openStream();
- inputStream.close();
- return vfConfig;
- }
- catch (IOException ex)
- {
- log.debug("Cannot find security config: " + descriptorPath);
- return null;
- }
- }
-}
\ No newline at end of file
Copied:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/CallImpl.java
(from rev 2172,
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/CallImpl.java)
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/CallImpl.java
(rev 0)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/CallImpl.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -0,0 +1,629 @@
+/*
+ * 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 java.rmi.RemoteException;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import javax.xml.namespace.QName;
+import javax.xml.rpc.Call;
+import javax.xml.rpc.JAXRPCException;
+import javax.xml.rpc.ParameterMode;
+import javax.xml.rpc.ServiceException;
+import javax.xml.rpc.Stub;
+import javax.xml.rpc.encoding.SerializerFactory;
+import javax.xml.rpc.soap.SOAPFaultException;
+import javax.xml.soap.SOAPException;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.Constants;
+import org.jboss.ws.core.CommonClient;
+import org.jboss.ws.core.CommonMessageContext;
+import org.jboss.ws.core.WSTimeoutException;
+import org.jboss.ws.core.jaxrpc.SchemaGenerator;
+import org.jboss.ws.core.jaxrpc.TypeMappingImpl;
+import org.jboss.ws.core.jaxrpc.UnqualifiedCallParameter;
+import org.jboss.ws.core.jaxrpc.binding.JBossXBDeserializerFactory;
+import org.jboss.ws.core.jaxrpc.binding.JBossXBSerializerFactory;
+import org.jboss.ws.core.jaxrpc.handler.HandlerChainBaseImpl;
+import org.jboss.ws.core.jaxrpc.handler.SOAPMessageContextJAXRPC;
+import org.jboss.ws.core.soap.MessageContextAssociation;
+import org.jboss.ws.core.utils.JavaUtils;
+import org.jboss.ws.extensions.xop.XOPContext;
+import org.jboss.ws.metadata.umdm.EndpointMetaData;
+import org.jboss.ws.metadata.umdm.OperationMetaData;
+import org.jboss.ws.metadata.umdm.ParameterMetaData;
+import org.jboss.ws.metadata.umdm.ServiceMetaData;
+import org.jboss.ws.metadata.umdm.TypesMetaData;
+import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
+import org.jboss.ws.metadata.wsdl.xmlschema.JBossXSModel;
+
+/** Provides support for the dynamic invocation of a service endpoint.
+ * The javax.xml.rpc.Service interface acts as a factory for the creation of Call
instances.
+ *
+ * Once a Call instance is created, various setter and getter methods may be used to
configure this Call instance.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 10-Oct-2004
+ */
+public class CallImpl extends CommonClient implements Call
+{
+ // provide logging
+ private static Logger log = Logger.getLogger(CallImpl.class);
+
+ // The service that created this call
+ private ServiceImpl jaxrpcService;
+ // The port type name
+ private QName portType;
+ // A Map<String,Object> of Call properties
+ private Map<String, Object> properties = new HashMap<String, Object>();
+
+ // The set of supported properties
+ private static final Set<String> standardProperties = new
HashSet<String>();
+ static
+ {
+ standardProperties.add(Call.ENCODINGSTYLE_URI_PROPERTY);
+ standardProperties.add(Call.OPERATION_STYLE_PROPERTY);
+ standardProperties.add(Call.SESSION_MAINTAIN_PROPERTY);
+ standardProperties.add(Call.SOAPACTION_URI_PROPERTY);
+ standardProperties.add(Call.SOAPACTION_USE_PROPERTY);
+ standardProperties.add(Call.USERNAME_PROPERTY);
+ standardProperties.add(Call.PASSWORD_PROPERTY);
+
+ standardProperties.add(Stub.ENDPOINT_ADDRESS_PROPERTY);
+ standardProperties.add(Stub.SESSION_MAINTAIN_PROPERTY);
+ standardProperties.add(Stub.USERNAME_PROPERTY);
+ standardProperties.add(Stub.PASSWORD_PROPERTY);
+ }
+
+ /** Create a call that needs to be configured manually
+ */
+ CallImpl(ServiceImpl service)
+ {
+ super(service.getServiceMetaData());
+ this.jaxrpcService = service;
+
+ if (epMetaData != null)
+ setTargetEndpointAddress(epMetaData.getEndpointAddress());
+ }
+
+ /** Create a call for a known WSDL endpoint.
+ *
+ * @param epMetaData A WSDLEndpoint
+ */
+ CallImpl(ServiceImpl service, EndpointMetaData epMetaData)
+ {
+ super(epMetaData);
+ this.jaxrpcService = service;
+
+ setTargetEndpointAddress(epMetaData.getEndpointAddress());
+ }
+
+ /** Create a call for a known WSDL endpoint.
+ *
+ * @param portName Qualified name for the target service endpoint
+ * @throws ServiceException
+ */
+ CallImpl(ServiceImpl service, QName portName, QName opName) throws ServiceException
+ {
+ super(service.getServiceMetaData(), portName, opName);
+ this.jaxrpcService = service;
+
+ if (epMetaData != null)
+ setTargetEndpointAddress(epMetaData.getEndpointAddress());
+ }
+
+ public ServiceImpl getServiceImpl()
+ {
+ return jaxrpcService;
+ }
+
+ @Override
+ protected Map<String, Object> getRequestContext()
+ {
+ return properties;
+ }
+
+ /** Gets the address of a target service endpoint.
+ */
+ public String getTargetEndpointAddress()
+ {
+ return (String)properties.get(Stub.ENDPOINT_ADDRESS_PROPERTY);
+ }
+
+ /** Sets the address of the target service endpoint. This address must correspond to
the transport
+ * specified in the binding for this Call instance.
+ *
+ * @param address Address of the target service endpoint; specified as an URI
+ */
+ public void setTargetEndpointAddress(String address)
+ {
+ this.properties.put(Stub.ENDPOINT_ADDRESS_PROPERTY, address);
+ }
+
+ /** Adds a parameter type and mode for a specific operation.
+ */
+ public void addParameter(String paramName, QName xmlType, ParameterMode
parameterMode)
+ {
+ TypeMappingImpl typeMapping =
getEndpointMetaData().getServiceMetaData().getTypeMapping();
+ Class javaType = typeMapping.getJavaType(xmlType);
+
+ // CTS
com/sun/ts/tests/jaxrpc/api/javax_xml_rpc/Call/AddGetRemoveAllParametersTest1
+ // tests addParameter/getParameter without giving the javaType for a custom
parameter
+ // IMHO, this flavour of addParameter should only be used for standard types,
where
+ // the javaType can be derived from the xmlType
+ if (javaType == null)
+ {
+ log.warn("Register unqualified call parameter for: " + xmlType);
+ javaType = new UnqualifiedCallParameter(xmlType).getClass();
+ typeMapping.register(javaType, xmlType, null, null);
+ }
+
+ addParameter(paramName, xmlType, javaType, parameterMode);
+ }
+
+ /** Adds a parameter type and mode for a specific operation.
+ */
+ public void addParameter(String paramName, QName xmlType, Class javaType,
ParameterMode mode)
+ {
+ QName xmlName = new QName(paramName);
+ addParameter(xmlName, xmlType, javaType, mode, false);
+ }
+
+ /** Add a parameter to the current operation description.
+ * This is a propriatary extension that gives full control over the parameter
configuration.
+ */
+ public void addParameter(QName xmlName, QName xmlType, Class javaType, ParameterMode
mode, boolean inHeader)
+ {
+ if (xmlType == null || javaType == null)
+ throw new IllegalArgumentException("Invalid null parameter");
+
+ OperationMetaData opMetaData = getOperationMetaData();
+ ParameterMetaData paramMetaData = new ParameterMetaData(opMetaData, xmlName,
xmlType, javaType.getName());
+ paramMetaData.setMode(mode);
+ paramMetaData.setInHeader(inHeader);
+ paramMetaData.setIndex(opMetaData.getParameters().size());
+ opMetaData.addParameter(paramMetaData);
+
+ registerParameterType(xmlType, javaType);
+ }
+
+ /** Removes all specified parameters from this Call instance. Note that this method
removes only the parameters and
+ * not the return type. The setReturnType(null) is used to remove the return type.
+ *
+ * @throws javax.xml.rpc.JAXRPCException This exception may be thrown If this method
is called when the method isParameterAndReturnSpecRequired returns false for this
Call's operation.
+ */
+ public void removeAllParameters()
+ {
+ OperationMetaData opMetaData = getOperationMetaData();
+ opMetaData.removeAllParameters();
+ }
+
+ /** Sets the return type for a specific operation. Invoking setReturnType(null)
removes the return type for this Call object.
+ */
+ public void setReturnType(QName xmlType)
+ {
+ Class javaType =
getEndpointMetaData().getServiceMetaData().getTypeMapping().getJavaType(xmlType);
+ setReturnType(xmlType, javaType);
+ }
+
+ /** Sets the return type for a specific operation.
+ */
+ public void setReturnType(QName xmlType, Class javaType)
+ {
+ if (xmlType == null || javaType == null)
+ throw new IllegalArgumentException("Invalid null parameter");
+
+ OperationMetaData opMetaData = getOperationMetaData();
+ QName xmlName = new QName(Constants.DEFAULT_RPC_RETURN_NAME);
+ String javaTypeName = javaType.getName();
+ ParameterMetaData retMetaData = new ParameterMetaData(opMetaData, xmlName, xmlType,
javaTypeName);
+ opMetaData.setReturnParameter(retMetaData);
+
+ registerParameterType(xmlType, javaType);
+ }
+
+ /** Invokes a remote method using the one-way interaction mode.
+ */
+ public void invokeOneWay(Object[] inputParams)
+ {
+ try
+ {
+ invokeInternal(operationName, inputParams, true);
+ }
+ catch (RemoteException ex)
+ {
+ throw new JAXRPCException(ex);
+ }
+ }
+
+ /** Invokes a specific operation using a synchronous request-response interaction
mode.
+ */
+ public Object invoke(Object[] inputParams) throws RemoteException
+ {
+ return invokeInternal(operationName, inputParams, false);
+ }
+
+ /** Invokes a specific operation using a synchronous request-response interaction
mode.
+ */
+ public Object invoke(QName operationName, Object[] inputParams) throws
RemoteException
+ {
+ return invokeInternal(operationName, inputParams, false);
+ }
+
+ protected CommonMessageContext processPivot(CommonMessageContext requestContext) {
+ log.debug("Begin response processing");
+ return requestContext;
+ }
+
+ /** Returns a List values for the output parameters of the last invoked operation.
+ *
+ * @return java.util.List Values for the output parameters. An empty List is returned
if there are no output values.
+ * @throws JAXRPCException If this method is invoked for a one-way operation or is
invoked before any invoke method has been called.
+ */
+ public List getOutputValues()
+ {
+ if (epInv == null)
+ throw new JAXRPCException("Output params not available");
+
+ try
+ {
+ OperationMetaData opMetaData = getOperationMetaData();
+
+ List<Object> objPayload = new ArrayList<Object>();
+ for (QName xmlName : epInv.getResponseParamNames())
+ {
+ Object paramValue = epInv.getResponseParamValue(xmlName);
+ if (opMetaData.isDocumentWrapped())
+ {
+ objPayload = Arrays.asList((Object[])paramValue);
+ break;
+ }
+ else
+ {
+ objPayload.add(paramValue);
+ }
+ }
+ return objPayload;
+ }
+ catch (SOAPException ex)
+ {
+ throw new JAXRPCException("Cannot obtain response payload", ex);
+ }
+ }
+
+ /** Returns a Map of {name, value} for the output parameters of the last invoked
operation.
+ * The parameter names in the returned Map are of type java.lang.String.
+ *
+ * @return Map Output parameters for the last Call.invoke(). Empty Map is returned if
there are no output parameters.
+ * @throws JAXRPCException If this method is invoked for a one-way operation or is
invoked before any invoke method has been called.
+ */
+ public Map getOutputParams()
+ {
+ if (epInv == null)
+ throw new JAXRPCException("Output params not available");
+
+ try
+ {
+ Map<String, Object> outMap = new LinkedHashMap<String, Object>();
+ for (QName xmlName : epInv.getResponseParamNames())
+ {
+ Object value = epInv.getResponseParamValue(xmlName);
+ outMap.put(xmlName.getLocalPart(), value);
+ }
+ return outMap;
+ }
+ catch (SOAPException ex)
+ {
+ throw new JAXRPCException("Cannot obtain response payload", ex);
+ }
+ }
+
+ /**
+ * Gets the qualified name of the port type.
+ *
+ * @return Qualified name of the port type
+ */
+ public QName getPortTypeName()
+ {
+ if (portType != null)
+ {
+ return portType;
+ }
+
+ /* This code could be used to derive the portType from the endpoint meta data.
+ * However, it breaks CTS
com/sun/ts/tests/jaxrpc/api/javax_xml_rpc/Call/Client.java#SetGetPortTypeNameTest2
+ if (epMetaData != null)
+ {
+ ServiceMetaData serviceMetaData = epMetaData.getServiceMetaData();
+ WSDLDefinitions wsdlDefinitions = serviceMetaData.getWsdlDefinitions();
+ WSDLService wsdlService = wsdlDefinitions.getService(new
NCName(serviceMetaData.getName().getLocalPart()));
+ WSDLEndpoint wsdlEndpoint = wsdlService.getEndpoint(epMetaData.getName());
+ WSDLInterface wsdlInterface = wsdlEndpoint.getInterface();
+ return wsdlInterface.getQName();
+ }
+ */
+
+ // CTS
com/sun/ts/tests/jaxrpc/api/javax_xml_rpc/Call/Client.java#SetGetPortTypeNameTest2
+ return new QName("");
+ }
+
+ /**
+ * Gets the return type for a specific operation
+ *
+ * @return Returns the XML type for the return value
+ */
+ public QName getReturnType()
+ {
+ QName retType = null;
+ if (operationName != null)
+ {
+ OperationMetaData opDesc = getOperationMetaData();
+ ParameterMetaData retMetaData = opDesc.getReturnParameter();
+ if (retMetaData != null)
+ retType = retMetaData.getXmlType();
+ }
+ return retType;
+ }
+
+ /**
+ * Sets the qualified name of the interface.
+ *
+ * @param portType - Qualified name of the port type
+ */
+ public void setPortTypeName(QName portType)
+ {
+ this.portType = portType;
+ }
+
+ /**
+ * Indicates whether addParameter and setReturnType methods are to be invoked to
specify the parameter and return
+ * type specification for a specific operation.
+ *
+ * @param opName Qualified name of the operation
+ * @return Returns true if the Call implementation class requires addParameter and
setReturnType to be invoked in the client code for the specified operation. This method
returns false otherwise.
+ * @throws IllegalArgumentException If invalid operation name is specified
+ */
+ public boolean isParameterAndReturnSpecRequired(QName opName)
+ {
+ setOperationName(opName);
+ OperationMetaData opMetaData = getOperationMetaData();
+ return opMetaData.getParameters().size() == 0 &&
opMetaData.getReturnParameter() == null;
+ }
+
+ /** Gets the names of configurable properties supported by this Call object.
+ * @return Iterator for the property names
+ */
+ public Iterator getPropertyNames()
+ {
+ return standardProperties.iterator();
+ }
+
+ /** Gets the value of a named property.
+ */
+ public Object getProperty(String name)
+ {
+ if (null == name)
+ throw new JAXRPCException("Unsupported property: " + name);
+ // CTS:
com/sun/ts/tests/jaxrpc/api/javax_xml_rpc/Call/Client.java#SetGetPropertyTest2
+ if (name.startsWith("javax.xml.rpc") &&
standardProperties.contains(name) == false)
+ throw new JAXRPCException("Unsupported property: " + name);
+
+ return properties.get(name);
+ }
+
+ /** Sets the value for a named property.
+ */
+ public void setProperty(String name, Object value)
+ {
+ if (null == name)
+ throw new JAXRPCException("Unsupported property: " + name);
+ // CTS:
com/sun/ts/tests/jaxrpc/api/javax_xml_rpc/Call/Client.java#SetGetPropertyTest2
+ if (name.startsWith("javax.xml.rpc") &&
standardProperties.contains(name) == false)
+ throw new JAXRPCException("Unsupported property: " + name);
+
+ properties.put(name, value);
+ }
+
+ /** Removes a named property.
+ */
+ public void removeProperty(String name)
+ {
+ properties.remove(name);
+ }
+
+ /** Gets the XML type of a parameter by name.
+ */
+ public QName getParameterTypeByName(String paramName)
+ {
+ OperationMetaData opMetaData = getOperationMetaData();
+ ParameterMetaData paramMetaData = opMetaData.getParameter(new QName(paramName));
+ if (paramMetaData != null)
+ return paramMetaData.getXmlType();
+ else return null;
+ }
+
+ @Override
+ protected void setInboundContextProperties()
+ {
+ }
+
+ @Override
+ protected void setOutboundContextProperties()
+ {
+ }
+
+ private Object invokeInternal(QName opName, Object[] inputParams, boolean forceOneway)
throws RemoteException
+ {
+ if (opName.equals(operationName) == false)
+ setOperationName(opName);
+
+ OperationMetaData opMetaData = getOperationMetaData();
+
+ // Check or generate the the schema if this call is unconfigured
+ generateOrUpdateSchemas(opMetaData);
+
+ // Associate a message context with the current thread
+ SOAPMessageContextJAXRPC msgContext = new SOAPMessageContextJAXRPC();
+ MessageContextAssociation.pushMessageContext(msgContext);
+ Object retObj = null;
+ try
+ {
+ retObj = super.invoke(opName, inputParams, properties, forceOneway);
+ return retObj;
+ }
+ catch (SOAPFaultException ex)
+ {
+ log.error("Call invocation failed", ex);
+ String faultCode = ex.getFaultCode().getLocalPart();
+ throw new RemoteException("Call invocation failed with code [" +
faultCode + "] because of: " + ex.getFaultString(), ex);
+ }
+ catch (RemoteException rex)
+ {
+ throw rex;
+ }
+ catch (WSTimeoutException toex)
+ {
+ throw toex;
+ }
+ catch (Exception ex)
+ {
+ throw new RemoteException("Call invocation failed", ex);
+ }
+ finally
+ {
+ // Reset the message context association
+ MessageContextAssociation.popMessageContext();
+ }
+ }
+
+ @Override
+ protected boolean callRequestHandlerChain(QName portName, HandlerType type)
+ {
+ SOAPMessageContextJAXRPC msgContext =
(SOAPMessageContextJAXRPC)MessageContextAssociation.peekMessageContext();
+ HandlerChainBaseImpl handlerChain =
(HandlerChainBaseImpl)jaxrpcService.getHandlerChain(portName);
+ boolean status = (handlerChain != null ? handlerChain.handleRequest(msgContext,
type) : true);
+
+ if (type == HandlerType.ENDPOINT)
+ XOPContext.visitAndRestoreXOPData();
+
+ return status;
+ }
+
+ @Override
+ protected boolean callResponseHandlerChain(QName portName, HandlerType type)
+ {
+ SOAPMessageContextJAXRPC msgContext =
(SOAPMessageContextJAXRPC)MessageContextAssociation.peekMessageContext();
+ HandlerChainBaseImpl handlerChain =
(HandlerChainBaseImpl)jaxrpcService.getHandlerChain(portName);
+
+ boolean status = true;
+ if (handlerChain != null)
+ {
+ status = handlerChain.handleResponse(msgContext, type);
+ }
+ return status;
+ }
+
+ /** Generate or update the XSD schema for all parameters and the return.
+ * This should only be done when the Call is unconfigured, hence there is no WSDL
+ */
+ private void generateOrUpdateSchemas(OperationMetaData opMetaData)
+ {
+ ServiceMetaData serviceMetaData =
opMetaData.getEndpointMetaData().getServiceMetaData();
+ if (serviceMetaData.getWsdlLocation() == null)
+ {
+ TypesMetaData typesMetaData = serviceMetaData.getTypesMetaData();
+ for (ParameterMetaData paramMetaData : opMetaData.getParameters())
+ {
+ generateOrUpdateParameterSchema(typesMetaData, paramMetaData);
+ }
+
+ ParameterMetaData retMetaData = opMetaData.getReturnParameter();
+ if (retMetaData != null)
+ {
+ generateOrUpdateParameterSchema(typesMetaData, retMetaData);
+ }
+ }
+ }
+
+ /** Generate or update the XSD schema for a given parameter
+ * This should only be done if the parameter is not an attachment
+ */
+ private void generateOrUpdateParameterSchema(TypesMetaData typesMetaData,
ParameterMetaData paramMetaData)
+ {
+ if (paramMetaData.isSwA() == false)
+ {
+ QName xmlType = paramMetaData.getXmlType();
+ Class javaType = paramMetaData.getJavaType();
+
+ ServiceMetaData serviceMetaData = getEndpointMetaData().getServiceMetaData();
+ TypeMappingImpl typeMapping = serviceMetaData.getTypeMapping();
+ SerializerFactory serFactory = typeMapping.getSerializer(javaType, xmlType);
+ if (serFactory instanceof JBossXBSerializerFactory)
+ {
+ SchemaGenerator xsdGenerator = new SchemaGenerator();
+ JBossXSModel model = xsdGenerator.generateXSDSchema(xmlType, javaType);
+ typesMetaData.addSchemaModel(model);
+ }
+ }
+ }
+
+ private void registerParameterType(QName xmlType, Class javaType)
+ {
+ ServiceMetaData serviceMetaData = getEndpointMetaData().getServiceMetaData();
+
+ String nsURI = xmlType.getNamespaceURI();
+ if (Constants.NS_ATTACHMENT_MIME_TYPE.equals(nsURI) == false)
+ {
+ TypeMappingImpl typeMapping = serviceMetaData.getTypeMapping();
+ Class regJavaType = typeMapping.getJavaType(xmlType);
+ if (regJavaType == null)
+ {
+ typeMapping.register(javaType, xmlType, new JBossXBSerializerFactory(), new
JBossXBDeserializerFactory());
+ }
+ else if (regJavaType != null && JavaUtils.isAssignableFrom(regJavaType,
javaType) == false)
+ {
+ throw new IllegalArgumentException("Different java type already
registered: " + regJavaType.getName());
+ }
+ }
+ }
+
+ @Override
+ public void setConfigName(String configName, String configFile)
+ {
+ EndpointMetaData epMetaData = getEndpointMetaData();
+ epMetaData.setConfigName(configName, configFile);
+
+ // Reinitialize the client handler chain
+ jaxrpcService.setupHandlerChain(epMetaData);
+ }
+}
Copied:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/HandlerRegistryImpl.java
(from rev 2172,
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/HandlerRegistryImpl.java)
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/HandlerRegistryImpl.java
(rev 0)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/HandlerRegistryImpl.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -0,0 +1,119 @@
+/*
+* 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 java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import javax.xml.namespace.QName;
+import javax.xml.rpc.handler.HandlerChain;
+import javax.xml.rpc.handler.HandlerInfo;
+import javax.xml.rpc.handler.HandlerRegistry;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.core.jaxrpc.handler.ClientHandlerChain;
+import org.jboss.ws.metadata.umdm.EndpointMetaData;
+import org.jboss.ws.metadata.umdm.HandlerMetaDataJAXRPC;
+import org.jboss.ws.metadata.umdm.ServiceMetaData;
+import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
+
+/**
+ * Provides support for the programmatic configuration of
+ * handlers in a HandlerRegistry.
+ *
+ * A handler chain is registered per service endpoint, as indicated by the
+ * qualified name of a port. The getHandlerChain returns the handler chain
+ * (as a java.util.List) for the specified service endpoint. The returned
+ * handler chain is configured using the java.util.List interface. Each element
+ * in this list is required to be of the Java type
+ * javax.xml.rpc.handler.HandlerInfo.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 20-Jul-2005
+ */
+public class HandlerRegistryImpl implements HandlerRegistry
+{
+ // provide logging
+ private static Logger log = Logger.getLogger(HandlerRegistryImpl.class);
+
+ // Map<QName,HandlerChain> the endpoint name to a HandlerChain
+ private Map<QName, HandlerChain> handlerChains = new HashMap<QName,
HandlerChain>();
+ // Maps the port name to a list of HandlerInfo objects
+ private Map<QName, List<HandlerInfo>> handlerInfos = new HashMap<QName,
List<HandlerInfo>>();
+ // The service this registry is associated with
+ private ServiceMetaData serviceMetaData;
+
+ public HandlerRegistryImpl(ServiceMetaData serviceMetaData)
+ {
+ this.serviceMetaData = serviceMetaData;
+ }
+
+ public List getHandlerChain(QName portName)
+ {
+ List<HandlerInfo> list = handlerInfos.get(portName);
+ if (list == null)
+ list = new ArrayList<HandlerInfo>();
+
+ return new ArrayList(list);
+ }
+
+ public void setHandlerChain(QName portName, List chain)
+ {
+ registerClientHandlerChain(portName, chain, null);
+ }
+
+ /** Get the handler chain for the given endpoint name, maybe null.
+ */
+ HandlerChain getHandlerChainInstance(QName portName)
+ {
+ HandlerChain handlerChain = handlerChains.get(portName);
+ return handlerChain;
+ }
+
+ /** Register a handler chain for the given endpoint name
+ */
+ void registerClientHandlerChain(QName portName, List<HandlerInfo> infos,
Set<String> roles)
+ {
+ ClientHandlerChain chain = new ClientHandlerChain(infos, roles);
+ handlerChains.put(portName, chain);
+ handlerInfos.put(portName, infos);
+
+ EndpointMetaData epMetaData = serviceMetaData.getEndpoint(portName);
+ if (epMetaData == null)
+ throw new IllegalStateException("Cannot obtain endpoint meta data for:
" + portName);
+
+ epMetaData.clearHandlers();
+ for (HandlerInfo info : infos)
+ {
+ HandlerMetaDataJAXRPC handler = new HandlerMetaDataJAXRPC(epMetaData,
HandlerType.ENDPOINT);
+ handler.setHandlerClassName(info.getHandlerClass().getName());
+ handler.setSoapRoles(roles);
+ log.debug("Add handler to: " + portName + handler);
+ epMetaData.addHandler(handler);
+ }
+ }
+}
Copied:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/PortProxy.java
(from rev 2172,
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/PortProxy.java)
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/PortProxy.java
(rev 0)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/PortProxy.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -0,0 +1,210 @@
+/*
+* 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 java.lang.reflect.InvocationHandler;
+import java.lang.reflect.Method;
+import java.rmi.RemoteException;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import javax.xml.rpc.JAXRPCException;
+import javax.xml.rpc.Stub;
+import javax.xml.rpc.soap.SOAPFaultException;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.WSException;
+import org.jboss.ws.core.StubExt;
+import org.jboss.ws.core.utils.JavaUtils;
+import org.jboss.ws.metadata.umdm.EndpointMetaData;
+import org.jboss.ws.metadata.umdm.OperationMetaData;
+
+/**
+ * The dynamic proxy that delegates to the underlying Call implementation
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 07-Jan-2005
+ */
+public class PortProxy implements InvocationHandler
+{
+ // provide logging
+ private static final Logger log = Logger.getLogger(PortProxy.class);
+
+ // The underlying Call
+ private CallImpl call;
+ // List<Method> of the Stub methods
+ private List stubMethods;
+ // List<Method> of the Object methods
+ private List objectMethods;
+
+ // The set of standard properties
+ private static final Set<String> standardProperties = new
HashSet<String>();
+ static
+ {
+ standardProperties.add(Stub.ENDPOINT_ADDRESS_PROPERTY);
+ standardProperties.add(Stub.SESSION_MAINTAIN_PROPERTY);
+ standardProperties.add(Stub.USERNAME_PROPERTY);
+ standardProperties.add(Stub.PASSWORD_PROPERTY);
+ }
+
+ // The map of jboss-ws4ee supported properties
+ private static final Map<String,String> legacyPropertyMap = new
HashMap<String,String>();
+ static
+ {
+ legacyPropertyMap.put("org.jboss.webservice.client.timeout",
StubExt.PROPERTY_CLIENT_TIMEOUT);
+ legacyPropertyMap.put("org.jboss.webservice.keyStore",
StubExt.PROPERTY_KEY_STORE);
+ legacyPropertyMap.put("org.jboss.webservice.keyStorePassword",
StubExt.PROPERTY_KEY_STORE_PASSWORD);
+ legacyPropertyMap.put("org.jboss.webservice.keyStoreType",
StubExt.PROPERTY_KEY_STORE_TYPE);
+ legacyPropertyMap.put("org.jboss.webservice.trustStore",
StubExt.PROPERTY_TRUST_STORE);
+ legacyPropertyMap.put("org.jboss.webservice.trustStorePassword",
StubExt.PROPERTY_TRUST_STORE_PASSWORD);
+ legacyPropertyMap.put("org.jboss.webservice.trustStoreType",
StubExt.PROPERTY_TRUST_STORE_TYPE);
+ }
+
+ public PortProxy(CallImpl call)
+ {
+ this.call = call;
+ this.stubMethods = new ArrayList(Arrays.asList(StubExt.class.getMethods()));
+ this.stubMethods.addAll(Arrays.asList(Stub.class.getMethods()));
+ this.objectMethods = Arrays.asList(Object.class.getMethods());
+ }
+
+ /** Processes a method invocation on a proxy instance and returns the result.
+ */
+ public Object invoke(Object proxy, Method method, Object[] args) throws Throwable
+ {
+ // An invocation on the Stub interface
+ String methodName = method.getName();
+ if (stubMethods.contains(method))
+ {
+ if (methodName.equals("_getPropertyNames"))
+ {
+ return call.getPropertyNames();
+ }
+ else if (methodName.equals("_getProperty"))
+ {
+ return getProperty((String)args[0]);
+ }
+ else if (methodName.equals("_setProperty"))
+ {
+ setProperty((String)args[0], args[1]);
+ return null;
+ }
+ else
+ {
+ Method callMethod = CallImpl.class.getMethod(methodName,
method.getParameterTypes());
+ return callMethod.invoke(call, args);
+ }
+ }
+
+ // An invocation on proxy's Object class
+ else if (objectMethods.contains(method))
+ {
+ Method callMethod = CallImpl.class.getMethod(methodName,
method.getParameterTypes());
+ return callMethod.invoke(call, args);
+ }
+
+ // An invocation on the service endpoint interface
+ else
+ {
+ EndpointMetaData epMetaData = call.getEndpointMetaData();
+ OperationMetaData opMetaData = epMetaData.getOperation(method);
+ if (opMetaData == null)
+ throw new WSException("Cannot obtain operation meta data for: " +
methodName);
+
+ call.setOperationName(opMetaData.getQName());
+
+ try
+ {
+ if (opMetaData.isOneWay())
+ {
+ call.invokeOneWay(args);
+ return null;
+ }
+ else
+ {
+ Object retObj = call.invoke(args);
+ if (retObj != null)
+ {
+ Class retType = method.getReturnType();
+ if (retType == null)
+ throw new WSException("Return value not supported by: " +
opMetaData);
+
+ if (JavaUtils.isPrimitive(retType))
+ retObj = JavaUtils.getPrimitiveValueArray(retObj);
+ }
+ return retObj;
+ }
+ }
+ catch (Exception ex)
+ {
+ handleException(ex);
+ return null;
+ }
+ }
+ }
+
+ private Object getProperty(String name)
+ {
+ name = assertPropertyName(name);
+ return call.getProperty(name);
+ }
+
+ private void setProperty(String name, Object value)
+ {
+ name = assertPropertyName(name);
+ call.setProperty(name, value);
+ }
+
+ private String assertPropertyName(String name)
+ {
+ if (name != null && name.startsWith("javax.xml.rpc") &&
standardProperties.contains(name) == false)
+ throw new JAXRPCException("Unsupported property: " + name);
+
+ if (legacyPropertyMap.keySet().contains(name))
+ {
+ String jbosswsName = legacyPropertyMap.get(name);
+ log.warn("Legacy propery '" + name + "' mapped to
'" + jbosswsName + "'");
+ name = jbosswsName;
+ }
+
+ return name;
+ }
+
+ private void handleException(Exception ex) throws Throwable
+ {
+ Throwable th = ex;
+ if (ex instanceof RemoteException && ex.getCause() instanceof
SOAPFaultException)
+ {
+ SOAPFaultException faultEx = (SOAPFaultException)ex.getCause();
+ if (faultEx.getCause() != null)
+ th = faultEx.getCause();
+ }
+ throw th;
+ }
+}
Copied:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceExt.java
(from rev 2172,
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceExt.java)
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceExt.java
(rev 0)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceExt.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -0,0 +1,42 @@
+/*
+* 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.xml.rpc.Service;
+import javax.xml.rpc.handler.HandlerRegistry;
+
+/**
+ * Extends the JAXRPC Service with JBoss propriatary behaviour
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 27-Jan-2005
+ */
+public interface ServiceExt extends Service
+{
+ /**
+ * Get a HandlerRegistry that can be used to dynamically
+ * change the client side handler chain
+ */
+ HandlerRegistry getDynamicHandlerRegistry();
+}
Copied:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceFactoryImpl.java
(from rev 2172,
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceFactoryImpl.java)
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceFactoryImpl.java
(rev 0)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceFactoryImpl.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -0,0 +1,160 @@
+/*
+* 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 java.net.URL;
+import java.util.Properties;
+
+import javax.xml.namespace.QName;
+import javax.xml.rpc.Service;
+import javax.xml.rpc.ServiceException;
+import javax.xml.rpc.ServiceFactory;
+
+import org.jboss.logging.Logger;
+import org.jboss.util.NotImplementedException;
+
+/**
+ * Service class acts as a factory for:
+ * <ul>
+ * <li>Dynamic proxy for the target service endpoint.
+ * <li>Instance of the type javax.xml.rpc.Call for the dynamic invocation of a
remote operation on the target service endpoint.
+ * <li>Instance of a generated stub class
+ * </ul>
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 10-Oct-2004
+ */
+public class ServiceFactoryImpl extends ServiceFactory
+{
+ // provide logging
+ private final Logger log = Logger.getLogger(ServiceFactoryImpl.class);
+
+ /**
+ * Create an instance of the generated service implementation class for a given
service interface, if available.
+ *
+ * @param serviceInterface Service interface
+ * @return A Service
+ * @throws ServiceException If there is any error while creating the specified
service, including the case where a
+ * generated service implementation class cannot be located
+ */
+ public Service loadService(Class serviceInterface) throws ServiceException
+ {
+ throw new NotImplementedException();
+ }
+
+ /**
+ * Create an instance of the generated service implementation class for a given
service interface, if available.
+ * An implementation may use the provided wsdlDocumentLocation and properties to help
locate the generated implementation class.
+ * If no such class is present, a ServiceException will be thrown.
+ *
+ * @param wsdlDocumentLocation URL for the WSDL document location for the service or
null
+ * @param serviceInterface Service interface
+ * @param props A set of implementation-specific properties to help
locate the generated service implementation class
+ * @return A Service
+ * @throws ServiceException If there is any error while creating the specified
service, including the case where a
+ * generated service implementation class cannot be located
+ */
+ public Service loadService(URL wsdlDocumentLocation, Class serviceInterface,
Properties props) throws ServiceException
+ {
+ throw new NotImplementedException();
+ }
+
+ /**
+ * Create an instance of the generated service implementation class for a given
service, if available.
+ * The service is uniquely identified by the wsdlDocumentLocation and serviceName
arguments.
+ * An implementation may use the provided properties to help locate the generated
implementation class.
+ * If no such class is present, a ServiceException will be thrown.
+ *
+ * @param wsdlDocumentLocation URL for the WSDL document location for the service or
null
+ * @param serviceName Qualified name for the service
+ * @param props A set of implementation-specific properties to help
locate the generated service implementation class
+ * @return A Service
+ * @throws ServiceException If there is any error while creating the specified
service, including the case where a generated service implementation class cannot be
located
+ */
+ public Service loadService(URL wsdlDocumentLocation, QName serviceName, Properties
props) throws ServiceException
+ {
+ throw new NotImplementedException();
+ }
+
+ /**
+ * Create a <code>Service</code> instance.
+ *
+ * @param serviceName QName for the service
+ * @return Service.
+ * @throws ServiceException If any error in creation of the specified service
+ */
+ public Service createService(QName serviceName) throws ServiceException
+ {
+ return new ServiceImpl(serviceName);
+ }
+
+ /**
+ * Create a <code>Service</code> instance.
+ *
+ * @param wsdlURL URL for the WSDL document location
+ * @param serviceName QName for the service.
+ * @return Service.
+ * @throws ServiceException If any error in creation of the specified service
+ */
+ public Service createService(URL wsdlURL, QName serviceName) throws ServiceException
+ {
+ ClassLoader cl = Thread.currentThread().getContextClassLoader();
+
+ URL mappingURL = cl.getResource("META-INF/jaxrpc-mapping.xml");
+ if (mappingURL != null)
+ log.info("Use jaxrpc-mapping from: " + mappingURL);
+
+ return createService(wsdlURL, serviceName, mappingURL, null);
+ }
+
+ /**
+ * Create a <code>Service</code> instance.
+ *
+ * @param wsdlURL URL for the WSDL document location
+ * @param serviceName QName for the service.
+ * @param mappingURL URL for the jaxrpc-mapping.xml document location
+ * @return Service.
+ * @throws ServiceException If any error in creation of the specified service
+ */
+ public Service createService(URL wsdlURL, QName serviceName, URL mappingURL) throws
ServiceException
+ {
+ return createService(wsdlURL, serviceName, mappingURL, null);
+ }
+
+ /**
+ * Create a <code>Service</code> instance.
+ *
+ * @param wsdlURL URL for the WSDL document location
+ * @param serviceName QName for the service.
+ * @param mappingURL URL for the jaxrpc-mapping.xml document location
+ * @param securityURL URL for the jboss-ws-security.xml file
+ * @return Service.
+ * @throws ServiceException If any error in creation of the specified service
+ */
+ public Service createService(URL wsdlURL, QName serviceName, URL mappingURL, URL
securityURL) throws ServiceException
+ {
+ ServiceImpl service = new ServiceImpl(serviceName, wsdlURL, mappingURL,
securityURL);
+ return service;
+ }
+}
Copied:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceImpl.java
(from rev 2172,
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceImpl.java)
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceImpl.java
(rev 0)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceImpl.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -0,0 +1,451 @@
+/*
+ * 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 java.lang.reflect.Proxy;
+import java.net.URL;
+import java.rmi.Remote;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+
+import javax.xml.namespace.QName;
+import javax.xml.rpc.Call;
+import javax.xml.rpc.ServiceException;
+import javax.xml.rpc.Stub;
+import javax.xml.rpc.encoding.TypeMappingRegistry;
+import javax.xml.rpc.handler.HandlerChain;
+import javax.xml.rpc.handler.HandlerInfo;
+import javax.xml.rpc.handler.HandlerRegistry;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.core.StubExt;
+import org.jboss.ws.metadata.builder.jaxrpc.JAXRPCClientMetaDataBuilder;
+import org.jboss.ws.metadata.j2ee.UnifiedServiceRefMetaData;
+import org.jboss.ws.metadata.jaxrpcmapping.JavaWsdlMapping;
+import org.jboss.ws.metadata.umdm.EndpointMetaData;
+import org.jboss.ws.metadata.umdm.HandlerMetaData;
+import org.jboss.ws.metadata.umdm.HandlerMetaDataJAXRPC;
+import org.jboss.ws.metadata.umdm.OperationMetaData;
+import org.jboss.ws.metadata.umdm.ResourceLoaderAdapter;
+import org.jboss.ws.metadata.umdm.ServiceMetaData;
+import org.jboss.ws.metadata.umdm.UnifiedMetaData;
+import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerInitParam;
+import org.jboss.ws.metadata.umdm.HandlerMetaData.HandlerType;
+import org.jboss.ws.metadata.wsse.WSSecurityConfiguration;
+
+/**
+ * Service class acts as a factory for:
+ * <ul>
+ * <li>Dynamic proxy for the target service endpoint.
+ * <li>Instance of the type javax.xml.rpc.Call for the dynamic invocation of a
+ * remote operation on the target service endpoint.
+ * <li>Instance of a generated stub class
+ * </ul>
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 10-Oct-2004
+ */
+public class ServiceImpl implements ServiceExt
+{
+ // provide logging
+ private static final Logger log = Logger.getLogger(ServiceImpl.class);
+
+ // The service meta data that is associated with this JAXRPC Service
+ private ServiceMetaData serviceMetaData;
+
+ // The optional WSDL location
+ private URL wsdlLocation;
+
+ // The handler registry
+ private HandlerRegistryImpl handlerRegistry;
+
+ /**
+ * Construct a Service without WSDL meta data
+ */
+ ServiceImpl(QName serviceName)
+ {
+ UnifiedMetaData wsMetaData = new UnifiedMetaData(new ResourceLoaderAdapter());
+ serviceMetaData = new ServiceMetaData(wsMetaData, serviceName);
+ handlerRegistry = new HandlerRegistryImpl(serviceMetaData);
+ }
+
+ /**
+ * Construct a Service that has access to some WSDL meta data
+ */
+ ServiceImpl(QName serviceName, URL wsdlURL, URL mappingURL, URL securityURL)
+ {
+ this.wsdlLocation = wsdlURL;
+ JAXRPCClientMetaDataBuilder builder = new JAXRPCClientMetaDataBuilder();
+
+ ClassLoader ctxClassLoader = Thread.currentThread().getContextClassLoader();
+
+ serviceMetaData = builder.buildMetaData(serviceName, wsdlURL, mappingURL,
securityURL, null, ctxClassLoader);
+ handlerRegistry = new HandlerRegistryImpl(serviceMetaData);
+ }
+
+ /**
+ * Construct a Service that has access to some WSDL meta data
+ */
+ ServiceImpl(QName serviceName, URL wsdlURL, JavaWsdlMapping mappingURL,
WSSecurityConfiguration securityConfig, UnifiedServiceRefMetaData serviceRefMetaData)
+ {
+ this.wsdlLocation = wsdlURL;
+ JAXRPCClientMetaDataBuilder builder = new JAXRPCClientMetaDataBuilder();
+
+ ClassLoader ctxClassLoader = Thread.currentThread().getContextClassLoader();
+
+ serviceMetaData = builder.buildMetaData(serviceName, wsdlURL, mappingURL,
securityConfig, serviceRefMetaData, ctxClassLoader);
+ handlerRegistry = new HandlerRegistryImpl(serviceMetaData);
+ }
+
+ public ServiceMetaData getServiceMetaData()
+ {
+ return serviceMetaData;
+ }
+
+ /**
+ * Gets the location of the WSDL document for this Service.
+ *
+ * @return URL for the location of the WSDL document for this service
+ */
+ public URL getWSDLDocumentLocation()
+ {
+ return wsdlLocation;
+ }
+
+ /**
+ * Gets the name of this service.
+ *
+ * @return Qualified name of this service
+ */
+ public QName getServiceName()
+ {
+ return serviceMetaData.getServiceName();
+ }
+
+ /**
+ * Creates a Call instance.
+ *
+ * @param portName
+ * Qualified name for the target service endpoint
+ * @return Call instance
+ * @throws javax.xml.rpc.ServiceException
+ * If any error in the creation of the Call object
+ */
+ public Call createCall(QName portName) throws ServiceException
+ {
+ String nsURI = portName.getNamespaceURI();
+ serviceMetaData.assertTargetNamespace(nsURI);
+ return new CallImpl(this, portName, null);
+ }
+
+ /**
+ * Creates a Call instance.
+ *
+ * @param portName
+ * Qualified name for the target service endpoint
+ * @param operationName
+ * Name of the operation for which this Call object is to be
+ * created.
+ * @return Call instance
+ * @throws javax.xml.rpc.ServiceException
+ * If any error in the creation of the Call object
+ */
+ public Call createCall(QName portName, String operationName) throws ServiceException
+ {
+ String nsURI = portName.getNamespaceURI();
+ serviceMetaData.assertTargetNamespace(nsURI);
+ QName opName = new QName(nsURI, operationName);
+ return new CallImpl(this, portName, opName);
+ }
+
+ /**
+ * Creates a Call instance.
+ *
+ * @param portName
+ * Qualified name for the target service endpoint
+ * @param opName
+ * Qualified name of the operation for which this Call object is
+ * to be created.
+ * @return Call instance
+ * @throws javax.xml.rpc.ServiceException
+ * If any error in the creation of the Call object
+ */
+ public Call createCall(QName portName, QName opName) throws ServiceException
+ {
+ serviceMetaData.assertTargetNamespace(portName.getNamespaceURI());
+ serviceMetaData.assertTargetNamespace(opName.getNamespaceURI());
+ return new CallImpl(this, portName, opName);
+ }
+
+ /**
+ * Creates a Call object not associated with specific operation or target
+ * service endpoint. This Call object needs to be configured using the
+ * setter methods on the Call interface.
+ *
+ * @return Call object
+ * @throws javax.xml.rpc.ServiceException
+ * If any error in the creation of the Call object
+ */
+ public Call createCall() throws ServiceException
+ {
+ return new CallImpl(this);
+ }
+
+ /**
+ * Gets an array of preconfigured Call objects for invoking operations on
+ * the specified port. There is one Call object per operation that can be
+ * invoked on the specified port. Each Call object is pre-configured and
+ * does not need to be configured using the setter methods on Call
+ * interface. <p/> Each invocation of the getCalls method returns a new
+ * array of preconfigured Call objects <p/> This method requires the Service
+ * implementation class to have access to the WSDL related metadata.
+ *
+ * @param portName
+ * Qualified name for the target service endpoint
+ * @return Call[] Array of pre-configured Call objects
+ * @throws javax.xml.rpc.ServiceException
+ * If this Service class does not have access to the required
+ * WSDL metadata or if an illegal endpointName is specified.
+ */
+ public Call[] getCalls(QName portName) throws ServiceException
+ {
+ EndpointMetaData epMetaData = serviceMetaData.getEndpoint(portName);
+ if (epMetaData == null)
+ throw new ServiceException("Cannot find endpoint for name: " +
portName);
+
+ List<Call> calls = new ArrayList<Call>();
+ for (OperationMetaData opMetaData : epMetaData.getOperations())
+ {
+ Call call = createCall(portName, opMetaData.getQName());
+ calls.add(call);
+ }
+
+ Call[] callArr = new Call[calls.size()];
+ calls.toArray(callArr);
+
+ return callArr;
+ }
+
+ /**
+ * J2EE components should not use the getHandlerRegistry() method. A
+ * container provider must throw a java.lang.UnsupportedOperationException
+ * from the getHandlerRegistry() method of the Service Interface. Handler
+ * support is documented in Chapter 6 Handlers.
+ */
+ public HandlerRegistry getHandlerRegistry()
+ {
+ throw new UnsupportedOperationException("Components should not use the
getHandlerRegistry() method.");
+ }
+
+ /**
+ * Get a HandlerRegistry that can be used to dynamically change the client
+ * side handler chain associated with a given endpoint.
+ */
+ public HandlerRegistry getDynamicHandlerRegistry()
+ {
+ return handlerRegistry;
+ }
+
+ /**
+ * J2EE components should not use the getTypeMappingRegistry() method. A
+ * container provider must throw a java.lang.UnsupportedOperationException
+ * from the getTypeMappingRegistry() method of the Service Interface.
+ */
+ public TypeMappingRegistry getTypeMappingRegistry()
+ {
+ throw new UnsupportedOperationException("Components should not use the
getTypeMappingRegistry() method.");
+ }
+
+ /**
+ * Returns an Iterator for the list of QNames of service endpoints grouped
+ * by this service
+ *
+ * @return Returns java.util.Iterator with elements of type
+ * javax.xml.namespace.QName
+ * @throws javax.xml.rpc.ServiceException
+ * If this Service class does not have access to the required
+ * WSDL metadata
+ */
+ public Iterator getPorts() throws ServiceException
+ {
+ ArrayList<QName> list = new ArrayList<QName>();
+ if (serviceMetaData != null)
+ {
+ for (EndpointMetaData epMetaData : serviceMetaData.getEndpoints())
+ {
+ list.add(epMetaData.getPortName());
+ }
+ }
+ return list.iterator();
+ }
+
+ /**
+ * The getPort method returns either an instance of a generated stub
+ * implementation class or a dynamic proxy. The parameter
+ * serviceEndpointInterface specifies the service endpoint interface that is
+ * supported by the returned stub or proxy. In the implementation of this
+ * method, the JAX-RPC runtime system takes the responsibility of selecting
+ * a protocol binding (and a port) and configuring the stub accordingly. The
+ * returned Stub instance should not be reconfigured by the client.
+ */
+ public Remote getPort(Class seiClass) throws ServiceException
+ {
+ if (seiClass == null)
+ throw new IllegalArgumentException("SEI class cannot be null");
+
+ String seiName = seiClass.getName();
+ if (Remote.class.isAssignableFrom(seiClass) == false)
+ throw new ServiceException("SEI does not implement java.rmi.Remote: "
+ seiName);
+
+ if (serviceMetaData == null)
+ throw new ServiceException("Service meta data not available");
+
+ try
+ {
+ EndpointMetaData epMetaData =
serviceMetaData.getEndpointByServiceEndpointInterface(seiName);
+ if (epMetaData == null && serviceMetaData.getEndpoints().size() == 1)
+ {
+ epMetaData = serviceMetaData.getEndpoints().get(0);
+ epMetaData.setServiceEndpointInterfaceName(seiName);
+ }
+
+ if (epMetaData == null)
+ throw new ServiceException("Cannot find endpoint meta data for: " +
seiName);
+
+ return createProxy(seiClass, epMetaData);
+ }
+ catch (ServiceException ex)
+ {
+ throw ex;
+ }
+ catch (Exception ex)
+ {
+ throw new ServiceException("Cannot create proxy", ex);
+ }
+ }
+
+ /**
+ * The getPort method returns either an instance of a generated stub
+ * implementation class or a dynamic proxy. A service client uses this
+ * dynamic proxy to invoke operations on the target service endpoint. The
+ * serviceEndpointInterface specifies the service endpoint interface that is
+ * supported by the created dynamic proxy or stub instance.
+ */
+ public Remote getPort(QName portName, Class seiClass) throws ServiceException
+ {
+ if (seiClass == null)
+ throw new IllegalArgumentException("SEI class cannot be null");
+
+ if (serviceMetaData == null)
+ throw new ServiceException("Service meta data not available");
+
+ String seiName = seiClass.getName();
+ if (Remote.class.isAssignableFrom(seiClass) == false)
+ throw new ServiceException("SEI does not implement java.rmi.Remote: "
+ seiName);
+
+ EndpointMetaData epMetaData = serviceMetaData.getEndpoint(portName);
+ if (epMetaData == null)
+ throw new ServiceException("Cannot obtain endpoint meta data for: " +
portName);
+
+ try
+ {
+ if (epMetaData.getServiceEndpointInterfaceName() == null)
+ epMetaData.setServiceEndpointInterfaceName(seiName);
+
+ return createProxy(seiClass, epMetaData);
+ }
+ catch (ServiceException ex)
+ {
+ throw ex;
+ }
+ catch (Exception ex)
+ {
+ throw new ServiceException("Cannot create proxy", ex);
+ }
+ }
+
+ private Remote createProxy(Class seiClass, EndpointMetaData epMetaData) throws
Exception
+ {
+ CallImpl call = new CallImpl(this, epMetaData);
+
+ PortProxy handler = new PortProxy(call);
+ ClassLoader cl = epMetaData.getClassLoader();
+ Remote proxy = (Remote)Proxy.newProxyInstance(cl, new Class[] { seiClass,
Stub.class, StubExt.class }, handler);
+
+ return proxy;
+ }
+
+ /**
+ * Get the handler chain for the given endpoint name, maybe null.
+ */
+ public HandlerChain getHandlerChain(QName portName)
+ {
+ return handlerRegistry.getHandlerChainInstance(portName);
+ }
+
+ /**
+ * Register a handler chain for the given endpoint name
+ */
+ public void registerHandlerChain(QName portName, List infos, Set roles)
+ {
+ handlerRegistry.registerClientHandlerChain(portName, infos, roles);
+ }
+
+ void setupHandlerChain(EndpointMetaData epMetaData)
+ {
+ QName portName = epMetaData.getPortName();
+ Set<String> handlerRoles = new HashSet<String>();
+ ArrayList handlerInfos = new ArrayList();
+ for (HandlerMetaData handlerMetaData :
epMetaData.getHandlerMetaData(HandlerType.ALL))
+ {
+ HandlerMetaDataJAXRPC jaxrpcMetaData = (HandlerMetaDataJAXRPC)handlerMetaData;
+ handlerRoles.addAll(jaxrpcMetaData.getSoapRoles());
+
+ HashMap hConfig = new HashMap();
+ for (HandlerInitParam param : jaxrpcMetaData.getInitParams())
+ {
+ hConfig.put(param.getParamName(), param.getParamValue());
+ }
+
+ Set<QName> headers = jaxrpcMetaData.getSoapHeaders();
+ QName[] headerArr = new QName[headers.size()];
+ headers.toArray(headerArr);
+
+ Class hClass = jaxrpcMetaData.getHandlerClass();
+ hConfig.put(HandlerType.class.getName(), jaxrpcMetaData.getHandlerType());
+ HandlerInfo info = new HandlerInfo(hClass, hConfig, headerArr);
+
+ log.debug("Adding client side handler to endpoint '" + portName +
"': " + info);
+ handlerInfos.add(info);
+
+ // register the handlers with the client engine
+ if (handlerInfos.size() > 0)
+ registerHandlerChain(portName, handlerInfos, handlerRoles);
+ }
+ }
+}
Copied:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceObjectFactory.java
(from rev 2172,
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceObjectFactory.java)
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceObjectFactory.java
(rev 0)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceObjectFactory.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -0,0 +1,252 @@
+/*
+ * 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.
+ */
+// $Id$
+package org.jboss.ws.core.jaxrpc.client;
+
+// $Id$
+
+import java.io.BufferedReader;
+import java.io.ByteArrayInputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.io.ObjectInputStream;
+import java.lang.reflect.InvocationHandler;
+import java.lang.reflect.Proxy;
+import java.net.URL;
+import java.net.URLEncoder;
+import java.rmi.Remote;
+import java.util.Hashtable;
+import java.util.List;
+
+import javax.naming.Context;
+import javax.naming.Name;
+import javax.naming.NamingException;
+import javax.naming.RefAddr;
+import javax.naming.Reference;
+import javax.naming.spi.ObjectFactory;
+import javax.xml.namespace.QName;
+import javax.xml.rpc.JAXRPCException;
+import javax.xml.rpc.Service;
+
+import org.jboss.logging.Logger;
+import org.jboss.ws.Constants;
+import org.jboss.ws.WSException;
+import org.jboss.ws.core.server.ServiceEndpoint;
+import org.jboss.ws.core.server.ServiceEndpointManager;
+import org.jboss.ws.core.server.ServiceEndpointManagerFactory;
+import org.jboss.ws.metadata.j2ee.UnifiedPortComponentRefMetaData;
+import org.jboss.ws.metadata.j2ee.UnifiedServiceRefMetaData;
+import org.jboss.ws.metadata.jaxrpcmapping.JavaWsdlMapping;
+import org.jboss.ws.metadata.umdm.EndpointMetaData;
+import org.jboss.ws.metadata.umdm.ServiceMetaData;
+import org.jboss.ws.metadata.wsse.WSSecurityConfiguration;
+
+/**
+ * This ServiceObjectFactory reconstructs a javax.xml.rpc.Service
+ * for a given WSDL when the webservice client does a JNDI lookup
+ * <p/>
+ * It uses the information provided by the service-ref element in application-client.xml
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 15-April-2004
+ */
+public class ServiceObjectFactory implements ObjectFactory
+{
+ // provide logging
+ private static final Logger log = Logger.getLogger(ServiceObjectFactory.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;
+
+ // Unmarshall the ServiceRefMetaData
+ UnifiedServiceRefMetaData serviceRefMetaData = null;
+ RefAddr metaRefAddr = ref.get(ServiceReferenceable.SERVICE_REF_META_DATA);
+ ByteArrayInputStream bais = new
ByteArrayInputStream((byte[])metaRefAddr.getContent());
+ try
+ {
+ ObjectInputStream ois = new ObjectInputStream(bais);
+ serviceRefMetaData = (UnifiedServiceRefMetaData)ois.readObject();
+ ois.close();
+ }
+ catch (IOException ex)
+ {
+ NamingException ne = new NamingException("Cannot unmarshall service ref
meta data");
+ ne.setRootCause(ex);
+ throw ne;
+ }
+
+ // Unmarshall the WSSecurityConfiguration
+ WSSecurityConfiguration securityConfig = null;
+ RefAddr wsseRefAddr = ref.get(ServiceReferenceable.SECURITY_CONFIG);
+ if (wsseRefAddr != null)
+ {
+ bais = new ByteArrayInputStream((byte[])wsseRefAddr.getContent());
+ try
+ {
+ ObjectInputStream ois = new ObjectInputStream(bais);
+ securityConfig = (WSSecurityConfiguration)ois.readObject();
+ ois.close();
+ }
+ catch (IOException e)
+ {
+ throw new NamingException("Cannot unmarshall security config, cause:
" + e.toString());
+ }
+ }
+
+ ServiceImpl jaxrpcService = null;
+ URL wsdlLocation = serviceRefMetaData.getWsdlLocation();
+ if (wsdlLocation != null)
+ {
+ log.debug("Create jaxrpc service from wsdl");
+
+ // Create the actual service object
+ QName serviceName = serviceRefMetaData.getServiceQName();
+ JavaWsdlMapping javaWsdlMapping =
(JavaWsdlMapping)serviceRefMetaData.getJavaWsdlMapping();
+ jaxrpcService = new ServiceImpl(serviceName, wsdlLocation, javaWsdlMapping,
securityConfig, serviceRefMetaData);
+ }
+ else
+ {
+ log.debug("Create jaxrpc service with no wsdl");
+ jaxrpcService = new ServiceImpl(new QName(Constants.NS_JBOSSWS_URI,
"AnonymousService"));
+ }
+
+ // Set any service level properties
+ ServiceMetaData serviceMetaData = jaxrpcService.getServiceMetaData();
+ serviceMetaData.setProperties(serviceRefMetaData.getCallProperties());
+
+ // The web service client using a port-component-link, the contet is the URL to
+ // the PortComponentLinkServlet that will return the actual endpoint address
+ RefAddr pcLinkRef = ref.get(ServiceReferenceable.PORT_COMPONENT_LINK);
+ if (pcLinkRef != null)
+ {
+ String pcLink = (String)pcLinkRef.getContent();
+ log.debug("Resolving port-component-link: " + pcLink);
+
+ // First try to obtain the endpoint address loacally
+ String endpointAddress = null;
+ try
+ {
+ ServiceEndpointManagerFactory factory =
ServiceEndpointManagerFactory.getInstance();
+ ServiceEndpointManager epManager = factory.getServiceEndpointManager();
+ ServiceEndpoint serviceEndpoint =
epManager.resolvePortComponentLink(pcLink);
+ if (serviceEndpoint == null)
+ throw new WSException("Cannot resolve port-component-link: "
+ pcLink);
+
+ endpointAddress =
serviceEndpoint.getServiceEndpointInfo().getServerEndpointMetaData().getEndpointAddress();
+ }
+ catch (Exception ex)
+ {
+ // ignore, we are probably a remote client
+ }
+
+ // We may be remote in the esoteric case where an appclient uses the
port-comonent-link feature
+ if (endpointAddress == null)
+ {
+ String servletPath =
(String)ref.get(ServiceReferenceable.PORT_COMPONENT_LINK_SERVLET).getContent();
+ servletPath += "?pcLink=" + URLEncoder.encode(pcLink,
"UTF-8");
+ InputStream is = new URL(servletPath).openStream();
+ BufferedReader br = new BufferedReader(new InputStreamReader(is));
+ endpointAddress = br.readLine();
+ is.close();
+ }
+
+ log.debug("Resolved to: " + endpointAddress);
+ if (serviceMetaData.getEndpoints().size() == 1)
+ {
+ EndpointMetaData epMetaData = serviceMetaData.getEndpoints().get(0);
+ epMetaData.setEndpointAddress(endpointAddress);
+ }
+ else
+ {
+ log.warn("Cannot set endpoint address for port-component-link,
unsuported number of endpoints");
+ }
+ }
+
+ /********************************************************
+ * Setup the Proxy that implements the service-interface
+ ********************************************************/
+
+ // load the service interface class
+ ClassLoader contextCL = Thread.currentThread().getContextClassLoader();
+ Class siClass = contextCL.loadClass(serviceRefMetaData.getServiceInterface());
+ if (Service.class.isAssignableFrom(siClass) == false)
+ throw new JAXRPCException("The service interface does not implement
javax.xml.rpc.Service: " + siClass.getName());
+
+ // load all service endpoint interface classes
+ UnifiedPortComponentRefMetaData[] pcrArray =
serviceRefMetaData.getPortComponentRefs();
+ for (int i = 0; i < pcrArray.length; i++)
+ {
+ UnifiedPortComponentRefMetaData pcr = pcrArray[i];
+ Class seiClass = contextCL.loadClass(pcr.getServiceEndpointInterface());
+ if (Remote.class.isAssignableFrom(seiClass) == false)
+ throw new IllegalArgumentException("The SEI does not implement
java.rmi.Remote: " + seiClass.getName());
+ }
+
+ // Setup the handler chain
+ setupHandlerChain(jaxrpcService);
+
+ InvocationHandler handler = new ServiceProxy(jaxrpcService, siClass);
+ return Proxy.newProxyInstance(contextCL, new Class[] { siClass, ServiceExt.class
}, handler);
+ }
+ catch (Exception ex)
+ {
+ log.error("Cannot create service", ex);
+ throw ex;
+ }
+ }
+
+ /**
+ * Setup the handler chain(s) for this service
+ */
+ private void setupHandlerChain(ServiceImpl jaxrpcService) throws Exception
+ {
+ List<EndpointMetaData> endpoints =
jaxrpcService.getServiceMetaData().getEndpoints();
+ for (EndpointMetaData epMetaData : endpoints)
+ {
+ jaxrpcService.setupHandlerChain(epMetaData);
+ }
+ }
+}
Copied:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceProxy.java
(from rev 2172,
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/ServiceProxy.java)
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceProxy.java
(rev 0)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceProxy.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -0,0 +1,162 @@
+/*
+* 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.
+*/
+// $Id$
+package org.jboss.ws.core.jaxrpc.client;
+
+// $Id$
+
+import java.lang.reflect.InvocationHandler;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.rmi.Remote;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+import javax.xml.rpc.JAXRPCException;
+import javax.xml.rpc.Service;
+
+import org.jboss.logging.Logger;
+
+/**
+ * This is the proxy that implements the service interface .
+ * <p/>
+ * Additionally it handles some ws4ee functionality that is not part of jaxrpc
behaviour.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 15-May-2004
+ */
+public class ServiceProxy implements InvocationHandler
+{
+ // provide logging
+ private static final Logger log = Logger.getLogger(ServiceProxy.class);
+
+ // The underlying jaxrpc service
+ private ServiceImpl jaxrpcService;
+
+ // The methods from java.lang.Object
+ private List objectMethods = new ArrayList();
+ // The methods from javax.xml.rpc.Service
+ private List jaxrpcServiceMethods = new ArrayList();
+ // The methods from the service interface, in case of javax.xml.rpc.Service it is
empty
+ private List serviceInterfaceMethods = new ArrayList();
+
+ // The cached getPort method
+ private Method getPortMethod;
+
+ /**
+ * Construct a client side service proxy.
+ * <p/>
+ * This proxy implements the (generated) service interface.
+ *
+ * @param service The underlying {@link javax.xml.rpc.Service}
+ * @param siClass The service interface, a subclass of {@link javax.xml.rpc.Service}
+ */
+ public ServiceProxy(ServiceImpl service, Class siClass)
+ {
+ this.jaxrpcService = service;
+
+ // initialize java.lang.Object methods
+ objectMethods.addAll(Arrays.asList(Object.class.getMethods()));
+
+ // initialize javax.xml.rpc.Service methods
+ jaxrpcServiceMethods.addAll(Arrays.asList(ServiceExt.class.getMethods()));
+
+ // initialize SI methods
+ if (siClass.getName().equals("javax.xml.rpc.Service") == false)
+ serviceInterfaceMethods.addAll(Arrays.asList(siClass.getDeclaredMethods()));
+
+ // initialize special ws4ee methods
+ try
+ {
+ getPortMethod = Service.class.getMethod("getPort", new
Class[]{Class.class});
+ }
+ catch (NoSuchMethodException e)
+ {
+ throw new JAXRPCException(e.toString());
+ }
+ }
+
+ /**
+ * Processes a method invocation on a proxy instance and returns
+ * the result.
+ */
+ public Object invoke(Object proxy, Method method, Object[] args) throws Throwable
+ {
+ String methodName = method.getName();
+
+ try
+ {
+ Object retObj = null;
+ if (jaxrpcServiceMethods.contains(method))
+ {
+ log.debug("Invoke on jaxrpc service: " + methodName);
+
+ if (method.getName().equals("getPort"))
+ {
+ Remote port = (Remote)method.invoke(jaxrpcService, args);
+ return port;
+ }
+ else
+ {
+ retObj = method.invoke(jaxrpcService, args);
+ return retObj;
+ }
+ }
+ if (serviceInterfaceMethods.contains(method))
+ {
+ log.debug("Invoke on service interface: " + methodName);
+
+ Class seiClass = method.getReturnType();
+ retObj = getPortMethod.invoke(jaxrpcService, new Object[]{seiClass});
+ return retObj;
+ }
+ if (objectMethods.contains(method))
+ {
+ log.debug("Invoke on object: " + methodName);
+
+ retObj = method.invoke(jaxrpcService, args);
+ return retObj;
+ }
+
+ throw new JAXRPCException("Don't know how to invoke: " + method);
+ }
+ catch (Exception e)
+ {
+ handleException(e);
+ return null;
+ }
+ }
+
+ /**
+ * Log the client side exception
+ */
+ private void handleException(Exception ex) throws Throwable
+ {
+ Throwable th = ex;
+ if (ex instanceof InvocationTargetException)
+ th = ((InvocationTargetException)ex).getTargetException();
+
+ log.error("Service error", th);
+ throw th;
+ }
+}
\ No newline at end of file
Modified:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceReferenceable.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceReferenceable.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/core/jaxrpc/client/ServiceReferenceable.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -37,7 +37,6 @@
import javax.naming.StringRefAddr;
import org.jboss.logging.Logger;
-import org.jboss.ws.core.jaxrpc.ServiceObjectFactory;
import org.jboss.ws.core.server.ServiceEndpointManager;
import org.jboss.ws.core.server.ServiceEndpointManagerFactory;
import org.jboss.ws.core.server.UnifiedDeploymentInfo;
Modified:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/jaxrpc/ServiceFactoryImpl.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/jaxrpc/ServiceFactoryImpl.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/jaxrpc/ServiceFactoryImpl.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -28,6 +28,6 @@
* Included for backwards compatibility
* @deprecated
*/
-public class ServiceFactoryImpl extends org.jboss.ws.core.jaxrpc.ServiceFactoryImpl
+public class ServiceFactoryImpl extends
org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl
{
}
Modified:
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-core/src/main/java/org/jboss/ws/metadata/j2ee/UnifiedBeanMetaData.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -80,12 +80,12 @@
this.portComponent = portComponent;
}
- public String getServiceEndpoint()
+ public String getServiceEndpointInterface()
{
return seiName;
}
- public void setServiceEndpoint(String seiName)
+ public void setServiceEndpointInterface(String seiName)
{
this.seiName = seiName;
}
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/common/binding/SOAPBindingTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/common/binding/SOAPBindingTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/common/binding/SOAPBindingTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -41,7 +41,7 @@
import org.jboss.ws.core.CommonMessageContext;
import org.jboss.ws.core.CommonSOAPBinding;
import org.jboss.ws.core.EndpointInvocation;
-import org.jboss.ws.core.jaxrpc.CallImpl;
+import org.jboss.ws.core.jaxrpc.client.CallImpl;
import org.jboss.ws.core.jaxrpc.handler.SOAPMessageContextJAXRPC;
import org.jboss.ws.core.soap.MessageContextAssociation;
import org.jboss.ws.core.soap.MessageFactoryImpl;
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/common/soap/attachment/GenericAttachmentTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/common/soap/attachment/GenericAttachmentTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/common/soap/attachment/GenericAttachmentTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -45,7 +45,7 @@
import org.jboss.ws.core.CommonBindingProvider;
import org.jboss.ws.core.CommonSOAPBinding;
import org.jboss.ws.core.EndpointInvocation;
-import org.jboss.ws.core.jaxrpc.CallImpl;
+import org.jboss.ws.core.jaxrpc.client.CallImpl;
import org.jboss.ws.core.jaxrpc.handler.SOAPMessageContextJAXRPC;
import org.jboss.ws.core.soap.MessageContextAssociation;
import org.jboss.ws.core.soap.MessageFactoryImpl;
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1093/JBWS1093TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1093/JBWS1093TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1093/JBWS1093TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -35,7 +35,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test case to test that when a deployment contains both an endpoint and a
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1107/JBWS1107TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1107/JBWS1107TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1107/JBWS1107TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -32,7 +32,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test case to test that an endpoint can be accessed if there is whitespace
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1124/JBWS1124TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1124/JBWS1124TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1124/JBWS1124TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -31,7 +31,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Scoped class loading domains for WS endpoints
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1186/JBWS1186TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1186/JBWS1186TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1186/JBWS1186TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -37,7 +37,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* The prefix "xsi" for attribute "xsi:nil" is not bound
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1378/JBWS1378TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1378/JBWS1378TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1378/JBWS1378TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,7 +33,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* NPE in replaceAddressLocation with SOAP1.2 WSDL
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1384/JBWS1384TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -35,7 +35,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.core.StubExt;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
import org.jboss.ws.tools.WSTools;
/**
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1386/JBWS1386TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1386/JBWS1386TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1386/JBWS1386TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,7 +33,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* [JBWS-1386] - ComplexType with base64Binary property
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1410/JBWS1410TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -35,7 +35,7 @@
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.core.StubExt;
import org.jboss.ws.core.WSTimeoutException;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* NumberFormatException From StubExt.PROPERTY_CLIENT_TIMEOUT
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1427/JBWS1427TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1427/JBWS1427TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws1427/JBWS1427TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -35,7 +35,7 @@
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.test.ws.jaxrpc.jbws1427.interfaces.RequestService;
import org.jboss.test.ws.jaxrpc.jbws1427.services.Message;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
import org.jboss.ws.tools.wsdl.WSDLDefinitionsFactory;
/**
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws950/JBWS950TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws950/JBWS950TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws950/JBWS950TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -32,7 +32,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Attributes of type xsd:QName incorrectly serialized
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws956/JBWS956TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws956/JBWS956TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/jbws956/JBWS956TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -32,7 +32,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Deserialization of complex bean containing an array of complex beans
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/marshall/MarshallRpcLitDIITestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/marshall/MarshallRpcLitDIITestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/marshall/MarshallRpcLitDIITestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -35,7 +35,7 @@
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.test.ws.jaxrpc.marshall.types.JavaBean;
import org.jboss.ws.Constants;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test the Dynamic Invocation Interface (DII) on the Call
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/docstyle/bare/TrivialServiceDocBareTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/docstyle/bare/TrivialServiceDocBareTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/docstyle/bare/TrivialServiceDocBareTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,7 +33,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test JSE test case for an document/literal/bare style service.
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/docstyle/wrapped/TrivialServiceDocWrappedTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/docstyle/wrapped/TrivialServiceDocWrappedTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/docstyle/wrapped/TrivialServiceDocWrappedTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,7 +33,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test JSE test case for an document/literal/wrapped style service.
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/dynamichandler/DynamicHandlerTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/dynamichandler/DynamicHandlerTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/dynamichandler/DynamicHandlerTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -35,7 +35,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceExt;
+import org.jboss.ws.core.jaxrpc.client.ServiceExt;
import org.jboss.ws.core.utils.ObjectNameFactory;
import org.jboss.ws.metadata.umdm.HandlerMetaData;
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/exception/ExceptionTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/exception/ExceptionTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/exception/ExceptionTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -48,7 +48,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test user exception propagation.
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderClientTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderClientTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderClientTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -37,7 +37,7 @@
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.Constants;
import org.jboss.ws.core.StubExt;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test bound and unbound headers
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderDIITestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderDIITestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderDIITestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -35,7 +35,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.Constants;
-import org.jboss.ws.core.jaxrpc.CallImpl;
+import org.jboss.ws.core.jaxrpc.client.CallImpl;
/**
* Test the Dynamic Invocation Interface (DII) on the Call
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderProxyTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderProxyTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/handler/HeaderProxyTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -34,8 +34,8 @@
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.Constants;
import org.jboss.ws.core.StubExt;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
-import org.jboss.ws.core.jaxrpc.ServiceImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceImpl;
/**
* Test bound and unbound headers
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/holder/HolderTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/holder/HolderTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/holder/HolderTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -56,7 +56,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test Holders
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcDIIConfiguredCallTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcDIIConfiguredCallTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcDIIConfiguredCallTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,8 +33,8 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
-import org.jboss.ws.core.jaxrpc.ServiceImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceImpl;
/**
* Test the Dynamic Invocation Interface (DII) on a Call that is preconfigured from WSDL
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcDIIUnconfiguredCallTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcDIIUnconfiguredCallTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcDIIUnconfiguredCallTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -34,7 +34,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.Constants;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test the Dynamic Invocation Interface (DII) on the Call
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcProxyTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcProxyTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109ejb/RpcProxyTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -30,8 +30,8 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
-import org.jboss.ws.core.jaxrpc.ServiceImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceImpl;
/**
* Test the DynamicProxy Call
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/DocJSETestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/DocJSETestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/DocJSETestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,7 +33,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test JSE endpoint for a document style service.
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcDIIConfiguredCallTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcDIIConfiguredCallTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcDIIConfiguredCallTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,8 +33,8 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
-import org.jboss.ws.core.jaxrpc.ServiceImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceImpl;
/**
* Test the Dynamic Invocation Interface (DII) on a Call that is preconfigured from WSDL
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcDIIUnconfiguredCallTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcDIIUnconfiguredCallTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcDIIUnconfiguredCallTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -34,7 +34,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.Constants;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test the Dynamic Invocation Interface (DII) on the Call
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcJSETestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcJSETestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcJSETestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,7 +33,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test JSE test case for an rpc style service.
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcProxyTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcProxyTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/jsr109pojo/RpcProxyTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -30,8 +30,8 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
-import org.jboss.ws.core.jaxrpc.ServiceImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceImpl;
/**
* Test the DynamicProxy Call
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/message/MessageTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/message/MessageTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/message/MessageTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -50,7 +50,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
import org.jboss.ws.core.utils.DOMUtils;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/mtom/MTOMTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/mtom/MTOMTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/mtom/MTOMTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -39,7 +39,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.core.StubExt;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test SOAP with XOP through the JAXRPC dynamic proxy layer.
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/oneway/OneWayTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/oneway/OneWayTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/oneway/OneWayTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,7 +33,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test JSE test case for onway operations.
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/rpcstyle/TrivialServiceRpcTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/rpcstyle/TrivialServiceRpcTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/rpcstyle/TrivialServiceRpcTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,7 +33,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test JSE test case for an rpc style service.
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/swa/AttachmentProxyTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/swa/AttachmentProxyTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/swa/AttachmentProxyTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -40,7 +40,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
* Test SOAP with Attachements (SwA) through the JAXRPC dynamic proxy layer.
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/SimpleEncryptTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/SimpleEncryptTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/SimpleEncryptTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -34,8 +34,8 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.core.StubExt;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
-import org.jboss.ws.core.jaxrpc.ServiceImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceImpl;
/**
* Test WS-Security with RPC/Literal
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/SimpleSignTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/SimpleSignTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/SimpleSignTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -34,8 +34,8 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
import org.jboss.ws.core.StubExt;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
-import org.jboss.ws.core.jaxrpc.ServiceImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceImpl;
/**
* Test WS-Security with RPC/Literal
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/StorePassEncryptTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/StorePassEncryptTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/samples/wssecurity/StorePassEncryptTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -37,8 +37,8 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
-import org.jboss.ws.core.jaxrpc.ServiceImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceImpl;
import org.jboss.ws.extensions.security.jaxrpc.WSSecurityHandlerOutbound;
/**
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefClientTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefClientTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefClientTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -34,7 +34,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
import org.jboss.ws.tools.wsdl.WSDLDefinitionsFactory;
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefEJBTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefEJBTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefEJBTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,7 +33,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
import org.jboss.ws.tools.wsdl.WSDLDefinitionsFactory;
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefServletTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefServletTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxrpc/webserviceref/WebServiceRefServletTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -34,7 +34,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
import org.jboss.ws.tools.wsdl.WSDLDefinitionsFactory;
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jbws1178/JBWS1178TestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jbws1178/JBWS1178TestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jbws1178/JBWS1178TestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -34,7 +34,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.CallImpl;
+import org.jboss.ws.core.jaxrpc.client.CallImpl;
/**
* [JBWS-1178] Multiple virtual host and soap:address problem
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/complex/client/JSR181ComplexTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/complex/client/JSR181ComplexTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/complex/client/JSR181ComplexTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -32,7 +32,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
/**
*
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/webparam/JSR181WebParamTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/webparam/JSR181WebParamTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/webparam/JSR181WebParamTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -32,8 +32,8 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.CallImpl;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.CallImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
import org.jboss.ws.metadata.umdm.OperationMetaData;
import org.jboss.ws.metadata.umdm.ParameterMetaData;
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/webresult/JSR181WebResultTestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/webresult/JSR181WebResultTestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/jsr181/webresult/JSR181WebResultTestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -37,8 +37,8 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.CallImpl;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.CallImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
import org.jboss.ws.core.soap.NameImpl;
import org.jboss.ws.metadata.umdm.OperationMetaData;
Modified:
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/samples/jsr181pojo/JSR181WebServiceJSETestCase.java
===================================================================
---
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/samples/jsr181pojo/JSR181WebServiceJSETestCase.java 2007-01-29
12:14:45 UTC (rev 2174)
+++
branches/jbossws-1.2.0/jbossws-tests/src/main/java/org/jboss/test/ws/jaxws/samples/jsr181pojo/JSR181WebServiceJSETestCase.java 2007-01-29
13:02:19 UTC (rev 2175)
@@ -33,7 +33,7 @@
import org.jboss.test.ws.JBossWSTest;
import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.core.jaxrpc.ServiceFactoryImpl;
+import org.jboss.ws.core.jaxrpc.client.ServiceFactoryImpl;
import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
import org.jboss.ws.tools.wsdl.WSDLDefinitionsFactory;