You have being using service task for invoking synchronous operations in services. You have invoked the synchronous service StockValidator_EBS, to validate stock in Chapter 8, Exception Management. However, in this section, you will learn how synchronous service invocation works.
Here, you will learn to invoke a synchronous service using a service task:
BPMN Service Engine runs a service task and waits for the service to respond before continuing with the process flow. When the service finishes running, it sends a response to the service task. If the service operation returns output data, then this data is mapped to the data objects in the project using the service task data association.
In the way you have implemented the invocation of a synchronous operation on a service, you can also invoke a BPM synchronous operation using service task.
A synchronous BPM process operation can be invoked using a service task, as follows:
In case of a synchronous BPMN process invocation, BPMN Service Engine waits for the response. When the synchronous BPMN process completes, it sends a response, and if the response has returned the data, it gets mapped to the data objects assigned to output of the service task.
3.138.35.193