解决方案 »

  1.   

    WSDL如下:
    <?xml version="1.0"?>
    <definitions name="HelloWorldProcess"
            targetNamespace="www.hit.edu.cn"
            xmlns:tns="www.hit.edu.cn"
            xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
            xmlns="http://schemas.xmlsoap.org/wsdl/"
            xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
            ><!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         TYPE DEFINITION - List of types participating in this BPEL process 
         The BPEL Designer will generate default request and response types
         but you can define or import any XML Schema type and use them as part 
         of the message types.
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->    
        <types>
            <schema attributeFormDefault="unqualified" elementFormDefault="qualified" 
                    targetNamespace="www.hit.edu.cn" 
                    xmlns="http://www.w3.org/2001/XMLSchema">            <element name="HelloWorldProcessRequest">
                    <complexType>
                        <sequence>
                            <element name="input" type="string"/>
                        </sequence>
                    </complexType>
                </element>            <element name="HelloWorldProcessResponse">
                    <complexType>
                        <sequence>
                            <element name="result" type="string"/>
                        </sequence>
                    </complexType>
                </element>
            </schema>
        </types>
    <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         MESSAGE TYPE DEFINITION - Definition of the message types used as 
         part of the port type defintions
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->    
        <message name="HelloWorldProcessRequestMessage">
            <part name="payload" element="tns:HelloWorldProcessRequest"/>
        </message>
        <message name="HelloWorldProcessResponseMessage">
            <part name="payload" element="tns:HelloWorldProcessResponse"/>
        </message><!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         PORT TYPE DEFINITION - A port type groups a set of operations into
         a logical service unit.
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->        <!-- portType implemented by the HelloWorldProcess BPEL process -->
        <portType name="HelloWorldProcess">
            <operation name="process">
                <input  message="tns:HelloWorldProcessRequestMessage" />
                <output message="tns:HelloWorldProcessResponseMessage"/>
            </operation>
        </portType>   
    <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         PARTNER LINK TYPE DEFINITION
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->    
        <plnk:partnerLinkType name="HelloWorldProcess">
            <plnk:role name="HelloWorldProcessProvider" portType="tns:HelloWorldProcess"/>
        </plnk:partnerLinkType>
        <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         BINDING DEFINITION - Defines the message format and protocol details
         for a web service.
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
        <binding name="HelloWorldProcessBinding" type="tns:HelloWorldProcess">
         <soap:binding style="document"
         transport="http://schemas.xmlsoap.org/soap/http" />
         <operation name="process">
         <soap:operation
         soapAction="www.hit.edu.cn/process" />
         <input>
         <soap:body use="literal" />
         </input>
         <output>
         <soap:body use="literal" />
         </output>
         </operation>
        </binding><!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         SERVICE DEFINITION - A service groups a set of ports into
         a service unit.
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
        <service name="HelloWorldProcessService">
         <port name="HelloWorldProcessPort" binding="tns:HelloWorldProcessBinding">
         <soap:address location="http://localhost:8080/ode/processes/HelloWorld/HelloWorldProcess" />
         </port>
        </service>
    </definitions>