@Generated(value="OracleSDKGenerator", comments="API Version: 20200630") public final class Span extends Object
Definition of a span object.
Span.Builder
. This model distinguishes fields
that are null
because they are unset from fields that are explicitly set to null
. This is done in
the setter methods of the Span.Builder
, which maintain a set of all explicitly set fields called
__explicitlySet__
. The hashCode()
and equals(Object)
methods are implemented to take
__explicitlySet__
into account. The constructor, on the other hand, does not set __explicitlySet__
(since the constructor cannot distinguish explicit null
from unset null
).Modifier and Type | Class and Description |
---|---|
static class |
Span.Builder |
Constructor and Description |
---|
Span(String key,
String parentSpanKey,
String traceKey,
Date timeStarted,
Date timeEnded,
Long durationInMs,
String operationName,
String serviceName,
String kind,
List<Tag> tags,
List<SpanLogCollection> logs,
Boolean isError)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
static Span.Builder |
builder()
Create a new builder.
|
boolean |
equals(Object o) |
Set<String> |
get__explicitlySet__() |
Long |
getDurationInMs()
Total span duration in milliseconds.
|
Boolean |
getIsError()
Indicates if the span has an error.
|
String |
getKey()
Unique identifier (spanId) for the span.
|
String |
getKind()
Kind associated with the span.
|
List<SpanLogCollection> |
getLogs()
List of logs associated with the span.
|
String |
getOperationName()
Span name associated with the trace.
|
String |
getParentSpanKey()
Unique parent identifier for the span if one exists.
|
String |
getServiceName()
Service name associated with the span.
|
List<Tag> |
getTags()
List of tags associated with the span.
|
Date |
getTimeEnded()
Span end time.
|
Date |
getTimeStarted()
Span start time.
|
String |
getTraceKey()
Unique identifier for the trace.
|
int |
hashCode() |
Span.Builder |
toBuilder() |
String |
toString() |
@Deprecated @ConstructorProperties(value={"key","parentSpanKey","traceKey","timeStarted","timeEnded","durationInMs","operationName","serviceName","kind","tags","logs","isError"}) public Span(String key, String parentSpanKey, String traceKey, Date timeStarted, Date timeEnded, Long durationInMs, String operationName, String serviceName, String kind, List<Tag> tags, List<SpanLogCollection> logs, Boolean isError)
public static Span.Builder builder()
Create a new builder.
public Span.Builder toBuilder()
public String getKey()
Unique identifier (spanId) for the span. Note that this field is defined as spanKey in the API and it maps to the spanId in the trace data in Application Performance Monitoring.
public String getParentSpanKey()
Unique parent identifier for the span if one exists. For root spans this will be null.
public String getTraceKey()
Unique identifier for the trace.
public Date getTimeStarted()
Span start time. Timestamp when the span was started.
public Date getTimeEnded()
Span end time. Timestamp when the span was completed.
public Long getDurationInMs()
Total span duration in milliseconds.
public String getOperationName()
Span name associated with the trace. This is usually the method or URI of the request.
public String getServiceName()
Service name associated with the span.
public String getKind()
Kind associated with the span.
public List<SpanLogCollection> getLogs()
List of logs associated with the span.
public Boolean getIsError()
Indicates if the span has an error.
Copyright © 2016–2022. All rights reserved.