Hello Evenryone,
I have built a MPG that does the below process.
1) Accepts the JSON request with http request headers like - correlId,Content-type,xyz and then makes a call to ACE using Call-Processing rule with URL-open.
2) Depending on ACE response element value,
A. it may need to continue to next steps- transform request and call the next back-end
B. Send the response, using SKIP-backside
For case B: i am unable to send the response as the processing rule is in client-server mode and continue to execute the step A and finally giving the response.
I tried the below option:
In the Call processing rule: used On-Error Rule with Error mode-Cancel,Input:Auto,Output:Auto,ProcessingRule:Custom-error-rule, Then used session.reject to throw theException.When it reaches the Custom-error-rule, i am Creating the final json response and along with http response headers - correlId,Content-type,xyz(Same as requst Headers), those custom response headers are showing up in the probe but not at the application ex:postman.
Tried all the option to manipulate the http response headers using both XSLT and GatewayScript
<dp:set-http-request-header name="'correlation-id'" value="'45367373'"/>
<dp:set-http-response-header name="'correlation-id'" value="'45367373'"/>
Are there any configuration/properties to be updated at the MPG?
Postman snippet:

------------------------------
Sandeep Kolisetti
------------------------------