wso2 / micro-integrator

The cloud-native configuration driven runtime that helps developers implement composite microservices.
https://wso2.com/integration/
Apache License 2.0
194 stars 206 forks source link

DataServiceCall operationName replaces <mediate> tag when triggering a following fileAttachment API #3372

Open izzypod5 opened 1 week ago

izzypod5 commented 1 week ago

When I use a dataServiceCall mediator in one API it seems to save the operationName saved to the messageContext as can be found from the Synapse Message Context Properties after logging it.

Then when I call my next API which takes a file as form-data content usually I would expect to get a mediate tag covering the content but in this case it is getting replaced by the operationName of the previous call.

Note: calling the dataService via the call mediator does not have this behaviour and works as expected.

<soapenv:Body xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope"><query_fetch_operation><content filename="id-document.png" ... </content></query_fetch_operation></soapenv:Body>

vs expected:

<soapenv:Body xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope"><mediate><content filename="id-document.png" ... </content></mediate></soapenv:Body>