use of com.nr.agent.instrumentation.mule3.MuleHttpConnectorResponse in project newrelic-java-agent by newrelic.
the class HttpResponseBuilder_Instrumentation method build.
@Trace(excludeFromTransactionTrace = true)
public HttpResponse build() {
MuleHttpConnectorResponse response = new MuleHttpConnectorResponse(headers, responseStatus);
NewRelic.getAgent().getTracedMethod().addOutboundRequestHeaders(response);
final Transaction txn = AgentBridge.getAgent().getTransaction(false);
if (txn != null) {
txn.setWebResponse(response);
long contentLength;
try {
contentLength = getContentLength(response);
} catch (Exception e) {
contentLength = -1L;
}
txn.getCrossProcessState().processOutboundResponseHeaders(response, contentLength);
}
return Weaver.callOriginal();
}
Aggregations