Skip to content

Commit 20c14a4

Browse files
authored
Enable experimental gRPC instrumentation when enabling tracing (#75)
* enable experimental gRPC tracing
1 parent a0e0285 commit 20c14a4

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## 0.7.0-beta.2
44

5+
* Sets `OTEL_DOTNET_EXPERIMENTAL_ASPNETCORE_ENABLE_GRPC_INSTRUMENTATION`
6+
to `true` when enabling tracing. [gRPC instrumentation is experimental](https://github.com/open-telemetry/opentelemetry-dotnet/releases/tag/Instrumentation.AspNetCore-1.6.0),
7+
while HTTP is stable.
8+
59
### Bug fixes
610

711
* [#71](https://github.com/grafana/grafana-opentelemetry-dotnet/issues/71):

src/Grafana.OpenTelemetry.Base/MeterProviderBuilderExtensions.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,10 @@ public static MeterProviderBuilder UseGrafana(this MeterProviderBuilder builder,
3131

3232
GrafanaOpenTelemetryEventSource.Log.InitializeDistribution(settings);
3333

34-
// Default to using stable HTTP semantic conventions
35-
if (Environment.GetEnvironmentVariable("OTEL_SEMCONV_STABILITY_OPT_IN") == null)
34+
// Default to using experimental gRPC instrumentation
35+
if (Environment.GetEnvironmentVariable("OTEL_DOTNET_EXPERIMENTAL_ASPNETCORE_ENABLE_GRPC_INSTRUMENTATION") == null)
3636
{
37-
Environment.SetEnvironmentVariable("OTEL_SEMCONV_STABILITY_OPT_IN", "http");
37+
Environment.SetEnvironmentVariable("OTEL_DOTNET_EXPERIMENTAL_ASPNETCORE_ENABLE_GRPC_INSTRUMENTATION", "true");
3838
}
3939

4040
return builder

0 commit comments

Comments
 (0)