What Happens When You Configure a Process To React to a Specific Signal

Defining the Process Interface 21-5 Figure 21–3 Asynchronous BPMN process that exposes a start operation an its corresponding callback This figure shows a BPMN process that exposes a start operation and its corresponding callback, and how this reflects in the SOA Composite editor.

21.3 Using Message Events to Define Asynchronous Operations in a BPMN Processes

You can define asynchronous operations in a BPMN Process using message events. If you expose an asynchronous operation, then you must also expose a start operation. The client invoking the asynchronous service must invoke the start operation first to create an instance in the process. The asynchronous operation runs over the created instance. You must also specify a callback operation for each of the asynchronous operations you define.

21.3.1 How to Configure the Start Operation of a BPMN Process as Asynchronous Using Message Events

You can expose the start event of a BPMN process as an asynchronous operation. To configure the start operation of a BPMN process as asynchronous: 1. Edit the BPMN process. 2. Right-click the start activity.

3. Select Properties.

4. Click the Implementation tab.

5. If the Implementation Type is not message, then change it to Message. The Conversation section appears.

6. In the Conversation Properties section, select Define Interface from the

Implementation list. 21-6 Modeling and Implementation Guide for Oracle Business Process Management 7. If your asynchronous BPMN process requires input data, then you must define the process input in the Arguments Definition section. For more information on how to define the process input see Section 21.10, Defining the Process Input and Output .

8. Expand the Advanced section.

9. Select Asynchronous.

10. Enter a name for the start operation. The SOA Composite uses the name you specify for the operation to display it in the SOA Composite.

11. Click OK.

12. Follow the procedure described in Section 21.3.2, How to Define a Callback Operation Using Message Events , to define the callback operation of the asynchronous BPMN process.

21.3.2 How to Define a Callback Operation Using Message Events

You can expose a callback operation that pairs with an asynchronous operation using message events. To define the callback operation: 1. Edit the BPMN process.

2. Locate the point in your process where you want to return the answer of the

corresponding operation.

3. To return the answer before the process finishes, then add an intermediate

message throw event to your process.

4. Right-click the message throw event or the message end event.

5. Select Properties.

6. Click the Implementation tab.

7. If you are editing a throw message event, in the Conversation section, select

Continues . If you are editing an end message event this is the default selection and you cannot change it.

8. From the Initiator list, select the event to associate with the callback.

9. If you want your asynchronous process to return output data, then you must

define the process output in the Argument Definition section. For more information on how to define the process output, see Section 21.10, Defining the Process Input and Output .

10. Expand the Advanced section.

11. To change the name of the callback operation, then enter a name.

The SOA Composite uses the name you specify for the operation to display it in the SOA Composite. Note: To return the answer when the processes finishes, then add a message end event or change the implementation type of the end to message Defining the Process Interface 21-7