Class OpenSpan
java.lang.Object
com.palantir.tracing.api.OpenSpan
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic OpenSpan.Builderbuilder()Indicates if this trace state was sampled public abstract boolean isSampled();abstract StringReturns a description of the operation for this event.Deprecated.No longer used.Returns the identifier of the parent span for the current span, if one exists.abstract StringReturns a globally unique identifier representing a single span within the call trace.abstract longReturns the starting clock position in nanoseconds for use in computing span duration.abstract longReturns the start time in microseconds since epoch start of the span represented by this state.static OpenSpanUse this factory method to avoidOpenSpan.Builderallocations in hot paths.static OpenSpanof(String operation, String spanId, SpanType type, Optional<String> parentSpanId, Optional<String> _originatingSpanId) Deprecated.Use the variant without an originating span idabstract SpanTypetype()Indicates theSpanTypeof this span, e.g., a server-side vs.
-
Constructor Details
-
OpenSpan
public OpenSpan()
-
-
Method Details
-
getOperation
Returns a description of the operation for this event. -
getStartTimeMicroSeconds
@Parameter public abstract long getStartTimeMicroSeconds()Returns the start time in microseconds since epoch start of the span represented by this state.Users of this class should not set this value manually in the builder, it is configured automatically when using the
builder()static. -
getStartClockNanoSeconds
@Parameter public abstract long getStartClockNanoSeconds()Returns the starting clock position in nanoseconds for use in computing span duration.Users of this class should not set this value manually in the builder, it is configured automatically when using the
builder()static. -
getParentSpanId
-
getOriginatingSpanId
Deprecated.No longer used.Returns the identifier of the 'originating' span if one exists.- See Also:
-
getSpanId
Returns a globally unique identifier representing a single span within the call trace. -
type
-
builder
Indicates if this trace state was sampled public abstract boolean isSampled();/** Returns a builder for
OpenSpanpre-initialized to use the current time.Users should not set the
startTimeMsvalue manually. -
of
@Deprecated public static OpenSpan of(String operation, String spanId, SpanType type, Optional<String> parentSpanId, Optional<String> _originatingSpanId) Deprecated.Use the variant without an originating span idUse this factory method to avoidOpenSpan.Builderallocations in hot paths. -
of
-