Skip to content

Cloud Client Library with OpenTelemetry 調査隊 #150

Description

@sinmetal

Cloud Client Library for Goのtraceのコメントに2024/05/29を過ぎたら、OpenTelemetryがdefaultで使われるようになると書いてある。
引き続きOpenCensusを使い続けたい場合は $GOOGLE_API_GO_EXPERIMENTAL_TELEMETRY_PLATFORM_TRACING=opencensus を指定する

// TracePrintf retrieves the current OpenCensus or OpenTelemetry span from context, then:
// * calls Span.Annotatef if OpenCensus is enabled; or
// * calls Span.AddEvent if OpenTelemetry is enabled.
//
// If IsOpenCensusTracingEnabled returns true, the expected span must be an
// OpenCensus span. If IsOpenTelemetryTracingEnabled returns true, the expected
// span must be an OpenTelemetry span. Set the environment variable
// GOOGLE_API_GO_EXPERIMENTAL_TELEMETRY_PLATFORM_TRACING to the case-insensitive
// value "opentelemetry" before loading the package to use OpenTelemetry tracing.
// The default will remain OpenCensus until May 29, 2024, at which time the default will
// switch to "opentelemetry" and explicitly setting the environment variable to
// "opencensus" will be required to continue using OpenCensus tracing.

https://github.com/googleapis/google-cloud-go/blob/e5d0c2fc2182174b9307363b48c0a0e4056cb3f4/internal/trace/trace.go#L186C1-L197C71

現状、Javaなど他の言語ではotelへの以降は入っていない?
googleapis/java-spanner#2593 はcloseされている。

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions