You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuscany.apache.org by sl...@apache.org on 2008/05/30 13:20:18 UTC
svn commit: r661651 - in /incubator/tuscany/java/sca:
itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/
itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/
itest/validation/src/main/resources/interfacewsd...
Author: slaws
Date: Fri May 30 04:20:17 2008
New Revision: 661651
URL: http://svn.apache.org/viewvc?rev=661651&view=rev
Log:
TUSCANY-2319 - fix NPE in binding.ws and add validation itests. Thanks for the patch Ram.
Added:
incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/
incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl (with props)
incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworldwsjms.composite (with props)
incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/
incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl (with props)
incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworldwsjms.composite (with props)
incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/
incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl (with props)
incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworldwsjms.composite (with props)
incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java (with props)
incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java (with props)
incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java (with props)
Modified:
incubator/tuscany/java/sca/modules/binding-ws-xml/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java
incubator/tuscany/java/sca/modules/binding-ws-xml/src/main/resources/binding-wsxml-validation-messages.properties
incubator/tuscany/java/sca/modules/interface-wsdl-xml/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/xml/WSDLInterfaceProcessor.java
incubator/tuscany/java/sca/modules/interface-wsdl-xml/src/main/resources/interface-wsdlxml-validation-messages.properties
Added: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl?rev=661651&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl (added)
+++ incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl Fri May 30 04:20:17 2008
@@ -0,0 +1,92 @@
+<?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.
+-->
+<wsdl:definitions targetNamespace="http://helloworld" xmlns:tns="http://helloworld" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ name="helloworld">
+
+ <wsdl:types>
+ <schema elementFormDefault="qualified" targetNamespace="http://helloworld" xmlns="http://www.w3.org/2001/XMLSchema">
+
+ <element name="getGreetings">
+ <complexType>
+ <sequence>
+ <element name="name" type="xsd:string"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="getGreetingsResponse">
+ <complexType>
+ <sequence>
+ <element name="getGreetingsReturn" type="xsd:string"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ </schema>
+ </wsdl:types>
+
+ <wsdl:message name="getGreetingsRequest">
+ <wsdl:part element="tns:getGreetings" name="parameters"/>
+ </wsdl:message>
+
+ <wsdl:message name="getGreetingsResponse">
+ <wsdl:part element="tns:getGreetingsResponse" name="parameters"/>
+ </wsdl:message>
+
+ <wsdl:portType name="HelloWorld">
+ <wsdl:operation name="getGreetings">
+ <wsdl:input message="tns:getGreetingsRequest" name="getGreetingsRequest"/>
+ <wsdl:output message="tns:getGreetingsResponse" name="getGreetingsResponse"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="HelloWorldSoapBinding" type="tns:HelloWorld">
+ <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="getGreetings">
+ <wsdlsoap:operation soapAction=""/>
+ <wsdl:input name="getGreetingsRequest">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getGreetingsResponse">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:binding name="HelloWorldSoapJmsBinding" type="tns:HelloWorld">
+ <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/jms"/>
+ <wsdl:operation name="getGreetings">
+ <wsdlsoap:operation soapAction=""/>
+ <wsdl:input name="getGreetingsRequest">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getGreetingsResponse">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:service name="HelloWorldService">
+ <wsdl:port binding="tns:HelloWorldSoapJmsBinding" name="HelloWorldSoapJmsPort">
+ <wsdlsoap:address location="jms:/queue.sample?transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory&java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory&java.naming.provider.url=tcp://localhost:61619"/>
+ </wsdl:port>
+ </wsdl:service>
+
+</wsdl:definitions>
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworldwsjms.composite
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworldwsjms.composite?rev=661651&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworldwsjms.composite (added)
+++ incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworldwsjms.composite Fri May 30 04:20:17 2008
@@ -0,0 +1,34 @@
+<?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://www.osoa.org/xmlns/sca/1.0"
+ targetNamespace="http://helloworld"
+ xmlns:hw="http://helloworld"
+ name="helloworldws">
+
+ <component name="HelloWorldServiceComponent">
+ <implementation.java class="binding.jms.HelloWorldServiceImpl" />
+ <service name="HelloWorldService">
+ <interface.wsdl interface="http://helloworld#wsdl.interface(HelloWorld)" />
+ <binding.ws wsdlElement="http://helloworld#wsdl.binding(HelloWorldSoapJmsBinding2)"
+ uri="jms:/queue.sample?transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory&java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory&java.naming.provider.url=tcp://localhost:61619"/>
+ </service>
+ </component>
+
+</composite>
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworldwsjms.composite
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworldwsjms.composite
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworldwsjms.composite
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl?rev=661651&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl (added)
+++ incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl Fri May 30 04:20:17 2008
@@ -0,0 +1,92 @@
+<?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.
+-->
+<wsdl:definitions targetNamespace="http://helloworld" xmlns:tns="http://helloworld" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ name="helloworld">
+
+ <wsdl:types>
+ <schema elementFormDefault="qualified" targetNamespace="http://helloworld" xmlns="http://www.w3.org/2001/XMLSchema">
+
+ <element name="getGreetings">
+ <complexType>
+ <sequence>
+ <element name="name" type="xsd:string"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="getGreetingsResponse">
+ <complexType>
+ <sequence>
+ <element name="getGreetingsReturn" type="xsd:string"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ </schema>
+ </wsdl:types>
+
+ <wsdl:message name="getGreetingsRequest">
+ <wsdl:part element="tns:getGreetings" name="parameters"/>
+ </wsdl:message>
+
+ <wsdl:message name="getGreetingsResponse">
+ <wsdl:part element="tns:getGreetingsResponse" name="parameters"/>
+ </wsdl:message>
+
+ <wsdl:portType name="HelloWorld">
+ <wsdl:operation name="getGreetings">
+ <wsdl:input message="tns:getGreetingsRequest" name="getGreetingsRequest"/>
+ <wsdl:output message="tns:getGreetingsResponse" name="getGreetingsResponse"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="HelloWorldSoapBinding" type="tns:HelloWorld">
+ <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="getGreetings">
+ <wsdlsoap:operation soapAction=""/>
+ <wsdl:input name="getGreetingsRequest">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getGreetingsResponse">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:binding name="HelloWorldSoapJmsBinding" type="tns:HelloWorld">
+ <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/jms"/>
+ <wsdl:operation name="getGreetings">
+ <wsdlsoap:operation soapAction=""/>
+ <wsdl:input name="getGreetingsRequest">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getGreetingsResponse">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:service name="HelloWorldService">
+ <wsdl:port binding="tns:HelloWorldSoapJmsBinding" name="HelloWorldSoapJmsPort">
+ <wsdlsoap:address location="jms:/queue.sample?transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory&java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory&java.naming.provider.url=tcp://localhost:61619"/>
+ </wsdl:port>
+ </wsdl:service>
+
+</wsdl:definitions>
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworldwsjms.composite
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworldwsjms.composite?rev=661651&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworldwsjms.composite (added)
+++ incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworldwsjms.composite Fri May 30 04:20:17 2008
@@ -0,0 +1,34 @@
+<?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://www.osoa.org/xmlns/sca/1.0"
+ targetNamespace="http://helloworld"
+ xmlns:hw="http://helloworld"
+ name="helloworldws">
+
+ <component name="HelloWorldServiceComponent">
+ <implementation.java class="binding.jms.HelloWorldServiceImpl" />
+ <service name="HelloWorldService">
+ <interface.wsdl interface="http://helloworld#wsdl.interface(HelloWorld)" />
+ <binding.ws wsdlElement="http://helloworld#wsdl.service(HelloWorldService2)"
+ uri="jms:/queue.sample?transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory&java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory&java.naming.provider.url=tcp://localhost:61619"/>
+ </service>
+ </component>
+
+</composite>
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworldwsjms.composite
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworldwsjms.composite
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworldwsjms.composite
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl?rev=661651&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl (added)
+++ incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl Fri May 30 04:20:17 2008
@@ -0,0 +1,92 @@
+<?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.
+-->
+<wsdl:definitions targetNamespace="http://helloworld" xmlns:tns="http://helloworld" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ name="helloworld">
+
+ <wsdl:types>
+ <schema elementFormDefault="qualified" targetNamespace="http://helloworld" xmlns="http://www.w3.org/2001/XMLSchema">
+
+ <element name="getGreetings">
+ <complexType>
+ <sequence>
+ <element name="name" type="xsd:string"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ <element name="getGreetingsResponse">
+ <complexType>
+ <sequence>
+ <element name="getGreetingsReturn" type="xsd:string"/>
+ </sequence>
+ </complexType>
+ </element>
+
+ </schema>
+ </wsdl:types>
+
+ <wsdl:message name="getGreetingsRequest">
+ <wsdl:part element="tns:getGreetings" name="parameters"/>
+ </wsdl:message>
+
+ <wsdl:message name="getGreetingsResponse">
+ <wsdl:part element="tns:getGreetingsResponse" name="parameters"/>
+ </wsdl:message>
+
+ <wsdl:portType name="HelloWorld">
+ <wsdl:operation name="getGreetings">
+ <wsdl:input message="tns:getGreetingsRequest" name="getGreetingsRequest"/>
+ <wsdl:output message="tns:getGreetingsResponse" name="getGreetingsResponse"/>
+ </wsdl:operation>
+ </wsdl:portType>
+
+ <wsdl:binding name="HelloWorldSoapBinding" type="tns:HelloWorld">
+ <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="getGreetings">
+ <wsdlsoap:operation soapAction=""/>
+ <wsdl:input name="getGreetingsRequest">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getGreetingsResponse">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:binding name="HelloWorldSoapJmsBinding" type="tns:HelloWorld">
+ <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/jms"/>
+ <wsdl:operation name="getGreetings">
+ <wsdlsoap:operation soapAction=""/>
+ <wsdl:input name="getGreetingsRequest">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="getGreetingsResponse">
+ <wsdlsoap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+
+ <wsdl:service name="HelloWorldService">
+ <wsdl:port binding="tns:HelloWorldSoapJmsBinding" name="HelloWorldSoapJmsPort">
+ <wsdlsoap:address location="jms:/queue.sample?transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory&java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory&java.naming.provider.url=tcp://localhost:61619"/>
+ </wsdl:port>
+ </wsdl:service>
+
+</wsdl:definitions>
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworldwsjms.composite
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworldwsjms.composite?rev=661651&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworldwsjms.composite (added)
+++ incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworldwsjms.composite Fri May 30 04:20:17 2008
@@ -0,0 +1,34 @@
+<?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://www.osoa.org/xmlns/sca/1.0"
+ targetNamespace="http://helloworld"
+ xmlns:hw="http://helloworld"
+ name="helloworldws">
+
+ <component name="HelloWorldServiceComponent">
+ <implementation.java class="binding.jms.HelloWorldServiceImpl" />
+ <service name="HelloWorldService">
+ <interface.wsdl interface="http://helloworld#wsdl.interface(HelloWorld2)" />
+ <binding.ws wsdlElement="http://helloworld#wsdl.binding(HelloWorldSoapJmsBinding)"
+ uri="jms:/queue.sample?transport.jms.ConnectionFactoryJNDIName=QueueConnectionFactory&java.naming.factory.initial=org.apache.activemq.jndi.ActiveMQInitialContextFactory&java.naming.provider.url=tcp://localhost:61619"/>
+ </service>
+ </component>
+
+</composite>
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworldwsjms.composite
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworldwsjms.composite
------------------------------------------------------------------------------
svn:keywords = Rev Date
Propchange: incubator/tuscany/java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworldwsjms.composite
------------------------------------------------------------------------------
svn:mime-type = text/xml
Added: incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java?rev=661651&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java Fri May 30 04:20:17 2008
@@ -0,0 +1,60 @@
+/*
+ * 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 binding.wsxml;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class WsdlBindingDoesNotMatchTestCase extends TestCase {
+
+ private CustomCompositeBuilder customDomain;
+
+ @Override
+ protected void setUp() throws Exception
+ {
+ customDomain = CustomCompositeBuilder.getInstance();
+ try {
+ customDomain.loadContribution("src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworldwsjms.composite",
+ "TestContribution", "src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/");
+ } catch (Exception ex){
+ //throw ex;
+ }
+ }
+
+ @Override
+ protected void tearDown() throws Exception {
+ //node.stop();
+ }
+
+ public void testCalculator() {
+ Monitor monitor = customDomain.getMonitorInstance();
+ Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+
+ assertNotNull(problem);
+ assertEquals("WsdlBindingDoesNotMatch", problem.getMessageId());
+
+ }
+}
Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added: incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java?rev=661651&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java Fri May 30 04:20:17 2008
@@ -0,0 +1,60 @@
+/*
+ * 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 binding.wsxml;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class WsdlServiceDoesNotMatchTestCase extends TestCase {
+
+ private CustomCompositeBuilder customDomain;
+
+ @Override
+ protected void setUp() throws Exception
+ {
+ customDomain = CustomCompositeBuilder.getInstance();
+ try {
+ customDomain.loadContribution("src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworldwsjms.composite",
+ "TestContribution", "src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/");
+ } catch (Exception ex){
+ //throw ex;
+ }
+ }
+
+ @Override
+ protected void tearDown() throws Exception {
+ //node.stop();
+ }
+
+ public void testCalculator() {
+ Monitor monitor = customDomain.getMonitorInstance();
+ Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+
+ assertNotNull(problem);
+ assertEquals("WsdlServiceDoesNotMatch", problem.getMessageId());
+
+ }
+}
Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java?rev=661651&view=auto
==============================================================================
--- incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java (added)
+++ incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java Fri May 30 04:20:17 2008
@@ -0,0 +1,58 @@
+/*
+ * 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 interfacewsdl.xml;
+
+import junit.framework.TestCase;
+import org.apache.tuscany.sca.monitor.Monitor;
+import org.apache.tuscany.sca.monitor.Problem;
+import org.apache.tuscany.sca.monitor.impl.DefaultLoggingMonitorImpl;
+import domain.CustomCompositeBuilder;
+
+/**
+ * This shows how to test the Calculator service component.
+ */
+public class WsdlInterfaceDoesNotMatchTestCase extends TestCase {
+
+ private CustomCompositeBuilder customDomain;
+
+ @Override
+ protected void setUp() throws Exception
+ {
+ customDomain = CustomCompositeBuilder.getInstance();
+ try {
+ customDomain.loadContribution("src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworldwsjms.composite",
+ "TestContribution", "src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/");
+ } catch (Exception ex){
+ //throw ex;
+ }
+ }
+
+ @Override
+ protected void tearDown() throws Exception {
+ //node.stop();
+ }
+
+ public void testCalculator() {
+ Monitor monitor = customDomain.getMonitorInstance();
+ Problem problem = ((DefaultLoggingMonitorImpl)monitor).getLastLoggedProblem();
+
+ assertNotNull(problem);
+ assertEquals("WsdlInterfaceDoesNotMatch", problem.getMessageId());
+ }
+}
Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/java/sca/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Modified: incubator/tuscany/java/sca/modules/binding-ws-xml/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-ws-xml/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java?rev=661651&r1=661650&r2=661651&view=diff
==============================================================================
--- incubator/tuscany/java/sca/modules/binding-ws-xml/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java (original)
+++ incubator/tuscany/java/sca/modules/binding-ws-xml/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java Fri May 30 04:20:17 2008
@@ -324,6 +324,8 @@
if (binding != null) {
wsdlDefinition.setDefinition(binding.getDefinition());
model.setBinding(binding.getElement());
+ } else {
+ warning("WsdlBindingDoesNotMatch", wsdlDefinition, model.getBindingName());
}
}
if (model.getServiceName() != null) {
@@ -336,6 +338,8 @@
model.setPort(port);
model.setBinding(port.getBinding());
}
+ } else {
+ warning("WsdlServiceDoesNotMatch", wsdlDefinition, model.getServiceName());
}
}
@@ -346,8 +350,7 @@
try {
wsdlInterface = wsdlFactory.createWSDLInterface(portType, wsdlDefinition, resolver);
} catch (InvalidInterfaceException e) {
- warning("InvalidInterfaceException", wsdlFactory, model.getName());
- logger.log(Level.WARNING, "Exception creating interface from WSDL for binding: " + model.getName(), e);
+ warning("InvalidInterfaceException", wsdlFactory, model.getName());
}
interfaceContract.setInterface(wsdlInterface);
model.setBindingInterfaceContract(interfaceContract);
Modified: incubator/tuscany/java/sca/modules/binding-ws-xml/src/main/resources/binding-wsxml-validation-messages.properties
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/binding-ws-xml/src/main/resources/binding-wsxml-validation-messages.properties?rev=661651&r1=661650&r2=661651&view=diff
==============================================================================
--- incubator/tuscany/java/sca/modules/binding-ws-xml/src/main/resources/binding-wsxml-validation-messages.properties (original)
+++ incubator/tuscany/java/sca/modules/binding-ws-xml/src/main/resources/binding-wsxml-validation-messages.properties Fri May 30 04:20:17 2008
@@ -21,4 +21,6 @@
InvalidWsdlElementAttr = Invalid WebService binding wsdlElement attribute: {0}
MustUseWsdlBinding = {0} must use wsdl.binding when using wsa:EndpointReference
InvalidInterfaceException = Exception creating interface from WSDL for binding: {0}
+WsdlBindingDoesNotMatch = The #wsdl.binding({0}) does not match with the WSDL Definitions
+WsdlServiceDoesNotMatch = The #wsdl.service({0}) does not match with the WSDL Definitions
Modified: incubator/tuscany/java/sca/modules/interface-wsdl-xml/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/xml/WSDLInterfaceProcessor.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/interface-wsdl-xml/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/xml/WSDLInterfaceProcessor.java?rev=661651&r1=661650&r2=661651&view=diff
==============================================================================
--- incubator/tuscany/java/sca/modules/interface-wsdl-xml/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/xml/WSDLInterfaceProcessor.java (original)
+++ incubator/tuscany/java/sca/modules/interface-wsdl-xml/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/xml/WSDLInterfaceProcessor.java Fri May 30 04:20:17 2008
@@ -60,6 +60,20 @@
}
/**
+ * Report a warning.
+ *
+ * @param problems
+ * @param message
+ * @param model
+ */
+ private void warning(String message, Object model, Object... messageParameters) {
+ if (monitor != null) {
+ Problem problem = new ProblemImpl(this.getClass().getName(), "interface-wsdlxml-validation-messages", Severity.WARNING, model, message, (Object[])messageParameters);
+ monitor.problem(problem);
+ }
+ }
+
+ /**
* Report a error.
*
* @param problems
@@ -188,8 +202,7 @@
wsdlDefinition.getXmlSchemas().addAll(resolved.getXmlSchemas());
wsdlDefinition.setUnresolved(false);
WSDLObject<PortType> portType = wsdlDefinition.getWSDLObject(PortType.class, wsdlInterface.getName());
- if (portType != null) {
-
+ if (portType != null) {
// Introspect the WSDL portType and add the resulting
// WSDLInterface to the resolver
try {
@@ -203,6 +216,9 @@
}
resolver.addModel(wsdlInterface);
}
+ else {
+ warning("WsdlInterfaceDoesNotMatch", wsdlDefinition, wsdlInterface.getName());
+ }
}
}
}
Modified: incubator/tuscany/java/sca/modules/interface-wsdl-xml/src/main/resources/interface-wsdlxml-validation-messages.properties
URL: http://svn.apache.org/viewvc/incubator/tuscany/java/sca/modules/interface-wsdl-xml/src/main/resources/interface-wsdlxml-validation-messages.properties?rev=661651&r1=661650&r2=661651&view=diff
==============================================================================
--- incubator/tuscany/java/sca/modules/interface-wsdl-xml/src/main/resources/interface-wsdlxml-validation-messages.properties (original)
+++ incubator/tuscany/java/sca/modules/interface-wsdl-xml/src/main/resources/interface-wsdlxml-validation-messages.properties Fri May 30 04:20:17 2008
@@ -20,4 +20,5 @@
#
ContributionReadException = ContributionReadException occured due to :
ContributionResolveException = ContributionResolveException occured due to :
-InvalidWSDLInterfaceAttr = Invalid WSDL interface attribute: {0}
\ No newline at end of file
+InvalidWSDLInterfaceAttr = Invalid WSDL interface attribute: {0}
+WsdlInterfaceDoesNotMatch = The #wsdl.interface({0}) specified does not match with WSDL Definitions
\ No newline at end of file