版本化wsdl合同

时间:2012-12-05 11:55:10

标签: web-services

任何人都可以告诉我版本Wsdl合约(wsdl第一服务)的主要版本和次要版本。任何正在运行的示例将非常有帮助。

我跟随我的wsdl版本的方式就是这个。我正在关注Iona webservices版本指南

 <?xml version="1.0" encoding="UTF-8"?>
   <wsdl:definitions name="ProductServiceImplServicev2"
   targetNamespace="http://service.dtechtalkcenter.com/servicev2"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" 
   xmlns:tns="http://service.dtechtalkcenter.com/servicev2"
   xmlns:xsd="http://www.w3.org/2001/XMLSchema" `enter code here`
   xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" 
   xmlns:v2_0="http://service.dtechtalkcenter.com/servicev2.0"
   xmlns:v2_1="http://service.dtechtalkcenter.com/servicev2.1">
  <wsdl:types>
    <xsd:schema elementFormDefault="unqualified" targetNamespace="http://service.dtechtalkcenter.com/servicev2.0">
    <xsd:element name="addProduct" type="v2_0:addProduct"/>
   <xsd:element name="addProductResponse" type="v2_0:addProductResponse"/>
    <xsd:element name="getProducts" type="v2_0:getProducts"/>
    <xsd:element name="getProductsResponse" type="v2_0:getProductsResponse"/>
    <xsd:complexType name="getProducts">
    <xsd:sequence/>
    </xsd:complexType>
    <xsd:complexType name="getProductsResponse">
    <xsd:sequence>
      <xsd:element maxOccurs="unbounded" minOccurs="0" name="return" type="v2_0:product"/>
    </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="product">
    <xsd:sequence>
      <xsd:element name="cast" type="xsd:double"/>
      <xsd:element minOccurs="0" name="productCategory" type="xsd:string"/>
      <xsd:element minOccurs="0" name="productDetails" type="xsd:string"/>
    </xsd:sequence>
     </xsd:complexType>
    <xsd:complexType name="addProduct">
    <xsd:sequence>
      <xsd:element minOccurs="0" name="product" type="v2_0:product"/>
    </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="addProductResponse">
    <xsd:sequence/>
    </xsd:complexType>


    </xsd:schema>
    </wsdl:types>
    <wsdl:message name="addProductResponse">
    <wsdl:part name="parameters" element="v2_0:addProductResponse">
     </wsdl:part>
    </wsdl:message>
   <wsdl:message name="getProducts">
    <wsdl:part name="parameters" element="v2_0:getProducts">
    </wsdl:part>
    </wsdl:message>
    <wsdl:message name="addProduct">
    <wsdl:part name="parameters" element="v2_0:addProduct">
    </wsdl:part>
    </wsdl:message>
    <wsdl:message name="getProductsResponse">
    <wsdl:part name="parameters" element="v2_0:getProductsResponse">
    </wsdl:part>
    </wsdl:message>
    <wsdl:portType name="ProductService_v2_0">
    <wsdl:operation name="getProducts">
      <wsdl:input name="getProducts" message="tns:getProducts">
    </wsdl:input>
      <wsdl:output name="getProductsResponse" message="tns:getProductsResponse">
    </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="addProduct">
      <wsdl:input name="addProduct" message="tns:addProduct">
    </wsdl:input>
      <wsdl:output name="addProductResponse" message="tns:addProductResponse">
    </wsdl:output>
    </wsdl:operation>
     </wsdl:portType>
    <wsdl:binding name="ProductServiceImplService_v2_0_SoapBinding" type="tns:ProductService_v2_0">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <wsdl:operation name="getProducts">
      <soap:operation soapAction="" style="document"/>
      <wsdl:input name="getProducts">
        <soap:body use="literal"/>
      </wsdl:input>
      <wsdl:output name="getProductsResponse">
        <soap:body use="literal"/>
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="addProduct">
      <soap:operation soapAction="" style="document"/>
      <wsdl:input name="addProduct">
        <soap:body use="literal"/>
      </wsdl:input>
      <wsdl:output name="addProductResponse">
        <soap:body use="literal"/>
      </wsdl:output>
    </wsdl:operation>
    </wsdl:binding>
    <wsdl:service name="ProductServiceImplService_v2_0">
    <wsdl:port name="ProductServiceImplPort" binding="tns:ProductServiceImplService_v2_0_SoapBinding">
      <soap:address location="http://localhost:8088/VersionService/services/ProductServiceImplPort"/>
     </wsdl:port>
    </wsdl:service>
  </wsdl:definitions>

0 个答案:

没有答案