Hello,
I'm having a business service of type "native REST", connected to a pipeline of type "Any SOAP". The service sends a JSON message to a remote server and receives a JSON response- so far, so good.
Problem: When I'm trying to log the response with an log activity using javascript (process.body) the message says: Received response:: null. Thus subsequently access to the payload causes an error.
I've activated tracing for the business service and can see, that there is answer incoming:
Response metadata =
<xml-fragment>
<tran:headers xsi:type="http:HttpResponseHeaders" xmlns:http="http://www.bea.com/wli/sb/transports/http" xmlns:tran="http://www.bea.com/wli/sb/transports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<tran:user-header name="Access-Control-Allow-Origin" value="*"/>
<tran:user-header name="Expires" value="0"/>
<tran:user-header name="Strict-Transport-Security" value="max-age=31536000;includeSubdomains"/>
<tran:user-header name="X-Content-Type-Options" value="nosniff"/>
<tran:user-header name="X-Frame-Options" value="DENY"/>
<tran:user-header name="X-RateLimit-Limit-second" value="10"/>
<tran:user-header name="X-RateLimit-Remaining-second" value="9"/>
<tran:user-header name="X-XSS-Protection" value="1; mode=block"/>
<http:Cache-Control>no-cache, no-store, max-age=0, must-revalidate</http:Cache-Control>
<http:Content-Type>application/json;charset=UTF-8</http:Content-Type>
<http:Date>Mon, 05 Aug 2019 06:18:42 GMT</http:Date>
<http:Pragma>no-cache</http:Pragma>
<http:Set-Cookie>7609f7efeb008d365fefeed0246b3cb9=028f52403b095fd107f999c968fef0cc; path=/; HttpOnly; Secure</http:Set-Cookie>
<http:Transfer-Encoding>chunked</http:Transfer-Encoding>
<http:Vary>accept-encoding</http:Vary>
</tran:headers>
<tran:response-code xmlns:tran="http://www.bea.com/wli/sb/transports">0</tran:response-code>
<tran:encoding xmlns:tran="http://www.bea.com/wli/sb/transports">UTF-8</tran:encoding>
<http:http-response-code xmlns:http="http://www.bea.com/wli/sb/transports/http">200</http:http-response-code>
</xml-fragment>
Payload =
{"id":4711,"status":"NOT_READY"}
Somehow the payload get's lost in the handover from business service to pipeline. Any ideas on why this could happen are very welcome.
Addition: I just found out that I can access the payload in an XQuery-snippet and it's actually there, but in javascript using process.body the returned value is null.
Cheers
- akay