Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved


Chapter 7 Services and Partners : Partners

Partners
Services that an orchestration process invokes are represented by partners. Partners are defined by a name and a WSDL portType that describes the operations that can be invoked. The Invoke activity is used within an orchestration process to invoke an operation on a partner service.
Services, in turn, can also be called by other services. Therefore orchestration processes declare input partners that describe the various portTypes that are implemented within the orchestration process.
The orchestration process has an Input Partners tab and a Partners tab that allows you to define the partners of the service.
To describe partners and how they are used within orchestration processes, Figure 32 illustrates an online loan application orchestration process.
Figure 32 Online loan application process
In this example, loan requests are received and processed, and applicants can also request the status of the loan while it is still being processed. This process implements the ApplyForLoan and GetLoanApplicationStatus operations of the Loan portType in the following incomplete abstract WSDL:
 
<?xml version="1.0" encoding="UTF-8"?>
...
<portType name="Loan">
<operation name="ApplyForLoan"/>
<operation name="GetLoanApplicationStatus"/>
</portType>
</definitions>
This orchestration process also invokes a partner service for validating the applicant’s address and social security number. The following partial WSDL file describes the Validate portType of the partner service.
 
<?xml version="1.0" encoding="UTF-8"?>
...
<portType name="Validate">
<operation name="isValidAddress"/>
<operation name="isValidSSN"/>
</portType>
...
 
</definitions>
The following sections describe how to configure input partners and partners for orchestration processes.
Input Partners
The Input Partners tab of an orchestration service allows you to specify the various portTypes that are implemented within the orchestration process. Each portType can contain one or more operation, and the orchestration process can then include activities that receive messages for operations.
Consider the online loan application orchestration process example in Figure 32. The orchestration process implements both the ApplyForLoan and GetLoanApplicationStatus operations of the Loan portType. Therefore, the orchestration process has one input partner (the Loan portType). Figure 33 illustrates the configuration of the Input Partners tab of this orchestration process.
Figure 33 Input partner configuration
To configure input partners:
1.
Use the + and X buttons to add or delete partners in the table in the Input Partners field. Move the input partners up or down the list using the arrow buttons.
2.
3.
Select an input partner, then use the Browse button in the PortType field to locate the appropriate WSDL containing the portType for the input partner.
4.
Invoked Partners
Orchestration processes can invoke partner services. Partner services can be located either inside the same project as the orchestration process that invokes the service, or the partner can be an external partner service invoked over the internet by way of the SOAP protocol.
Partner Link Configuration resources associate partner services with their actual endpoints. Partner Link Configuration resources can contain one or more local or external partner services. You use the named partner links within a Partner Link Configuration either within an orchestration process or in the Partner Binding tab of a Service resource.
The general process for configuring partners is the following:
1.
2.
Define a partner on the Partner tab of the orchestration process that invokes the partner. The orchestration process requires the port type of the partner.
3.
4.
a.
b.
Specify the Partner Link Configuration resource containing the partner’s endpoint on the Partner Binding tab of the Service that uses the orchestration process as an implementation of its operations.
The following sections describe creating Partner Link Configuration resources and using these resources within orchestration processes or services.
Partner Link Configuration
Partner Link Configuration resources bind a partner service to its specific port. Bindings can be changed without affecting the underlying orchestration process or service so that you can switch to new partners services with the same portType. Figure 34 illustrates the Partner Link Configuration resource.
Figure 34 Partner Link Configuration resource
To create a partner link configuration resource:
1.
2.
Click the + button to add a new partner. If necessary, use the X button to delete partners or the arrow buttons to move partners up or down the list.
3.
In the Select a Service Endpoint dialog, select a valid endpoint. For WSDL files, valid endpoints are configured ports within the WSDL file. For services within the project, only endpoints configured to use LOCAL as the transport can be specified. If you wish to invoke a local service over SOAP, use a concrete WSDL that exposes the service by way of SOAP.
If necessary, you can later change an endpoint for the specified partner by double clicking on the Service Endpoint column of the partner and selecting a new endpoint.
4.
The partner appears in the table in the Partner field. Specify a name for the partner in the Name field. Specify a timeout (in seconds) for the amount of time you wish to allow for invokes to wait while a service responds. Zero indicates an unlimited amount of time.
Remote partners accessed through SOAP can be further configured, if required. See Partner Link Configuration for more information about these fields. Local partners whose services are located within the same project require no additional configuration.
5.
When a new partner is defined against a concrete binding, the URL specified in the concrete binding is set as default. You can modify this URL or set it to a global variable which can be configured at deployment time.
Associating a Security Policy
You can associate a security policy with a service endpoint operation defined for a Partner Link in the Partner Link Configuration resource. The association between the security policy and the service endpoint operation is unique.
Using the service endpoint operation as the security subject ensures consistency with security policy associations based on the service resource. Service resource also exposes the service endpoint operation as the security subject. Exposing partner links as security policy subjects ensures WS-Security support for all the TIBCO ActiveMatrix BusinessWorks and TIBCO ActiveMatrix BusinessWorks BPEL Extension constructs that use partner links for outbound invocations. The TIBCO ActiveMatrix BusinessWorks BPEL Extension Invoke activity and TIBCO ActiveMatrix BusinessWorks Invoke Partner activity have full WS-Security functionality if they are bound using SOAP protocol.
When a security policy is associated with a particular partner link service endpoint operation, the WS-Security processing is enabled and performed according to the WS-Security guidelines for the outbound, inbound, and inbound fault message exchange specified in the Security Policy Association resource.
Security policies in TIBCO ActiveMatrix BusinessWorks BPEL Extension are associated in exactly the same way as in TIBCO ActiveMatrix BusinessWorks. For more information on how to associate a security policy, refer to the TIBCO ActiveMatrix BusinessWorks documentation.
Configuring Partners Within An Orchestration Process
Orchestration processes must define the partner services that are invoked within the process. The Partners tab of the Orchestration Process resource is used to define partners for the orchestration process. Figure 35 illustrates the Partner tab of an orchestration process.
Figure 35 Partner tab on an Orchestration Process resource
To configure a partner service:
1.
Use the + and X buttons to add or delete partners in the table in the Partners field. Move the partners up or down the list using the arrow buttons.
2.
3.
Select a partner, then use the Browse button in the PortType field to locate the appropriate WSDL containing the portType for the partner.
4.
5.
Optionally, you can use the Browse button in the Partner Link field to specify the Partner Link Configuration resource that contains the partner’s endpoint.
If you specify the partner link in this field, you do not need to specify the Partner Binding tab in the Service when this orchestration process is used as an operation implementation. If you do not specify the partner link here, you must specify the partner binding on the service. See Configuring Partner Bindings on a Service for more information.
Configuring Partner Bindings on a Service
You can bind partners invoked by all operations in a service on the Partner Binding tab of the Service. Only partners that require binding appear on this tab. For example, if you specified a partner link for the partner on the Partners tab of the orchestration process, the partner does not appear on this tab. Figure 36 illustrates the Partner Binding tab of a service.
Figure 36 Partner Link Configuration resource
To configure partner bindings on a service:
1.
Click the Partner Binding tab to associate the Partner Link Configuration resource with the partners required for the orchestration processes in the service. The Partner Binding tab is automatically populated with all partners configured in orchestration processes within the service.
2.
 

Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved