summaryrefslogtreecommitdiffstats
path: root/sca-java-2.x/trunk
diff options
context:
space:
mode:
authorslaws <slaws@13f79535-47bb-0310-9956-ffa450edef68>2012-01-06 12:19:29 +0000
committerslaws <slaws@13f79535-47bb-0310-9956-ffa450edef68>2012-01-06 12:19:29 +0000
commitd0e15154ff66a8422425259d0b3b3a776a004cd5 (patch)
tree5b7d836a97ed3bc66a5b3b513d6af0c80e1cb80f /sca-java-2.x/trunk
parentcd8c29db34ed6e6aab5c2b05ab6cc34081ccbc35 (diff)
TUSCANY-4000 - Fix ClassCastException when user specifies WSDL interface
TUSCANY-4003 - Provide access to resource host from the resource itself. Thanks for the patch Brian git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1228143 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to '')
-rw-r--r--sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/injection/ResourceObjectFactory.java3
-rw-r--r--sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaAsyncImplementationInvoker.java7
-rw-r--r--sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaComponentContextProvider.java7
-rw-r--r--sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaImplementationInvoker.java20
-rw-r--r--sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaImplementationProvider.java11
-rw-r--r--sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/JavaResourceImpl.java15
-rw-r--r--sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/ResourceHost.java (renamed from sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/injection/ResourceHost.java)93
-rw-r--r--sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/ResourceResolutionException.java (renamed from sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/injection/ResourceResolutionException.java)86
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/pom.xml127
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorld.java32
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallback.java31
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallbackService.java34
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallbackServiceImpl.java53
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldImpl.java84
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplCallbackService.wsdl87
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplCallbackService_schema1.xsd60
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService.wsdl115
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService_schema1.xsd99
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService_schema2.xsd40
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldServiceService_schema1.xsd70
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/META-INF/sca-contribution.xml23
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/helloworld-external-service.wsdl75
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/helloworld.composite48
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/launcher-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/launcher/axis2/CallbackWSDLIfaceTestCase.java112
-rw-r--r--sca-java-2.x/trunk/testing/itest/ws/pom.xml1
25 files changed, 1222 insertions, 111 deletions
diff --git a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/injection/ResourceObjectFactory.java b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/injection/ResourceObjectFactory.java
index 8f55eb18bc..8e2cd66299 100644
--- a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/injection/ResourceObjectFactory.java
+++ b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/injection/ResourceObjectFactory.java
@@ -21,6 +21,9 @@ package org.apache.tuscany.sca.implementation.java.injection;
import org.apache.tuscany.sca.core.factory.ObjectCreationException;
import org.apache.tuscany.sca.core.factory.ObjectFactory;
+import org.apache.tuscany.sca.implementation.java.ResourceHost;
+import org.apache.tuscany.sca.implementation.java.ResourceResolutionException;
+
/**
* Resolves a runtime resource to be injected on a field or method of a Java component type marked with {@link
* javax.annotation.Resource}. If the mapped name of the resource is an absolute URI such as
diff --git a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaAsyncImplementationInvoker.java b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaAsyncImplementationInvoker.java
index 259e3a66ad..759724484e 100644
--- a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaAsyncImplementationInvoker.java
+++ b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaAsyncImplementationInvoker.java
@@ -26,7 +26,6 @@ import org.apache.tuscany.sca.core.factory.InstanceWrapper;
import org.apache.tuscany.sca.core.factory.ObjectCreationException;
import org.apache.tuscany.sca.core.invocation.AsyncResponseException;
import org.apache.tuscany.sca.interfacedef.DataType;
-import org.apache.tuscany.sca.interfacedef.InterfaceContract;
import org.apache.tuscany.sca.interfacedef.Operation;
import org.apache.tuscany.sca.interfacedef.java.JavaOperation;
import org.apache.tuscany.sca.invocation.InterceptorAsync;
@@ -34,6 +33,7 @@ import org.apache.tuscany.sca.invocation.Invoker;
import org.apache.tuscany.sca.invocation.InvokerAsyncResponse;
import org.apache.tuscany.sca.invocation.Message;
import org.apache.tuscany.sca.runtime.RuntimeComponent;
+import org.apache.tuscany.sca.runtime.RuntimeComponentService;
import org.oasisopen.sca.ResponseDispatch;
import org.oasisopen.sca.ServiceRuntimeException;
@@ -44,9 +44,8 @@ import org.oasisopen.sca.ServiceRuntimeException;
*/
public class JavaAsyncImplementationInvoker extends JavaImplementationInvoker implements InterceptorAsync {
- public JavaAsyncImplementationInvoker(Operation operation, Method method, RuntimeComponent component,
- InterfaceContract interfaceContract) {
- super( operation, method, component, interfaceContract);
+ public JavaAsyncImplementationInvoker(Operation operation, Method method, RuntimeComponent component, RuntimeComponentService service) {
+ super( operation, method, component, service);
assert method != null : "Operation method cannot be null";
assert ((JavaOperation) operation).isAsyncServer() : "Operation must be async";
} // end constructor
diff --git a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaComponentContextProvider.java b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaComponentContextProvider.java
index 1fa51315c3..403d8da3b9 100644
--- a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaComponentContextProvider.java
+++ b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaComponentContextProvider.java
@@ -65,6 +65,7 @@ import org.apache.tuscany.sca.interfacedef.java.impl.JavaInterfaceUtil;
import org.apache.tuscany.sca.invocation.Invoker;
import org.apache.tuscany.sca.runtime.RuntimeComponent;
import org.apache.tuscany.sca.runtime.RuntimeComponentReference;
+import org.apache.tuscany.sca.runtime.RuntimeComponentService;
import org.apache.tuscany.sca.runtime.RuntimeEndpointReference;
import org.oasisopen.sca.ServiceReference;
@@ -303,15 +304,15 @@ public class JavaComponentContextProvider {
//cleanUpPolicyHandlers();
}
- Invoker createInvoker(Operation operation, InterfaceContract interfaceContract) throws NoSuchMethodException {
+ Invoker createInvoker(Operation operation, RuntimeComponentService service) throws NoSuchMethodException {
Class<?> implClass = instanceFactoryProvider.getImplementationClass();
Method method = JavaInterfaceUtil.findMethod(implClass, operation);
if (operation instanceof JavaOperation &&
((JavaOperation) operation).isAsyncServer() ) {
- return new JavaAsyncImplementationInvoker(operation, method, component, interfaceContract);
+ return new JavaAsyncImplementationInvoker(operation, method, component, service);
} else {
- return new JavaImplementationInvoker(operation, method, component, interfaceContract);
+ return new JavaImplementationInvoker(operation, method, component, service);
} // end if
} // end
diff --git a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaImplementationInvoker.java b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaImplementationInvoker.java
index de15651227..9ea50fce73 100644
--- a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaImplementationInvoker.java
+++ b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaImplementationInvoker.java
@@ -18,8 +18,6 @@
*/
package org.apache.tuscany.sca.implementation.java.invocation;
-
-
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.security.AccessController;
@@ -30,6 +28,7 @@ import java.util.List;
import javax.xml.ws.Holder;
import org.apache.tuscany.sca.assembly.EndpointReference;
+import org.apache.tuscany.sca.assembly.Service;
import org.apache.tuscany.sca.core.factory.ObjectCreationException;
import org.apache.tuscany.sca.core.invocation.Constants;
import org.apache.tuscany.sca.core.scope.Scope;
@@ -49,6 +48,7 @@ import org.apache.tuscany.sca.invocation.DataExchangeSemantics;
import org.apache.tuscany.sca.invocation.Invoker;
import org.apache.tuscany.sca.invocation.Message;
import org.apache.tuscany.sca.runtime.RuntimeComponent;
+import org.apache.tuscany.sca.runtime.RuntimeComponentService;
import org.oasisopen.sca.ServiceReference;
import org.oasisopen.sca.ServiceRuntimeException;
@@ -61,26 +61,29 @@ import org.oasisopen.sca.ServiceRuntimeException;
public class JavaImplementationInvoker implements Invoker, DataExchangeSemantics {
protected Operation operation;
protected Method method;
+ protected RuntimeComponentService service;
protected boolean allowsPBR;
@SuppressWarnings("unchecked")
protected final ScopeContainer scopeContainer;
private final InterfaceContract interfaze;
- public JavaImplementationInvoker(Operation operation, Method method, RuntimeComponent component, InterfaceContract intf) {
+ public JavaImplementationInvoker(Operation operation, Method method, RuntimeComponent component, RuntimeComponentService service) {
assert method != null : "Operation method cannot be null";
this.method = method;
this.operation = operation;
this.scopeContainer = ((ScopedRuntimeComponent)component).getScopeContainer();
this.allowsPBR = ((JavaImplementation)component.getImplementation()).isAllowsPassByReference(method);
- this.interfaze = intf;
+ this.service = service;
+ this.interfaze = service.getInterfaceContract();
}
- public JavaImplementationInvoker(Operation operation, RuntimeComponent component, InterfaceContract intf) {
+ public JavaImplementationInvoker(Operation operation, RuntimeComponent component, RuntimeComponentService service) {
// used if the method can't be computed statically in advance
this.operation = operation;
this.scopeContainer = ((ScopedRuntimeComponent)component).getScopeContainer();
- this.interfaze = intf;
+ this.service = service;
+ this.interfaze = service.getInterfaceContract();
}
@SuppressWarnings("unchecked")
@@ -121,7 +124,10 @@ public class JavaImplementationInvoker implements Invoker, DataExchangeSemantics
// If there is a callback interface and the implementation is stateless, we need to
// inject callbacks at invocation time. For Composite scope, this has already been done.
if (( interfaze.getCallbackInterface() != null ) && (scopeContainer.getScope().equals(Scope.STATELESS))){
- injectCallbacks(wrapper, (JavaInterface)interfaze.getCallbackInterface());
+ // TUSCANY-4000 - injectCallbacks needs the Java callback interface so get it
+ // from the component type just in case the user has specified a
+ // WSDL interface and hence interfaze is WSDL
+ injectCallbacks(wrapper, (JavaInterface)service.getService().getInterfaceContract().getCallbackInterface());
}
final Object instance = wrapper.getInstance();
diff --git a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaImplementationProvider.java b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaImplementationProvider.java
index 03916909a5..19affac368 100644
--- a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaImplementationProvider.java
+++ b/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/invocation/JavaImplementationProvider.java
@@ -32,8 +32,8 @@ import org.apache.tuscany.sca.core.scope.ScopedImplementationProvider;
import org.apache.tuscany.sca.databinding.DataBindingExtensionPoint;
import org.apache.tuscany.sca.implementation.java.JavaImplementation;
import org.apache.tuscany.sca.implementation.java.JavaResourceImpl;
+import org.apache.tuscany.sca.implementation.java.ResourceHost;
import org.apache.tuscany.sca.implementation.java.injection.RequestContextObjectFactory;
-import org.apache.tuscany.sca.implementation.java.injection.ResourceHost;
import org.apache.tuscany.sca.implementation.java.injection.ResourceObjectFactory;
import org.apache.tuscany.sca.interfacedef.Interface;
import org.apache.tuscany.sca.interfacedef.Operation;
@@ -105,7 +105,8 @@ public class JavaImplementationProvider implements ScopedImplementationProvider,
} else {
boolean optional = resource.isOptional();
String mappedName = resource.getMappedName();
- objectFactory = createResourceObjectFactory(type, mappedName, optional, null);
+ ResourceHost resourceHost = resource.getResourceHost();
+ objectFactory = createResourceObjectFactory(type, mappedName, optional, resourceHost);
}
}
componentContextProvider.addResourceFactory(name, objectFactory);
@@ -121,7 +122,7 @@ public class JavaImplementationProvider implements ScopedImplementationProvider,
public Invoker createInvoker(RuntimeComponentService service, Operation operation) {
try {
- return componentContextProvider.createInvoker(operation, service.getInterfaceContract());
+ return componentContextProvider.createInvoker(operation, service);
} catch (NoSuchMethodException e) {
// It's possible that the instance being invoked is a user-specified
// callback object that isn't an instance of the component implementation
@@ -135,12 +136,12 @@ public class JavaImplementationProvider implements ScopedImplementationProvider,
if (iface instanceof JavaInterface) {
try {
Method method = JavaInterfaceUtil.findMethod(((JavaInterface)iface).getJavaClass(), operation);
- return new JavaImplementationInvoker(operation, method, componentContextProvider.getComponent(), service.getInterfaceContract());
+ return new JavaImplementationInvoker(operation, method, componentContextProvider.getComponent(), service);
} catch (NoSuchMethodException e1) {
throw new IllegalArgumentException(e1);
}
} else {
- return new JavaImplementationInvoker(operation, componentContextProvider.getComponent(), service.getInterfaceContract());
+ return new JavaImplementationInvoker(operation, componentContextProvider.getComponent(), service);
}
}
}
diff --git a/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/JavaResourceImpl.java b/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/JavaResourceImpl.java
index 19a9f38549..90aef45e94 100644
--- a/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/JavaResourceImpl.java
+++ b/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/JavaResourceImpl.java
@@ -18,8 +18,6 @@
*/
package org.apache.tuscany.sca.implementation.java;
-
-
/**
* A resource dependency declared by a Java component implementation
*
@@ -29,10 +27,16 @@ public class JavaResourceImpl {
private JavaElementImpl element;
private String mappedName;
private boolean optional;
+ private ResourceHost resourceHost;
public JavaResourceImpl(JavaElementImpl element) {
this.element = element;
}
+
+ public JavaResourceImpl(JavaElementImpl element, ResourceHost resourceHost) {
+ this.element = element;
+ this.resourceHost = resourceHost;
+ }
/**
* The name of the resource
@@ -82,5 +86,10 @@ public class JavaResourceImpl {
return element;
}
-
+ /**
+ * @return the resourceHost
+ */
+ public ResourceHost getResourceHost() {
+ return resourceHost;
+ }
}
diff --git a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/injection/ResourceHost.java b/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/ResourceHost.java
index 70c368a0e6..4882391087 100644
--- a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/injection/ResourceHost.java
+++ b/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/ResourceHost.java
@@ -1,46 +1,47 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.tuscany.sca.implementation.java.injection;
-
-/**
- * Interface implemented by host environments that allow for resolution of component implementation resources, e.g.
- * items bound in a JNDI tree.
- *
- * @version $Rev$ $Date$
- */
-public interface ResourceHost {
-
- /**
- * Resolve a resource matching the given type
- *
- * @param type the type of the resources
- * @throws ResourceResolutionException if an error is encountered during resolution
- */
- <T> T resolveResource(Class<T> type) throws ResourceResolutionException;
-
- /**
- * Resolve a resource matching the given type and name
- *
- * @param type the type of the resources
- * @param mappedName the mapped name of the resource
- * @throws ResourceResolutionException if an error is encountered during resolution
- */
- <T> T resolveResource(Class<T> type, String mappedName) throws ResourceResolutionException;
-
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.tuscany.sca.implementation.java;
+
+
+/**
+ * Interface implemented by host environments that allow for resolution of component implementation resources, e.g.
+ * items bound in a JNDI tree.
+ *
+ * @version $Rev: 537424 $ $Date: 2007-05-12 14:47:18 +0100 (Sat, 12 May 2007) $
+ */
+public interface ResourceHost {
+
+ /**
+ * Resolve a resource matching the given type
+ *
+ * @param type the type of the resources
+ * @throws ResourceResolutionException if an error is encountered during resolution
+ */
+ <T> T resolveResource(Class<T> type) throws ResourceResolutionException;
+
+ /**
+ * Resolve a resource matching the given type and name
+ *
+ * @param type the type of the resources
+ * @param mappedName the mapped name of the resource
+ * @throws ResourceResolutionException if an error is encountered during resolution
+ */
+ <T> T resolveResource(Class<T> type, String mappedName) throws ResourceResolutionException;
+
+}
diff --git a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/injection/ResourceResolutionException.java b/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/ResourceResolutionException.java
index f94b24762a..36b9ab8c99 100644
--- a/sca-java-2.x/trunk/modules/implementation-java-runtime/src/main/java/org/apache/tuscany/sca/implementation/java/injection/ResourceResolutionException.java
+++ b/sca-java-2.x/trunk/modules/implementation-java/src/main/java/org/apache/tuscany/sca/implementation/java/ResourceResolutionException.java
@@ -1,43 +1,43 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.tuscany.sca.implementation.java.injection;
-
-
-/**
- * @version $Rev$ $Date$
- */
-public class ResourceResolutionException extends Exception {
- private static final long serialVersionUID = 13421352711315479L;
-
- public ResourceResolutionException() {
- super();
- }
-
- public ResourceResolutionException(String message, Throwable cause) {
- super(message, cause);
- }
-
- public ResourceResolutionException(String message) {
- super(message);
- }
-
- public ResourceResolutionException(Throwable cause) {
- super(cause);
- }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.tuscany.sca.implementation.java;
+
+
+/**
+ * @version $Rev: 537424 $ $Date: 2007-05-12 14:47:18 +0100 (Sat, 12 May 2007) $
+ */
+public class ResourceResolutionException extends Exception {
+ private static final long serialVersionUID = 13421352711315479L;
+
+ public ResourceResolutionException() {
+ super();
+ }
+
+ public ResourceResolutionException(String message, Throwable cause) {
+ super(message, cause);
+ }
+
+ public ResourceResolutionException(String message) {
+ super(message);
+ }
+
+ public ResourceResolutionException(Throwable cause) {
+ super(cause);
+ }
+}
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/pom.xml b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/pom.xml
new file mode 100644
index 0000000000..f8a1ae0c02
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/pom.xml
@@ -0,0 +1,127 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+-->
+<project>
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.apache.tuscany.sca</groupId>
+ <artifactId>itest-ws</artifactId>
+ <version>2.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <artifactId>itest-ws-contribution-callback-wsdl-iface</artifactId>
+ <name>Apache Tuscany SCA iTest WS Contribution Callback WSDL Iface </name>
+
+ <dependencies>
+
+ <dependency>
+ <groupId>org.apache.tuscany.sca</groupId>
+ <artifactId>tuscany-base-runtime-pom</artifactId>
+ <type>pom</type>
+ <version>2.0-SNAPSHOT</version>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.tuscany.sca</groupId>
+ <artifactId>tuscany-binding-ws-runtime-axis2</artifactId>
+ <version>2.0-SNAPSHOT</version>
+ </dependency>
+
+ <dependency>
+ <groupId>org.mortbay.jetty</groupId>
+ <artifactId>jetty</artifactId>
+ <version>6.1.19</version>
+ </dependency>
+
+ </dependencies>
+
+ <build>
+ <finalName>${project.artifactId}</finalName>
+ <plugins>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>build-helper-maven-plugin</artifactId>
+ <version>1.0</version>
+ <executions>
+ <execution>
+ <id>add-source</id>
+ <phase>generate-sources</phase>
+ <goals>
+ <goal>add-test-source</goal>
+ </goals>
+ <configuration>
+ <sources>
+ <source>target/jaxws-source</source>
+ </sources>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.jvnet.jax-ws-commons</groupId>
+ <artifactId>jaxws-maven-plugin</artifactId>
+ <version>2.1</version>
+ <dependencies>
+ <dependency>
+ <groupId>com.sun.xml.ws</groupId>
+ <artifactId>jaxws-tools</artifactId>
+ <version>2.2.6-promoted-b10</version>
+ </dependency>
+ </dependencies>
+ <executions>
+ <execution>
+ <id>wsgen1</id>
+ <phase>process-classes</phase>
+ <goals>
+ <goal>wsgen</goal>
+ </goals>
+ <configuration>
+ <sei>org.apache.tuscany.sca.binding.ws.HelloWorldImpl</sei>
+ <genWsdl>true</genWsdl>
+ <staleFile>${project.build.directory}/jaxws/stale/.wsgen1StaleFlag</staleFile>
+ </configuration>
+ </execution>
+ <execution>
+ <id>wsimport1</id>
+ <phase>process-resources</phase>
+ <goals>
+ <goal>wsimport</goal>
+ </goals>
+ <configuration>
+ <packageName>org.apache.tuscany.sca.binding.ws.jaxws.external.service.iface</packageName>
+ <wsdlDirectory>${basedir}/target/classes</wsdlDirectory>
+ <wsdlFiles>
+ <wsdlFile>helloworld-external-service.wsdl</wsdlFile>
+ </wsdlFiles>
+ <staleFile>${project.build.directory}/jaxws/stale/.wsimport1StaleFlag</staleFile>
+ </configuration>
+ </execution>
+ </executions>
+ <configuration>
+ <target>2.1</target>
+ <sourceDestDir>${project.build.directory}/jaxws-source</sourceDestDir>
+ <resourceDestDir>${project.build.directory}/jaxws-source</resourceDestDir>
+ <verbose>true</verbose>
+ <xnocompile>true</xnocompile>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+</project>
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorld.java b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorld.java
new file mode 100644
index 0000000000..6bc67db5fc
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorld.java
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.tuscany.sca.binding.ws;
+
+import org.apache.tuscany.sca.binding.ws.jaxws.external.service.iface.Foo;
+import org.oasisopen.sca.ServiceRuntimeException;
+import org.oasisopen.sca.annotation.Remotable;
+
+@Remotable
+public interface HelloWorld {
+
+ String getGreetings(String s);
+ String getGreetingsException(String s) throws ServiceRuntimeException;
+ Foo getGreetingsComplex(Foo foo);
+}
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallback.java b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallback.java
new file mode 100644
index 0000000000..ba117c8cfd
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallback.java
@@ -0,0 +1,31 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.tuscany.sca.binding.ws;
+
+import org.apache.tuscany.sca.binding.ws.jaxws.external.service.iface.Foo;
+import org.oasisopen.sca.annotation.Remotable;
+
+@Remotable
+public interface HelloWorldCallback {
+
+ String getGreetingsCallback(String s);
+ Foo getGreetingsComplexCallback(Foo foo);
+
+}
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallbackService.java b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallbackService.java
new file mode 100644
index 0000000000..3521fa5624
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallbackService.java
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.tuscany.sca.binding.ws;
+
+import org.apache.tuscany.sca.binding.ws.jaxws.external.service.iface.Foo;
+import org.oasisopen.sca.ServiceRuntimeException;
+import org.oasisopen.sca.annotation.Callback;
+import org.oasisopen.sca.annotation.Remotable;
+
+@Remotable
+@Callback(HelloWorldCallback.class)
+public interface HelloWorldCallbackService {
+
+ String getGreetings(String s);
+ String getGreetingsException(String s) throws ServiceRuntimeException;
+ Foo getGreetingsComplex(Foo foo);
+}
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallbackServiceImpl.java b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallbackServiceImpl.java
new file mode 100644
index 0000000000..057b884bc9
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldCallbackServiceImpl.java
@@ -0,0 +1,53 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.tuscany.sca.binding.ws;
+
+import org.apache.tuscany.sca.binding.ws.jaxws.external.service.iface.Foo;
+import org.oasisopen.sca.ServiceRuntimeException;
+import org.oasisopen.sca.annotation.Callback;
+import org.oasisopen.sca.annotation.Service;
+
+@Service(HelloWorldCallbackService.class)
+public class HelloWorldCallbackServiceImpl implements HelloWorldCallbackService {
+
+ @Callback
+ protected HelloWorldCallback helloWorldCallback;
+
+ public String getGreetings(String s) {
+ System.out.println("Entering SCA HelloWorldCallbackService.getGreetings: " + s);
+ String response = helloWorldCallback.getGreetingsCallback(s);
+ System.out.println("Leaving SCA HelloWorldCallbackService.getGreetings: " + response);
+ return response;
+ }
+
+ public String getGreetingsException(String s) throws ServiceRuntimeException {
+ System.out.println("Entering SCA HelloWorldCallbackService.getGreetingsException: " + s);
+ String response = helloWorldCallback.getGreetingsCallback(s);
+ System.out.println("Leaving SCA HelloWorldCallbackService.getGreetings: " + response);
+ throw new ServiceRuntimeException(response);
+ }
+
+ public Foo getGreetingsComplex(Foo foo){
+ System.out.println("Entering SCA HelloWorldCallbackService.getGreetingsComplex: " + foo.getBars().get(0).getS());
+ Foo response = helloWorldCallback.getGreetingsComplexCallback(foo);
+ System.out.println("Leaving SCA HelloWorldCallbackService.getGreetingsComplex: " + foo.getBars().get(0).getS());
+ return response;
+ }
+}
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldImpl.java b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldImpl.java
new file mode 100644
index 0000000000..1ff58a29b0
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/java/org/apache/tuscany/sca/binding/ws/HelloWorldImpl.java
@@ -0,0 +1,84 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.tuscany.sca.binding.ws;
+
+import javax.jws.WebService;
+
+import org.apache.tuscany.sca.binding.ws.jaxws.external.service.iface.Foo;
+import org.apache.tuscany.sca.binding.ws.jaxws.external.service.iface.HelloWorldService;
+import org.oasisopen.sca.ServiceRuntimeException;
+import org.oasisopen.sca.annotation.Reference;
+
+@WebService
+public class HelloWorldImpl implements HelloWorld, HelloWorldCallback {
+
+ @Reference
+ public HelloWorldService helloWorldExternal;
+
+ @Reference
+ public HelloWorldCallbackService helloWorldCallbackService;
+
+ // HelloWorld operations
+
+ public String getGreetings(String s) {
+ System.out.println("Entering SCA HelloWorld.getGreetings: " + s);
+ String response = helloWorldCallbackService.getGreetings(s);
+ System.out.println("Leaving SCA HelloWorld.getGreetings: " + response);
+ return response;
+ }
+
+ public String getGreetingsException(String s) throws ServiceRuntimeException {
+ System.out.println("Entering SCA HelloWorld.getGreetingsException: " + s);
+ String response = helloWorldCallbackService.getGreetings(s);
+ System.out.println("Leaving SCA HelloWorld.getGreetings: " + response);
+ throw new ServiceRuntimeException(response);
+ }
+
+ public Foo getGreetingsComplex(Foo foo){
+ System.out.println("Entering SCA HelloWorld.getGreetingsComplex: " + foo.getBars().get(0).getS());
+ Foo response = helloWorldCallbackService.getGreetingsComplex(foo);
+ System.out.println("Leaving SCA HelloWorld.getGreetingsComplex: " + foo.getBars().get(0).getS());
+ return response;
+ }
+
+ // HelloWorldCallback operations
+
+ public String getGreetingsCallback(String s) {
+ System.out.println("Entering SCA HelloWorld.getGreetingsCallback: " + s);
+ String response = helloWorldExternal.getGreetings(s);
+ System.out.println("Leaving SCA HelloWorld.getGreetingsCallback: " + response);
+ return response;
+ }
+
+ public String getGreetingsExceptionCallback(String s) throws ServiceRuntimeException {
+ System.out.println("Entering SCA HelloWorld.getGreetingsExceptionCallback: " + s);
+ String response = helloWorldExternal.getGreetings(s);
+ System.out.println("Leaving SCA HelloWorld.getGreetingsCallback: " + response);
+ throw new ServiceRuntimeException(response);
+ }
+
+ public Foo getGreetingsComplexCallback(Foo foo){
+ System.out.println("Entering SCA HelloWorld.getGreetingsComplexCallback: " + foo.getBars().get(0).getS());
+ Foo response = helloWorldExternal.getGreetingsComplex(foo);
+ System.out.println("Leaving SCA HelloWorld.getGreetingsComplexCallback: " + foo.getBars().get(0).getS());
+ return response;
+ }
+
+}
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplCallbackService.wsdl b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplCallbackService.wsdl
new file mode 100644
index 0000000000..6cab010afa
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplCallbackService.wsdl
@@ -0,0 +1,87 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+-->
+<definitions targetNamespace="http://ws.binding.sca.tuscany.apache.org/"
+ name="HelloWorldImplCallbackService"
+ xmlns="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:tns="http://ws.binding.sca.tuscany.apache.org/"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+ <types>
+ <xsd:schema>
+ <xsd:import namespace="http://ws.binding.sca.tuscany.apache.org/"
+ schemaLocation="HelloWorldImplCallbackService_schema1.xsd"/>
+ </xsd:schema>
+ </types>
+
+ <message name="getGreetingsCallback">
+ <part name="parameters" element="tns:getGreetingsCallback"/>
+ </message>
+ <message name="getGreetingsCallbackResponse">
+ <part name="parameters" element="tns:getGreetingsCallbackResponse"/>
+ </message>
+ <message name="getGreetingsComplexCallback">
+ <part name="parameters" element="tns:getGreetingsComplexCallback"/>
+ </message>
+ <message name="getGreetingsComplexCallbackResponse">
+ <part name="parameters" element="tns:getGreetingsComplexCallbackResponse"/>
+ </message>
+
+ <portType name="HelloWorldCallbackImpl">
+ <operation name="getGreetingsCallback">
+ <input message="tns:getGreetingsCallback"/>
+ <output message="tns:getGreetingsCallbackResponse"/>
+ </operation>
+ <operation name="getGreetingsComplexCallback">
+ <input message="tns:getGreetingsComplexCallback"/>
+ <output message="tns:getGreetingsComplexCallbackResponse"/>
+ </operation>
+ </portType>
+
+ <binding name="HelloWorldCallbackImplPortBinding" type="tns:HelloWorldCallbackImpl">
+ <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/>
+ <operation name="getGreetingsCallback">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ </operation>
+ <operation name="getGreetingsComplexCallback">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ </operation>
+ </binding>
+
+ <service name="HelloWorldImplCallbackService">
+ <port name="HelloWorldCallbackImplPort" binding="tns:HelloWorldCallbackImplPortBinding">
+ <soap:address location="http://localhost:8085/HelloWorldService/HelloWorld"/>
+ </port>
+ </service>
+</definitions>
+
+
+
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplCallbackService_schema1.xsd b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplCallbackService_schema1.xsd
new file mode 100644
index 0000000000..53945b50a3
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplCallbackService_schema1.xsd
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+-->
+<xs:schema version="1.0" targetNamespace="http://ws.binding.sca.tuscany.apache.org/"
+ xmlns:tns="http://ws.binding.sca.tuscany.apache.org/"
+ xmlns:tns2="http://helloworld/external"
+ xmlns:xs="http://www.w3.org/2001/XMLSchema">
+
+ <xs:import namespace="http://helloworld/external" schemaLocation="./HelloWorldImplService_schema2.xsd"/>
+
+ <xs:element name="getGreetingsCallback" type="tns:getGreetingsCallback"/>
+
+ <xs:element name="getGreetingsCallbackResponse" type="tns:getGreetingsCallbackResponse"/>
+
+ <xs:element name="getGreetingsComplexCallback" type="tns:getGreetingsComplexCallback"/>
+
+ <xs:element name="getGreetingsComplexCallbackResponse" type="tns:getGreetingsComplexCallbackResponse"/>
+
+ <xs:complexType name="getGreetingsCallback">
+ <xs:sequence>
+ <xs:element name="arg0" type="xs:string" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="getGreetingsCallbackResponse">
+ <xs:sequence>
+ <xs:element name="return" type="xs:string" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="getGreetingsComplexCallback">
+ <xs:sequence>
+ <xs:element name="arg0" type="tns2:foo" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="getGreetingsComplexCallbackResponse">
+ <xs:sequence>
+ <xs:element name="return" type="tns2:foo" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+</xs:schema>
+
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService.wsdl b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService.wsdl
new file mode 100644
index 0000000000..813c23276d
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService.wsdl
@@ -0,0 +1,115 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+-->
+<definitions targetNamespace="http://ws.binding.sca.tuscany.apache.org/"
+ name="HelloWorldImplService"
+ xmlns="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:tns="http://ws.binding.sca.tuscany.apache.org/"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+ <types>
+ <xsd:schema>
+ <xsd:import namespace="http://ws.binding.sca.tuscany.apache.org/"
+ schemaLocation="HelloWorldImplService_schema1.xsd"/>
+ </xsd:schema>
+ </types>
+ <message name="getGreetings">
+ <part name="parameters" element="tns:getGreetings"/>
+ </message>
+ <message name="getGreetingsResponse">
+ <part name="parameters" element="tns:getGreetingsResponse"/>
+ </message>
+ <message name="getGreetingsException">
+ <part name="parameters" element="tns:getGreetingsException"/>
+ </message>
+ <message name="getGreetingsExceptionResponse">
+ <part name="parameters" element="tns:getGreetingsExceptionResponse"/>
+ </message>
+ <message name="Exception">
+ <part name="fault" element="tns:Exception"/>
+ </message>
+ <message name="getGreetingsComplex">
+ <part name="parameters" element="tns:getGreetingsComplex"/>
+ </message>
+ <message name="getGreetingsComplexResponse">
+ <part name="parameters" element="tns:getGreetingsComplexResponse"/>
+ </message>
+ <message name="GetGreetingsCaps">
+ <part name="parameters" element="tns:GetGreetingsCaps"/>
+ </message>
+ <message name="GetGreetingsCapsResponse">
+ <part name="parameters" element="tns:GetGreetingsCapsResponse"/>
+ </message>
+ <portType name="HelloWorldImpl">
+ <operation name="getGreetings">
+ <input message="tns:getGreetings"/>
+ <output message="tns:getGreetingsResponse"/>
+ </operation>
+ <operation name="getGreetingsException">
+ <input message="tns:getGreetingsException"/>
+ <output message="tns:getGreetingsExceptionResponse"/>
+ <fault message="tns:Exception" name="Exception"/>
+ </operation>
+ <operation name="getGreetingsComplex">
+ <input message="tns:getGreetingsComplex"/>
+ <output message="tns:getGreetingsComplexResponse"/>
+ </operation>
+ </portType>
+ <binding name="HelloWorldImplPortBinding" type="tns:HelloWorldImpl">
+ <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/>
+ <operation name="getGreetings">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ </operation>
+ <operation name="getGreetingsException">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ <fault name="Exception">
+ <soap:fault name="Exception" use="literal"/>
+ </fault>
+ </operation>
+ <operation name="getGreetingsComplex">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ </operation>
+ </binding>
+ <service name="HelloWorldImplService">
+ <port name="HelloWorldImplPort" binding="tns:HelloWorldImplPortBinding">
+ <soap:address location="http://localhost:8085/HelloWorldService/HelloWorld"/>
+ </port>
+ </service>
+</definitions>
+
+
+
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService_schema1.xsd b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService_schema1.xsd
new file mode 100644
index 0000000000..2d8adf3d73
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService_schema1.xsd
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+-->
+<xs:schema version="1.0" targetNamespace="http://ws.binding.sca.tuscany.apache.org/"
+ xmlns:tns="http://ws.binding.sca.tuscany.apache.org/"
+ xmlns:tns2="http://helloworld/external"
+ xmlns:xs="http://www.w3.org/2001/XMLSchema">
+
+ <xs:import namespace="http://helloworld/external" schemaLocation="./HelloWorldImplService_schema2.xsd"/>
+
+ <xs:element name="Exception" type="tns:Exception"/>
+
+ <xs:element name="getGreetings" type="tns:getGreetings"/>
+
+ <xs:element name="getGreetingsComplex" type="tns:getGreetingsComplex"/>
+
+ <xs:element name="getGreetingsComplexResponse" type="tns:getGreetingsComplexResponse"/>
+
+ <xs:element name="getGreetingsException" type="tns:getGreetingsException"/>
+
+ <xs:element name="getGreetingsExceptionResponse" type="tns:getGreetingsExceptionResponse"/>
+
+ <xs:element name="getGreetingsResponse" type="tns:getGreetingsResponse"/>
+
+ <xs:element name="GetGreetingsCaps" type="tns:GetGreetingsCaps"/>
+
+ <xs:element name="GetGreetingsCapsResponse" type="tns:GetGreetingsCapsResponse"/>
+
+ <xs:complexType name="getGreetingsException">
+ <xs:sequence>
+ <xs:element name="arg0" type="xs:string" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="getGreetingsExceptionResponse">
+ <xs:sequence>
+ <xs:element name="return" type="xs:string" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="Exception">
+ <xs:sequence>
+ <xs:element name="message" type="xs:string" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="getGreetings">
+ <xs:sequence>
+ <xs:element name="arg0" type="xs:string" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="getGreetingsResponse">
+ <xs:sequence>
+ <xs:element name="return" type="xs:string" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="getGreetingsComplex">
+ <xs:sequence>
+ <xs:element name="arg0" type="tns2:foo" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="getGreetingsComplexResponse">
+ <xs:sequence>
+ <xs:element name="return" type="tns2:foo" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="GetGreetingsCaps">
+ <xs:sequence>
+ <xs:element name="arg0" type="xs:string" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="GetGreetingsCapsResponse">
+ <xs:sequence>
+ <xs:element name="return" type="xs:string" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+</xs:schema>
+
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService_schema2.xsd b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService_schema2.xsd
new file mode 100644
index 0000000000..d955cc2af4
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldImplService_schema2.xsd
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+-->
+<xs:schema version="1.0" targetNamespace="http://helloworld/external"
+ xmlns:tns="http://helloworld/external"
+ xmlns:xs="http://www.w3.org/2001/XMLSchema">
+
+ <xs:complexType name="foo">
+ <xs:sequence>
+ <xs:element name="bars" type="tns:bar" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="bar">
+ <xs:sequence>
+ <xs:element name="b" type="xs:boolean" minOccurs="0"/>
+ <xs:element name="s" type="xs:string" minOccurs="0"/>
+ <xs:element name="x" type="xs:int"/>
+ <xs:element name="y" type="xs:int" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+</xs:schema>
+
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldServiceService_schema1.xsd b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldServiceService_schema1.xsd
new file mode 100644
index 0000000000..acdfcaaaa5
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/HelloWorldServiceService_schema1.xsd
@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+-->
+<xs:schema version="1.0" targetNamespace="http://helloworld/external" xmlns:tns="http://helloworld/external" xmlns:xs="http://www.w3.org/2001/XMLSchema">
+
+ <xs:element name="getGreetings" type="tns:getGreetings"/>
+
+ <xs:element name="getGreetingsComplex" type="tns:getGreetingsComplex"/>
+
+ <xs:element name="getGreetingsComplexResponse" type="tns:getGreetingsComplexResponse"/>
+
+ <xs:element name="getGreetingsResponse" type="tns:getGreetingsResponse"/>
+
+ <xs:complexType name="getGreetings">
+ <xs:sequence>
+ <xs:element name="name" type="xs:string" form="qualified" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="getGreetingsResponse">
+ <xs:sequence>
+ <xs:element name="getGreetingsReturn" type="xs:string" form="qualified" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="getGreetingsComplex">
+ <xs:sequence>
+ <xs:element name="arg0" type="tns:foo" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="foo">
+ <xs:sequence>
+ <xs:element name="bars" type="tns:bar" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="bar">
+ <xs:sequence>
+ <xs:element name="b" type="xs:boolean" minOccurs="0"/>
+ <xs:element name="s" type="xs:string" minOccurs="0"/>
+ <xs:element name="x" type="xs:int"/>
+ <xs:element name="y" type="xs:int" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+
+ <xs:complexType name="getGreetingsComplexResponse">
+ <xs:sequence>
+ <xs:element name="return" type="tns:foo" minOccurs="0"/>
+ </xs:sequence>
+ </xs:complexType>
+</xs:schema>
+
+
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/META-INF/sca-contribution.xml b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/META-INF/sca-contribution.xml
new file mode 100644
index 0000000000..350ad6be96
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/META-INF/sca-contribution.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+-->
+<contribution xmlns="http://docs.oasis-open.org/ns/opencsa/sca/200912"
+ xmlns:itest="http://www.tuscany.apache.org/itests/binding/ws/axis2">
+ <deployable composite="itest:HelloWorld"/>
+</contribution> \ No newline at end of file
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/helloworld-external-service.wsdl b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/helloworld-external-service.wsdl
new file mode 100644
index 0000000000..837bcb059e
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/helloworld-external-service.wsdl
@@ -0,0 +1,75 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+-->
+<!-- Generated by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is JAX-WS RI 2.1.7-b01-. -->
+<definitions targetNamespace="http://helloworld/external" name="HelloWorldServiceService" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://helloworld/external" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
+ <types>
+ <xsd:schema>
+ <xsd:import namespace="http://helloworld/external" schemaLocation="HelloWorldServiceService_schema1.xsd"/>
+ </xsd:schema>
+ </types>
+ <message name="getGreetings">
+ <part name="parameters" element="tns:getGreetings"/>
+ </message>
+ <message name="getGreetingsResponse">
+ <part name="parameters" element="tns:getGreetingsResponse"/>
+ </message>
+ <message name="getGreetingsComplex">
+ <part name="parameters" element="tns:getGreetingsComplex"/>
+ </message>
+ <message name="getGreetingsComplexResponse">
+ <part name="parameters" element="tns:getGreetingsComplexResponse"/>
+ </message>
+ <portType name="HelloWorldService">
+ <operation name="getGreetings">
+ <input message="tns:getGreetings"/>
+ <output message="tns:getGreetingsResponse"/>
+ </operation>
+ <operation name="getGreetingsComplex">
+ <input message="tns:getGreetingsComplex"/>
+ <output message="tns:getGreetingsComplexResponse"/>
+ </operation>
+ </portType>
+ <binding name="HelloWorldServicePortBinding" type="tns:HelloWorldService">
+ <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/>
+ <operation name="getGreetings">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ </operation>
+ <operation name="getGreetingsComplex">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ </operation>
+ </binding>
+ <service name="HelloWorldServiceService">
+ <port name="HelloWorldServicePort" binding="tns:HelloWorldServicePortBinding">
+ <soap:address location="REPLACE_WITH_ACTUAL_URL"/>
+ </port>
+ </service>
+</definitions>
diff --git a/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/helloworld.composite b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/helloworld.composite
new file mode 100644
index 0000000000..dd2d4d6330
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/contribution-callback-wsdl-iface/src/main/resources/helloworld.composite
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+-->
+<composite xmlns="http://docs.oasis-open.org/ns/opencsa/sca/200912"
+ xmlns:sca="http://docs.oasis-open.org/ns/opencsa/sca/200912"
+ targetNamespace="http://www.tuscany.apache.org/itests/binding/ws/axis2"
+ name="HelloWorld">
+
+ <component name="HelloWorldService">
+ <implementation.java class="org.apache.tuscany.sca.binding.ws.HelloWorldImpl"/>
+ <service name="HelloWorld">
+ <binding.ws wsdlElement="http://ws.binding.sca.tuscany.apache.org/#wsdl.port(HelloWorldImplService/HelloWorldImplPort)"/>
+ </service>
+ <reference name="helloWorldExternal">
+ <binding.ws uri="http://localhost:8086/External/HelloWorld"/>
+ </reference>
+ <reference name="helloWorldCallbackService" target="HelloWorldCallbackService">
+ <interface.wsdl interface="http://ws.binding.sca.tuscany.apache.org/#wsdl.porttype(HelloWorldImpl)"
+ callbackInterface="http://ws.binding.sca.tuscany.apache.org/#wsdl.porttype(HelloWorldCallbackImpl)" />
+ </reference>
+ </component>
+
+ <component name="HelloWorldCallbackService">
+ <implementation.java class="org.apache.tuscany.sca.binding.ws.HelloWorldCallbackServiceImpl"/>
+ <service name="HelloWorldCallbackService">
+ <interface.wsdl interface="http://ws.binding.sca.tuscany.apache.org/#wsdl.porttype(HelloWorldImpl)"
+ callbackInterface="http://ws.binding.sca.tuscany.apache.org/#wsdl.porttype(HelloWorldCallbackImpl)" />
+ <binding.ws uri="http://localhost:8085/HelloWorldService/HelloWorldCallbackService"/>
+ </service>
+ </component>
+
+</composite>
diff --git a/sca-java-2.x/trunk/testing/itest/ws/launcher-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/launcher/axis2/CallbackWSDLIfaceTestCase.java b/sca-java-2.x/trunk/testing/itest/ws/launcher-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/launcher/axis2/CallbackWSDLIfaceTestCase.java
new file mode 100644
index 0000000000..c8adcdd7ac
--- /dev/null
+++ b/sca-java-2.x/trunk/testing/itest/ws/launcher-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/launcher/axis2/CallbackWSDLIfaceTestCase.java
@@ -0,0 +1,112 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.tuscany.sca.binding.ws.launcher.axis2;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import org.apache.tuscany.sca.binding.ws.jaxws.external.client.HelloWorldClientLauncher;
+import org.apache.tuscany.sca.binding.ws.jaxws.external.service.HelloWorldServiceLauncher;
+import org.apache.tuscany.sca.binding.ws.jaxws.sca.Bar;
+import org.apache.tuscany.sca.binding.ws.jaxws.sca.Foo;
+import org.apache.tuscany.sca.node.Contribution;
+import org.apache.tuscany.sca.node.Node;
+import org.apache.tuscany.sca.node.NodeFactory;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Ignore;
+import org.junit.Test;
+
+public class CallbackWSDLIfaceTestCase {
+
+ private Node node;
+ private HelloWorldServiceLauncher externalService;
+ private HelloWorldClientLauncher externalClient;
+
+ @Before
+ public void setUp() throws Exception {
+ // Start the external service
+ externalService = new HelloWorldServiceLauncher();
+ externalService.createService();
+
+ // Start the SCA contribution
+ node = NodeFactory.newInstance().createNode(new Contribution("wsdl-iface", "../contribution-callback-wsdl-iface/target/itest-ws-contribution-callback-wsdl-iface.jar"));
+ node.start();
+
+ // start the external client
+ try {
+ externalClient = new HelloWorldClientLauncher();
+ externalClient.createClient();
+ } catch (Exception ex) {
+ ex.printStackTrace();
+ throw ex;
+ }
+ }
+
+/*
+ @Test
+ public void testWait() throws Exception {
+ System.out.println("Press a key");
+ System.in.read();
+ }
+*/
+
+ @Test
+ public void testGetGreetings() throws Exception {
+ assertEquals("Hello Fred", externalClient.getGreetings("Fred"));
+ }
+
+ @Test
+ public void testGetGreetingsComplex() throws Exception {
+ Foo f = new Foo();
+ Bar b1 = new Bar();
+ b1.setS("petra");
+ b1.setX(1);
+ b1.setY(new Integer(2));
+ b1.setB(Boolean.TRUE);
+ Bar b2 = new Bar();
+ b2.setS("beate");
+ b2.setX(3);
+ b2.setY(new Integer(4));
+ b2.setB(Boolean.FALSE);
+ f.getBars().add(b1);
+ f.getBars().add(b2);
+
+ Foo f2 = externalClient.getGreetingsComplex(f);
+
+ assertEquals("petra", f2.getBars().get(0).getS());
+ assertEquals(1, f2.getBars().get(0).getX());
+ assertEquals(2, f2.getBars().get(0).getY().intValue());
+ assertTrue(f2.getBars().get(0).isB());
+ assertEquals("simon", f2.getBars().get(2).getS());
+ assertEquals(7, f2.getBars().get(2).getX());
+ assertEquals(8, f2.getBars().get(2).getY().intValue());
+ assertTrue(f2.getBars().get(2).isB().booleanValue());
+ }
+
+ @After
+ public void tearDown() throws Exception {
+ node.stop();
+ externalClient.destroyClient();
+ externalService.destoryService();
+ }
+
+}
diff --git a/sca-java-2.x/trunk/testing/itest/ws/pom.xml b/sca-java-2.x/trunk/testing/itest/ws/pom.xml
index 54ad4da005..e14a5474c1 100644
--- a/sca-java-2.x/trunk/testing/itest/ws/pom.xml
+++ b/sca-java-2.x/trunk/testing/itest/ws/pom.xml
@@ -52,6 +52,7 @@
<module>contribution-callback-forwardspec</module>
<module>contribution-callback-fullspec</module>
<module>contribution-callback-promotion</module>
+ <module>contribution-callback-wsdl-iface</module>
<module>contribution-doc-lit</module>
<module>contribution-doc-lit-wrapped</module>
<module>contribution-rpc-lit</module>