Class TemporalClientConnectOptionsExtensions
- Namespace
- Temporalio.Extensions.Gcp.CloudRun.OpenTelemetry
- Assembly
- Temporalio.Extensions.Gcp.CloudRun.OpenTelemetry.dll
OpenTelemetry extensions for TemporalClientConnectOptions for Temporal workers running on Google Cloud Run, primarily in worker pools.
public static class TemporalClientConnectOptionsExtensions
- Inheritance
-
TemporalClientConnectOptionsExtensions
- Inherited Members
Remarks
WARNING: Google Cloud Run support is experimental.
Methods
ApplyGoogleCloudRunOpenTelemetryDefaults(TemporalClientConnectOptions, GoogleCloudRunOpenTelemetryOptions?)
Configure OpenTelemetry metrics and tracing with Google Cloud Run defaults.
public static GoogleCloudRunOpenTelemetryShutdown ApplyGoogleCloudRunOpenTelemetryDefaults(this TemporalClientConnectOptions options, GoogleCloudRunOpenTelemetryOptions? openTelemetryOptions = null)
Parameters
optionsTemporalClientConnectOptionsClient connection options to mutate.
openTelemetryOptionsGoogleCloudRunOpenTelemetryOptionsOptional OpenTelemetry configuration.
Returns
- GoogleCloudRunOpenTelemetryShutdown
A handle that owns the created tracer provider. Dispose it after every worker and client using these options has stopped to flush and release the provider. Use FlushAsync(TimeSpan, CancellationToken) to force-flush traces within a bounded time during graceful shutdown.
Remarks
This creates an OTLP gRPC trace exporter and tracer provider pointed at a local collector sidecar, configures Core SDK metrics through a Temporal runtime, and adds the Temporal tracing interceptor. Google Cloud resource detection, authentication, and export are the responsibility of the collector. Any existing Runtime is replaced.