Hi Udara,
I tried a similar scenario using the following main sequence.
sequence xmlns=http://ws.apache.org/ns/synapse; name=main
in/in
out
payloadFactory media-type=json
format{ stock_code : $1, stock_price :
$2}/format
args
arg
Hi Dilan,
First payloadFactory in out sequence is not in the proxy, it was pasted
mistakenly. Response from backend is soap. I just wanted to send back a
dummy json response to the client. That's why I used a payload factory.
On 26 Jan 2015 10:06, Dilan Udara Ariyaratne dil...@wso2.com wrote:
Hi Udara,
What is the type of response received by ESB from the back-end? Is it XML
or JSON?
Also if your requirement was to get a JSON in return, what was the purpose
of using two payload factories within the out sequence?
Shouldn't it be only one payload factory mediator of media-type=json?
Hi,
I tried below sequence to get a JSON response back. However no response
received to the client. I tried having Respond mediator instead of Send in
out sequence. What is missing which prevents response is being received.
1. sequence name=main
2. in
3. log level=custom