I have this VSM (using DT 8.5.0) that has a few script steps, then executes an HTTP/S live invocation step to pass the request on to the original server.
I get the correct response from the server, and now let it fall thru to do the normal respond processing
script step 1
script step 2
http/s live invocation
prepare response
respond
the response at postman looks good, except no data
return code is 200 OK
the headers come back properly
I removed the leading < to make this show
the response data from the Respond step looks like this
java.util.Arrays_-ArrayList>
<a class="TransientResponse-array">
<TransientResponse xmlns="http://www.ca.com/com/itko/lisa/vse/stateful/model/v1.0">
<id>0</id>
<binary>false</binary>
<charset>UTF-8</charset>
<metaData>
<p key="HTTP-Response-Code">200</p>
<p key="HTTP-Response-Code-Text">OK</p>
<p key="Access-Control-Allow-Headers">origin, content-type, accept</p>
<p key="Access-Control-Allow-Methods">GET, POST, DELETE, PUT, PATCH, OPTIONS, HEAD</p>
<p key="Access-Control-Allow-Origin">*</p>
<p key="Cache-Control">no-store</p>
<p key="WasGzip">gzip</p>
<p key="Content-Encoding">gzip</p>
<p key="Content-Type">application/json</p>
<p key="Date">Wed, 09 Mar 2016 12:47:11 GMT</p>
<p key="Pragma">no-cache</p>
<p key="Server">nginx/1.8.0</p>
<p key="X-XX-TransactionID">update1002</p>
<p key="Content-Length">169</p>
<p key="Connection">keep-alive</p>
</metaData>
<body>
<bodyAsString>{"firstName":"Tommy","lastName":"Dreamer","displayName":"John132","email":"Test198@mailinator.com","title":"AD","locale":"en_US","username":"Test198@mailinator.com","tivoliUuid":"7798e011-2627-4601-8176-c6cb63de8bfc"}</bodyAsString>
</body>
<unknown>false</unknown>
<thinkTimeSpec>0</thinkTimeSpec>
</TransientResponse>
</a>
/java.util.Arrays_-ArrayList>
the only thing I could think of is the Content-Encoding header
so I added a filter on the live inv step, to remove it, but my filter never executes..
process responses, use lisa.vse.response, this script is on both process tabs.. record and playback
%groovy%
import com.itko.util.ParameterList;
_logger.info("IN FILTER r")
// Metadata is a ParameterList
ParameterList metadata = lisa_vse_response.getMetaData();
String ce=metadata.getParameter("Content-Encoding")
_logger.info("filter has parm="+ce)
if(ce!=null && ce.equalsIgnoreCase("gzip"))
{
_logger.info("removing")
metadata.removeParameter("Content-Encoding")
lisa_vse_response.setMetaData(metadata);
}
no log entry is recorded