Skip to content

Instantly share code, notes, and snippets.

@chanakaudaya
Created June 9, 2018 03:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chanakaudaya/c34bb115bc69c2f8b0f9121dd3a1c115 to your computer and use it in GitHub Desktop.
Save chanakaudaya/c34bb115bc69c2f8b0f9121dd3a1c115 to your computer and use it in GitHub Desktop.
<?xml version="1.0" encoding="UTF-8"?><sequence xmlns="http://ws.apache.org/ns/synapse" name="mashupSeq">
<log level="full">
<property name="STATUS" value="RESP-1"/>
</log>
<enrich>
<source type="body" clone="true"/>
<target type="property" property="response1"/>
</enrich>
<call>
<endpoint>
<http method="POST" uri-template="http://localhost:9091/service2"/>
</endpoint>
</call>
<log level="full">
<property name="STATUS" value="RESP-2"/>
</log>
<enrich>
<source type="body" clone="true"/>
<target type="property" property="response2"/>
</enrich>
<payloadFactory media-type="json">
<format>{results: [result1:$1, result2:$2]}</format>
<args>
<arg xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope" xmlns:ns3="http://org.apache.synapse/xsd" evaluator="xml" expression="$ctx:response1"/>
<arg xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope" xmlns:ns3="http://org.apache.synapse/xsd" evaluator="xml" expression="$ctx:response2"/>
</args>
</payloadFactory>
<respond/>
</sequence>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment