Interface SpanOrBuilder (2.28.0)

public interface SpanOrBuilder extends MessageOrBuilder

Implements

MessageOrBuilder

Methods

getAttributes()

public abstract Span.Attributes getAttributes()

A set of attributes on the span. You can have up to 32 attributes per span.

.google.devtools.cloudtrace.v2.Span.Attributes attributes = 7;

Returns
TypeDescription
Span.Attributes

The attributes.

getAttributesOrBuilder()

public abstract Span.AttributesOrBuilder getAttributesOrBuilder()

A set of attributes on the span. You can have up to 32 attributes per span.

.google.devtools.cloudtrace.v2.Span.Attributes attributes = 7;

Returns
TypeDescription
Span.AttributesOrBuilder

getChildSpanCount()

public abstract Int32Value getChildSpanCount()

Optional. The number of child spans that were generated while this span was active. If set, allows implementation to detect missing child spans.

.google.protobuf.Int32Value child_span_count = 13 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Int32Value

The childSpanCount.

getChildSpanCountOrBuilder()

public abstract Int32ValueOrBuilder getChildSpanCountOrBuilder()

Optional. The number of child spans that were generated while this span was active. If set, allows implementation to detect missing child spans.

.google.protobuf.Int32Value child_span_count = 13 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Int32ValueOrBuilder

getDisplayName()

public abstract TruncatableString getDisplayName()

Required. A description of the span's operation (up to 128 bytes). Cloud Trace displays the description in the Cloud console. For example, the display name can be a qualified method name or a file name and a line number where the operation is called. A best practice is to use the same display name within an application and at the same call point. This makes it easier to correlate spans in different traces.

.google.devtools.cloudtrace.v2.TruncatableString display_name = 4 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
TruncatableString

The displayName.

getDisplayNameOrBuilder()

public abstract TruncatableStringOrBuilder getDisplayNameOrBuilder()

Required. A description of the span's operation (up to 128 bytes). Cloud Trace displays the description in the Cloud console. For example, the display name can be a qualified method name or a file name and a line number where the operation is called. A best practice is to use the same display name within an application and at the same call point. This makes it easier to correlate spans in different traces.

.google.devtools.cloudtrace.v2.TruncatableString display_name = 4 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
TruncatableStringOrBuilder

getEndTime()

public abstract Timestamp getEndTime()

Required. The end time of the span. On the client side, this is the time kept by the local machine where the span execution ends. On the server side, this is the time when the server application handler stops running.

.google.protobuf.Timestamp end_time = 6 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
Timestamp

The endTime.

getEndTimeOrBuilder()

public abstract TimestampOrBuilder getEndTimeOrBuilder()

Required. The end time of the span. On the client side, this is the time kept by the local machine where the span execution ends. On the server side, this is the time when the server application handler stops running.

.google.protobuf.Timestamp end_time = 6 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
TimestampOrBuilder
public abstract Span.Links getLinks()

Links associated with the span. You can have up to 128 links per Span.

.google.devtools.cloudtrace.v2.Span.Links links = 10;

Returns
TypeDescription
Span.Links

The links.

getLinksOrBuilder()

public abstract Span.LinksOrBuilder getLinksOrBuilder()

Links associated with the span. You can have up to 128 links per Span.

.google.devtools.cloudtrace.v2.Span.Links links = 10;

Returns
TypeDescription
Span.LinksOrBuilder

getName()

public abstract String getName()

Required. The resource name of the span in the following format:

  • projects/[PROJECT_ID]/traces/[TRACE_ID]/spans/[SPAN_ID]

    [TRACE_ID] is a unique identifier for a trace within a project; it is a 32-character hexadecimal encoding of a 16-byte array. It should not be zero.

    [SPAN_ID] is a unique identifier for a span within a trace; it is a 16-character hexadecimal encoding of an 8-byte array. It should not be zero. .

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
String

The name.

getNameBytes()

public abstract ByteString getNameBytes()

Required. The resource name of the span in the following format:

  • projects/[PROJECT_ID]/traces/[TRACE_ID]/spans/[SPAN_ID]

    [TRACE_ID] is a unique identifier for a trace within a project; it is a 32-character hexadecimal encoding of a 16-byte array. It should not be zero.

    [SPAN_ID] is a unique identifier for a span within a trace; it is a 16-character hexadecimal encoding of an 8-byte array. It should not be zero. .

string name = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ByteString

The bytes for name.

getParentSpanId()

public abstract String getParentSpanId()

The [SPAN_ID] of this span's parent span. If this is a root span, then this field must be empty.

string parent_span_id = 3;

Returns
TypeDescription
String

The parentSpanId.

getParentSpanIdBytes()

public abstract ByteString getParentSpanIdBytes()

The [SPAN_ID] of this span's parent span. If this is a root span, then this field must be empty.

string parent_span_id = 3;

Returns
TypeDescription
ByteString

The bytes for parentSpanId.

getSameProcessAsParentSpan()

public abstract BoolValue getSameProcessAsParentSpan()

Optional. Set this parameter to indicate whether this span is in the same process as its parent. If you do not set this parameter, Trace is unable to take advantage of this helpful information.

.google.protobuf.BoolValue same_process_as_parent_span = 12 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
BoolValue

The sameProcessAsParentSpan.

getSameProcessAsParentSpanOrBuilder()

public abstract BoolValueOrBuilder getSameProcessAsParentSpanOrBuilder()

Optional. Set this parameter to indicate whether this span is in the same process as its parent. If you do not set this parameter, Trace is unable to take advantage of this helpful information.

.google.protobuf.BoolValue same_process_as_parent_span = 12 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
BoolValueOrBuilder

getSpanId()

public abstract String getSpanId()

Required. The [SPAN_ID] portion of the span's resource name.

string span_id = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
String

The spanId.

getSpanIdBytes()

public abstract ByteString getSpanIdBytes()

Required. The [SPAN_ID] portion of the span's resource name.

string span_id = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ByteString

The bytes for spanId.

getSpanKind()

public abstract Span.SpanKind getSpanKind()

Optional. Distinguishes between spans generated in a particular context. For example, two spans with the same name may be distinguished using CLIENT (caller) and SERVER (callee) to identify an RPC call.

.google.devtools.cloudtrace.v2.Span.SpanKind span_kind = 14 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
Span.SpanKind

The spanKind.

getSpanKindValue()

public abstract int getSpanKindValue()

Optional. Distinguishes between spans generated in a particular context. For example, two spans with the same name may be distinguished using CLIENT (caller) and SERVER (callee) to identify an RPC call.

.google.devtools.cloudtrace.v2.Span.SpanKind span_kind = 14 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
int

The enum numeric value on the wire for spanKind.

getStackTrace()

public abstract StackTrace getStackTrace()

Stack trace captured at the start of the span.

.google.devtools.cloudtrace.v2.StackTrace stack_trace = 8;

Returns
TypeDescription
StackTrace

The stackTrace.

getStackTraceOrBuilder()

public abstract StackTraceOrBuilder getStackTraceOrBuilder()

Stack trace captured at the start of the span.

.google.devtools.cloudtrace.v2.StackTrace stack_trace = 8;

Returns
TypeDescription
StackTraceOrBuilder

getStartTime()

public abstract Timestamp getStartTime()

Required. The start time of the span. On the client side, this is the time kept by the local machine where the span execution starts. On the server side, this is the time when the server's application handler starts running.

.google.protobuf.Timestamp start_time = 5 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
Timestamp

The startTime.

getStartTimeOrBuilder()

public abstract TimestampOrBuilder getStartTimeOrBuilder()

Required. The start time of the span. On the client side, this is the time kept by the local machine where the span execution starts. On the server side, this is the time when the server's application handler starts running.

.google.protobuf.Timestamp start_time = 5 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
TimestampOrBuilder

