// let's assume that we're in a thread Y and we've received
// the `initialSpan` from thread X. `initialSpan` will be the parent
// of the `joinedSpan`
-Span joinedSpan = this.tracer.joinTrace("calculateCommission", initialSpan);
+Span joinedSpan = this.tracer.createSpan("calculateCommission", initialSpan);
try {
// ...
// You can tag a span
@@ -1018,7 +1018,7 @@ try {
Important
-After having joined the span remember to close it. Otherwise you will see a lot of warnings in your logs
+After having created such a span remember to close it. Otherwise you will see a lot of warnings in your logs
related to the fact that you have a span present in the current thread other than the one you’re trying to close.
What’s worse your spans won’t get closed properly thus will not get collected to Zipkin.
|
@@ -1253,7 +1253,7 @@ the number of dropped spans will get increased.