You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: dd-java-agent/instrumentation/scalatest/src/main/java/datadog/trace/instrumentation/scalatest/ScalatestForkInstrumentation.java
+6Lines changed: 6 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -55,6 +55,12 @@ public void methodAdvice(MethodTransformer transformer) {
55
55
* the tests) and not the parent one. The way to distinguish between the two is by examining the
56
56
* "remoteArgs" passed to the runner method: the args are non-empty in the child process, and
57
57
* empty in the parent one.
58
+
*
59
+
* <p>The instrumentation works by increasing the Reporter.class counter in the call depth thread
60
+
* local map. The counter is decreased when the runner method exits.
61
+
*
62
+
* <p>Since the tracing instrumentation is checking the counter value to avoid nested calls,
63
+
* increasing it here results in effectively disabling the tracing.
0 commit comments