getStatus()

public abstract Status getStatus()

Optional. The final status for this span.

.google.rpc.Status status = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
com.google.rpc.Status

The status.

getStatusOrBuilder()

public abstract StatusOrBuilder getStatusOrBuilder()

Optional. The final status for this span.

.google.rpc.Status status = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
com.google.rpc.StatusOrBuilder

getTimeEvents()

public abstract Span.TimeEvents getTimeEvents()

A set of time events. You can have up to 32 annotations and 128 message events per span.

.google.devtools.cloudtrace.v2.Span.TimeEvents time_events = 9;

Returns
TypeDescription
Span.TimeEvents

The timeEvents.

getTimeEventsOrBuilder()

public abstract Span.TimeEventsOrBuilder getTimeEventsOrBuilder()

A set of time events. You can have up to 32 annotations and 128 message events per span.

.google.devtools.cloudtrace.v2.Span.TimeEvents time_events = 9;

Returns
TypeDescription
Span.TimeEventsOrBuilder

hasAttributes()

public abstract boolean hasAttributes()

A set of attributes on the span. You can have up to 32 attributes per span.

.google.devtools.cloudtrace.v2.Span.Attributes attributes = 7;

Returns
TypeDescription
boolean

Whether the attributes field is set.

hasChildSpanCount()

public abstract boolean hasChildSpanCount()

Optional. The number of child spans that were generated while this span was active. If set, allows implementation to detect missing child spans.

.google.protobuf.Int32Value child_span_count = 13 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
boolean

Whether the childSpanCount field is set.

hasDisplayName()

public abstract boolean hasDisplayName()

Required. A description of the span's operation (up to 128 bytes). Cloud Trace displays the description in the Cloud console. For example, the display name can be a qualified method name or a file name and a line number where the operation is called. A best practice is to use the same display name within an application and at the same call point. This makes it easier to correlate spans in different traces.

.google.devtools.cloudtrace.v2.TruncatableString display_name = 4 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
boolean

Whether the displayName field is set.

hasEndTime()

public abstract boolean hasEndTime()

Required. The end time of the span. On the client side, this is the time kept by the local machine where the span execution ends. On the server side, this is the time when the server application handler stops running.

.google.protobuf.Timestamp end_time = 6 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
boolean

Whether the endTime field is set.

public abstract boolean hasLinks()

Links associated with the span. You can have up to 128 links per Span.

.google.devtools.cloudtrace.v2.Span.Links links = 10;

Returns
TypeDescription
boolean

Whether the links field is set.

hasSameProcessAsParentSpan()

public abstract boolean hasSameProcessAsParentSpan()

Optional. Set this parameter to indicate whether this span is in the same process as its parent. If you do not set this parameter, Trace is unable to take advantage of this helpful information.

.google.protobuf.BoolValue same_process_as_parent_span = 12 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
boolean

Whether the sameProcessAsParentSpan field is set.

hasStackTrace()

public abstract boolean hasStackTrace()

Stack trace captured at the start of the span.

.google.devtools.cloudtrace.v2.StackTrace stack_trace = 8;

Returns
TypeDescription
boolean

Whether the stackTrace field is set.

hasStartTime()

public abstract boolean hasStartTime()

Required. The start time of the span. On the client side, this is the time kept by the local machine where the span execution starts. On the server side, this is the time when the server's application handler starts running.

.google.protobuf.Timestamp start_time = 5 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
boolean

Whether the startTime field is set.

hasStatus()

public abstract boolean hasStatus()

Optional. The final status for this span.

.google.rpc.Status status = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
TypeDescription
boolean

Whether the status field is set.

hasTimeEvents()

public abstract boolean hasTimeEvents()

A set of time events. You can have up to 32 annotations and 128 message events per span.

.google.devtools.cloudtrace.v2.Span.TimeEvents time_events = 9;

Returns
TypeDescription
boolean

Whether the timeEvents field is set.