Package org.springframework.cloud.sleuth
Interface TraceContext
-
public interface TraceContext
Contains trace and span data.- Since:
- 3.0.0
- Author:
- Marcin Grzejszczak
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
TraceContext.Builder
Builder forTraceContext
.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description String
parentId()
Parent span id.Boolean
sampled()
String
spanId()
Span id.String
traceId()
Trace id.
-
-
-
Method Detail
-
traceId
String traceId()
Trace id.- Returns:
- trace id of a span
-
parentId
@Nullable String parentId()
Parent span id.- Returns:
- parent span id or
null
if one is not set
-
spanId
String spanId()
Span id.- Returns:
- span id
-
sampled
Boolean sampled()
- Returns:
true
when sampled,false
when not sampled andnull
when sampling decision should be deferred
-
-