Uploaded image for project: 'Tuscany'
  1. Tuscany
  2. TUSCANY-2980

tuscany generate wsdl so insistently

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • Java-SCA-1.4
    • None
    • None

    Description

      I want to publish webservice thought tuscany,and I write wsdl file
      firstly,and I want tuscany use the wsdl file when publish webservice.But I
      found tuscany so insistently generate wsdl file.

      following is my wsdl file sample.wsdl:

      <?xml version="1.0" encoding="UTF-8"?
      <wsdl:definitions targetNamespace="http://www.wiscom.com.cn/sample"
      xmlns:tns="http://www.wiscom.com.cn/sample"
      xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
      xmlns:xs="http://www.w3.org/2001/XMLSchema"
      xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
      <wsdl:types
      <xs:schema attributeFormDefault="qualified"
      elementFormDefault="unqualified"
      targetNamespace="http://www.wiscom.com.cn/sample"
      xmlns:tns="http://www.wiscom.com.cn/sample"
      xmlns:xs="http://www.w3.org/2001/XMLSchema"
      <xs:complexType name="student"
      <xs:sequence
      <xs:element name="id" type="xs:int"/
      <xs:element minOccurs="0" name="name"
      type="xs:string"/
      <xs:element minOccurs="0" name="address"
      type="tns:address"/
      <xs:element minOccurs="0" name="bornDate"
      type="xs:dateTime"/
      <xs:element maxOccurs="unbounded" minOccurs="0"
      name="familyMembers" nillable="true"
      type="tns:familyMember"/
      <xs:element name="graduated" type="xs:boolean"/
      </xs:sequence
      </xs:complexType
      <xs:complexType name="address"
      <xs:sequence
      <xs:element minOccurs="0" name="city"
      type="xs:string"/
      <xs:element minOccurs="0" name="conntry"
      type="xs:string"/
      <xs:element minOccurs="0" name="street"
      type="xs:string"/
      </xs:sequence
      </xs:complexType
      <xs:complexType name="familyMember"
      <xs:sequence
      <xs:element name="age" type="xs:int"/
      <xs:element minOccurs="0" name="name"
      type="xs:string"/
      <xs:element minOccurs="0" name="relation"
      type="xs:string"/
      </xs:sequence
      </xs:complexType
      <xs:element name="request"
      <xs:complexType
      <xs:sequence
      <xs:element minOccurs="0" name="arg0"
      nillable="true" type="tns:student"/
      </xs:sequence
      </xs:complexType
      </xs:element
      <xs:element name="response"
      <xs:complexType
      <xs:sequence
      <xs:element minOccurs="0" name="return"
      nillable="true" type="tns:student"/
      </xs:sequence
      </xs:complexType
      </xs:element
      </xs:schema
      </wsdl:types
      <wsdl:message name="requestMsg"
      <wsdl:part name="parameter" element="tns:request"/
      </wsdl:message
      <wsdl:message name="responseMsg"
      <wsdl:part name="parameter" element="tns:response"/
      </wsdl:message
      <wsdl:portType name="sampleInterface"
      <wsdl:operation name="process"
      <wsdl:input message="tns:requestMsg"/
      <wsdl:output message="tns:responseMsg"/
      </wsdl:operation
      </wsdl:portType
      <wsdl:binding name="sampleBinding" type="tns:sampleInterface"
      <soap:binding style="document" transport="
      http://schemas.xmlsoap.org/soap/http"/<http://schemas.xmlsoap.org/soap/http%22/

      <wsdl:operation name="process"
      <soap:operation/
      <wsdl:input
      <soap:body use="literal"/
      </wsdl:input
      <wsdl:output
      <soap:body use="literal"/
      </wsdl:output
      </wsdl:operation
      </wsdl:binding
      <wsdl:service name="sampleService"
      <wsdl:port name="sampleEndpoint" binding="tns:sampleBinding"
      <soap:address location="
      http://127.0.0.1:8080/bs/sampleService"/<http://127.0.0.1:8080/bs/sampleService%22/

      </wsdl:port
      </wsdl:service
      </wsdl:definitions

      and following is composite file:

      <composite xmlns="http://www.osoa.org/xmlns/sca/1.0"
      targetNamespace="http://wiscom"
      xmlns:wiscom="http://wiscom"
      xmlns:dbsdo="
      http://tuscany.apache.org/xmlns/sca/databinding/sdo/1.0"
      xmlns:wsdli="http://www.w3.org/2004/08/wsdl-instance"
      name="baseinfo"
      <dbsdo:import.sdo location="wsdl/sample.wsdl"/
      <component name="baseInfoServiceComponent"
      <implementation.java
      class="com.wiscom.tuscany.demo.baseinfo.BaseInfoServiceImpl"/
      <service name="BaseInfoService"
      <interface.java interface="com.wiscom.tuscany.demo.baseinfo.BaseInfoService"/>

      <binding.ws wsdlElement="http://www.wiscom.com.cn/sample#wsdl.port(sampleService/sampleEndpoint)"/>

      </service>
      </component>
      </composite>

      and when application startup,I access
      http://127.0.0.1:8080/bs/sampleService?wsdl, I get the following:

      <?xml version="1.0" encoding="UTF-8"?
      <wsdl:definitions name="baseInfoServiceComponent.BaseInfoService"
      targetNamespace="
      http://www.wiscom.com.cn/baseInfoServiceComponent/BaseInfoService"
      xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="
      http://www.wiscom.com.cn/baseInfoServiceComponent/BaseInfoService"
      xmlns:ns0="http://www.wiscom.com.cn/sample" xmlns:SOAP11="
      http://schemas.xmlsoap.org/wsdl/soap/"
      <wsdl:import namespace="http://www.wiscom.com.cn/sample" location=
      "/bs/sampleService?wsdl=wsdl/sample.wsdl"
      </wsdl:import
      <wsdl:service name="sampleInterfaceService"
      <wsdl:port name="sampleEndpoint" binding="ns0:sampleBinding"
      <SOAP11:address location="http://192.168.1.112:8080/bs/sampleService
      "/
      </wsdl:port
      </wsdl:service
      </wsdl:definitions

      Tuscany generate new wsdl file and new namespace,not using the sample.wsdl
      directly.how to do letting tuscany use sample.wsdl directly?

      Attachments

        Activity

          People

            Unassigned Unassigned
            likebean L.J.W
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: