Class DatastoreOpenTelemetryOptions.Builder (2.23.0)

public static class DatastoreOpenTelemetryOptions.Builder

Inheritance

java.lang.Object > DatastoreOpenTelemetryOptions.Builder

Methods

build()

public DatastoreOpenTelemetryOptions build()
Returns
Type Description
DatastoreOpenTelemetryOptions

setOpenTelemetry(OpenTelemetry openTelemetry)

public DatastoreOpenTelemetryOptions.Builder setOpenTelemetry(OpenTelemetry openTelemetry)

Sets the OpenTelemetry to use with this Datastore instance. If telemetry collection is enabled, but an OpenTelemetry is not provided, the Datastore SDK will attempt to use the GlobalOpenTelemetry.

Parameter
Name Description
openTelemetry io.opentelemetry.api.OpenTelemetry

The OpenTelemetry that should be used by this Datastore instance.

Returns
Type Description
DatastoreOpenTelemetryOptions.Builder

setTracingEnabled(boolean enabled)

public DatastoreOpenTelemetryOptions.Builder setTracingEnabled(boolean enabled)

Sets whether tracing should be enabled.

Parameter
Name Description
enabled boolean

Whether tracing should be enabled.

Returns
Type Description
DatastoreOpenTelemetryOptions.Builder