Class OpenCensusSpan (6.60.0)

public class OpenCensusSpan implements ISpan

Inheritance

java.lang.Object > OpenCensusSpan

Implements

com.google.cloud.spanner.ISpan

Constructors

OpenCensusSpan(Span openCensusSpan)

public OpenCensusSpan(Span openCensusSpan)
Parameter
NameDescription
openCensusSpanio.opencensus.trace.Span

Methods

addAnnotation(String message)

public void addAnnotation(String message)
Parameter
NameDescription
messageString

addAnnotation(String message, String key, String value)

public void addAnnotation(String message, String key, String value)
Parameters
NameDescription
messageString
keyString
valueString

addAnnotation(String message, String key, long value)

public void addAnnotation(String message, String key, long value)
Parameters
NameDescription
messageString
keyString
valuelong

addAnnotation(String message, Throwable e)

public void addAnnotation(String message, Throwable e)
Parameters
NameDescription
messageString
eThrowable

addAnnotation(String message, Map<String,Object> attributes)

public void addAnnotation(String message, Map<String,Object> attributes)

Adds an annotation to the OpenCensus and OpenTelemetry span.

Parameters
NameDescription
messageString
attributesMap<String,Object>

end()

public void end()

setStatus(ErrorCode errorCode)

public void setStatus(ErrorCode errorCode)
Parameter
NameDescription
errorCodeErrorCode

setStatus(Throwable e)

public void setStatus(Throwable e)
Parameter
NameDescription
eThrowable