Objective: Demonstrate the use of the Call mediator for non-blocking web service invocations. It also demonstrates how we can use the Call mediator to implement service chaining scenarios.
- Deploy the SimpleStockQuoteService in sample Axis2 server and start it on port 9000.
- Start Synapse with the sample configuration 500 (
wso2esb-samples -sn 500).
In this sample, Call mediator does a direct service invocation to the StockQuoteService using the client request. After getting the response, a new payload is constructed using the Payload Factory mediator, and we invoke the StockQuoteService using the Call mediator again. Then, using the Respond mediator, the message is sent back to the client.
Invoke the client as follows.