Concurent instrumentation tests: block thread before starting tracing
Otherwise blocking thread is pretty much useless since we may still get spans if threads are executed quickly enough.
This commit is contained in:
parent
06bd670f0a
commit
354cbfcb2d
|
|
@ -31,12 +31,12 @@ public class AsyncChild implements Runnable, Callable {
|
|||
}
|
||||
|
||||
private void runImpl() {
|
||||
if (doTraceableWork) {
|
||||
asyncChild();
|
||||
}
|
||||
while (blockThread.get()) {
|
||||
// busy-wait to block thread
|
||||
}
|
||||
if (doTraceableWork) {
|
||||
asyncChild();
|
||||
}
|
||||
}
|
||||
|
||||
@Trace(operationName = "asyncChild")
|
||||
|
|
|
|||
Loading…
Reference in New Issue