Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -97,10 +97,10 @@ static void before(
throw new BlockingException("Blocked request (for StatusHeader/sendJson)");
}
}
}

@Advice.OnMethodExit(suppress = Throwable.class, onThrowable = Throwable.class)
static void after() {
CallDepthThreadLocalMap.decrementCallDepth(StatusHeader.class);
@Advice.OnMethodExit(suppress = Throwable.class, onThrowable = Throwable.class)
static void after() {
CallDepthThreadLocalMap.decrementCallDepth(StatusHeader.class);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2384,6 +2384,7 @@ abstract class HttpServerTest<SERVER> extends WithHttpServer<SERVER> {
boolean bodyConvertedBlock
boolean responseHeadersInTags
boolean responseBodyTag
Object responseBody
}

static final String stringOrEmpty(String string) {
Expand All @@ -2399,6 +2400,9 @@ abstract class HttpServerTest<SERVER> extends WithHttpServer<SERVER> {
final BiFunction<RequestContext, IGSpanInfo, Flow<Void>> requestEndedCb =
({ RequestContext rqCtxt, IGSpanInfo info ->
Context context = rqCtxt.getData(RequestContextSlot.APPSEC)
if (context.responseBodyTag) {
rqCtxt.traceSegment.setTagTop('response.body', context.responseBody)
}
if (context.extraSpanName) {
runUnderTrace(context.extraSpanName, false) {
def span = activeSpan()
Expand Down Expand Up @@ -2547,9 +2551,7 @@ abstract class HttpServerTest<SERVER> extends WithHttpServer<SERVER> {
body = obj.toString()
}
Context context = rqCtxt.getData(RequestContextSlot.APPSEC)
if (context.responseBodyTag) {
rqCtxt.traceSegment.setTagTop('response.body', body)
}
context.responseBody = body
if (context.responseBlock) {
new RbaFlow(
new Flow.Action.RequestBlockingAction(413, BlockingContentType.JSON)
Expand Down