How to Implement Fire-and-Forget Pattern with EBS One-Way Calls Creating EBS WSDLs

Designing and Developing Enterprise Business Services 10-13

10.6 Implementing the Fire-and-Forget Message Exchange Pattern

To implement both asynchronous MEPs fire-and-forget and request-delayed response, you must create EBS WSDLs and then create one or two Mediator routing services, depending upon the MEP. Next, implement the requester and provider services, adhering to the guidelines laid out for the respective MEPs. The requesting service can be a requester ABCS BPEL process, EBF BPEL process, or a participating application. The providing service can be a provider ABCS BPEL Process, EBF BPEL process, or a participating application. This section includes the following topics: ■ Section 10.6.1, How to Implement Fire-and-Forget Pattern with EBS One-Way Calls ■ Section 10.6.2, Creating EBS WSDLs ■ Section 10.6.3, Creating Mediator Routing Services for Asynchronous Fire-and-Forget Patterns with a One-Way Call EBS ■ Section 10.6.4, Asynchronous Fire-and-Forget MEP Error Handling Using Compensatory Operations ■ Section 10.6.5, How to Invoke the Compensate Operation of EBS ■ Section 10.6.6, How to Enable Routing Rules in Compensate Operation Routing Service

10.6.1 How to Implement Fire-and-Forget Pattern with EBS One-Way Calls

The initiator for a fire-and-forget pattern is a requesting service not waiting for or expecting a response. The requesting service can be a participating application, a requester ABCS Impl, or an EBF. In each of these cases, the request payload must be an EBM request. For more information about enabling the ABCS both requester and provider, see Chapter 11, Designing Application Business Connector Services , Chapter 12, Constructing the ABCS , and Chapter 13, Completing ABCS Development . For more information about enabling the EBF, see Chapter 15, Designing and Constructing Enterprise Business Flows . To implement fire-and-forget pattern with EBS one-way calls: 1. Create EBS WSDLs. 2. Create a Mediator routing service for asynchronous fire-and-forget patterns with one-way call EBS. 3. Route the request from the requesting service to correct providing service in the routing service of the one-way call operation of the request EBS. 4. Implement error handling for logging and notification based on fault policies. Note: These steps are in addition to the regular steps required for the requesting service and the providing service. 10-14 Developers Guide for Oracle Application Integration Architecture Foundation Pack

10.6.2 Creating EBS WSDLs

For the entity EBS, use the WSDLs from the Enterprise Service Library of the Foundation Pack. For the process EBS, use the TemplateEBS.wsdl available in the Foundation Pack and create a Process EBS wsdl. ■ Service operations supporting a synchronous request-response MEP must be defined in one port type and the operation must have input, output, and fault message defined. ■ Service operations supporting a fire-and-forget MEP must be defined in one port type and the operation must have an input message. ■ Service operations supporting asynchronous request-response pattern must have two operations, one operation for sending the request message and another operation for processing the response message. Each of these two operations must have an input message alone. You should have two different portTypes, one for each operation. The service operation for processing the response message must reside in a portType having Response as the suffix. ■ The EBS WSDLs must have two portTypes: – PortType for all operations used for modeling synchronous request, response operations and request-only operations. The name must not specify Request. – PortType for asynchronous response operations. The name must specify Response. ■ Two Mediator routing services must be created for each of the portTypes. 10.6.3 Creating Mediator Routing Services for Asynchronous Fire-and-Forget Patterns with a One-Way Call EBS To create Mediator routing services for asynchronous fire-and-forget patterns with a one-way call EBS: 1. Create Mediator projects. 2. Create routing services. 3. Create routing rules. 4. Implement error handling.

10.6.3.1 How to Create Mediator Projects for the Asynchronous Fire-and-Forget MEP

To create Mediator projects for the asynchronous fire-and-forget MEP: 1. Create two Mediator projects, one for each of the portTypes in the EBS WSDL. If all of the service operations for an EBS have either a synchronous request-response or fire-and-forget pattern, then all of these operations must reside in only one portType so there would be only one Mediator routing service. If the EBS has at least one asynchronous request-response operation, then there should be two port types - two Mediator Routing Services and two Mediator projects one for each of the routing services. Designing and Developing Enterprise Business Services 10-15 2. Follow the naming conventions detailed in Appendix: Oracle AIA Naming Standards. Examples of typical names for the Mediator projects: ■ CustomerPartyEBSV2 This has a routing service with all operations for synchronous request-response and request-only. ■ CustomerPartyEBSResponseV2 This has a routing service with all operations for asynchronous request-response.

10.6.3.2 How to Create Routing Services for Asynchronous Fire-and-Forget MEP

To create routing services for asynchronous fire-and-forget MEP: 1. Put the EBS WSDL in the Mediator project folder. 2. Create a routing service and name according to the naming convention detailed in Appendix: Oracle AIA Naming Standards. 3. Select the WSDL. The WSDL must be parsed and the portType name filled in the portType field of the routing service. 4. Select the portType matching with the routing service. Save the routing service. The routing service created for a portType must have all the operations specified in that portType in the EBS WSDL.

10.6.3.3 How to Create Routing Rules for Asynchronous Fire-and-Forget MEP

The routing rules for the request EBS are the same as those for the synchronous request-response section. For more information, see Section 10.7.3, How to Create Routing Services for the Synchronous Request-Response MEP .

10.6.3.4 How to Implement Error Handling for Asynchronous Fire-and-Forget MEP

For more information, see Chapter 24, Configuring Oracle AIA Processes for Error Handling and Trace Logging .

10.6.4 Asynchronous Fire-and-Forget MEP Error Handling Using Compensatory Operations