Partner of BPEL

Source: Internet
Author: User

One, Partner link type (Partner link Types)

1. Interactive process

The interaction process between partners is divided into two typical situations:

    • The process calls the partner after the synchronization waits for the result to be returned. This is usually the case when a partner can return the results quickly, and the process does not have to wait long.
    • The process call partner asynchronously waits for the result to be returned. This is usually the case when a partner takes a long time to return a result, and the process does not have to wait for it to continue. When the partner finishes executing, it will callback the process interface and inform the process to return the results.

1. Use

A partner link type defines a relationship that is dependent on an interaction.

  

<Plnk:partnerlinktypename= "NCName">    <Plink:rolename= "NCName"PortType= "QName" />    <Plink:rolename= "NCName"PortType= "QName" />    </plnk:partnerlinktype name= "NCName">

The name of the partner link type is specified by the Name property. Roles are used to describe the role played by participants in an interaction. The definition of a role refers to the interface definition defined in the WSDL in addition to the name. Any service that participates in this interaction and acts as the role must implement this interface. The following two scenarios illustrate:

    • But the role partner link type. This means that there is only one role in the interaction, and that only the interacting party implements the interface referenced in the role, and there is no restriction on the other side of the interaction.
 <  plnk:partnetlinktype  namee  = "Orderprocessplt"  >  Span style= "color: #0000ff;" ><  plnk:role  name  = "Orderprocessrole"  >  <  Span style= "color: #800000;" >plnk:porttype  name   />  </ plnk:role  >  </ plnk:partnetlinktype  >  

This partner link type only defines a role orderprocessrole, the interface that implements the role must implement the Orderprocess interface, there is no restriction on the other side of the interaction, any service can participate in this interaction, Invokes the service provided by Orderprocessrole.

    • The two-Role partner link type. There are two roles involved in the interaction. Both parties to the interaction must implement the appropriate role interface to complete the interaction correctly.
<Plnk:partnerlnktypename= "Shippartnerplt">  <Plnk:rolename= "Shipservicerequester">      <Plnk:porttypename= "Ns1:shipservicecallback" />   </Plnk:role>  <Plnk:rolename= "Shipserviceprovider">      <Plnk:porttypename= "Ns1:shipproduct" />   </Plnk:role></Plnk:partnerlnktype>

This partner link defines two roles, Shipservicerequester and shipserviceprovider, so both parties involved in the interaction must implement the interface of their respective roles. For example, an order processing process invokes the Shipproduct interface of the delivery service to initiate the delivery service, and the shipservicecallback of the order processing process is called to return the confirmation information after the delivery is complete.

3. Partner links (Partner links)

A partner link can be seen as an instance of a partner link type.

 <  partnetlinks  >  <  partnetlink  name  = "NCName"   Partnetlinktype  = "QName"   Myrole  = "NCName"   Partnetrole  = "NCName"   Initializepartnetrole  = "Yes|no"  />  </ partnetlinks  >  

Defining a partner link needs to indicate which type of partner link it is, and what role it will play. MYROLE specifies the role of the caller in the interaction, while partnerrole indicates the role of the partner. The value of Initializepartnetrole indicates whether the BPEL engine initializes its endpoint references the first time the service specified by Partnetrole is called.

For example:

< partnerlinks >  <  name= "Callshipservicepartnerlink"  partnerlinktype= "SHIPPARTNERPLT" Myrole = "Shipservicerequester" Partnerrole = "Shipserviceprovider" /> </ partnerlinks >

This partner link definition indicates that it is the caller of the delivery service and that it implements the Shipservicecallback interface for the delivery service callback.

Partner of BPEL

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.