From 3c11ae7f3352d7986f1d038e80beb09647087827 Mon Sep 17 00:00:00 2001 From: "Timothy Mothra Lee (from Dev Box)" Date: Mon, 11 Nov 2024 17:18:34 -0800 Subject: [PATCH] cleanup --- .../Implementation/HttpHandlerDiagnosticListener.cs | 2 +- .../HttpClientTests.Basic.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/OpenTelemetry.Instrumentation.Http/Implementation/HttpHandlerDiagnosticListener.cs b/src/OpenTelemetry.Instrumentation.Http/Implementation/HttpHandlerDiagnosticListener.cs index 84f06a56dc..9c47aa894d 100644 --- a/src/OpenTelemetry.Instrumentation.Http/Implementation/HttpHandlerDiagnosticListener.cs +++ b/src/OpenTelemetry.Instrumentation.Http/Implementation/HttpHandlerDiagnosticListener.cs @@ -26,7 +26,7 @@ internal sealed class HttpHandlerDiagnosticListener : ListenerHandler internal static readonly string ActivitySourceName = AssemblyName.Name + ".HttpClient"; internal static readonly Version Version = AssemblyName.Version!; internal static readonly ActivitySource ActivitySource = new(ActivitySourceName, Version.ToString()); - + private const string OnStartEvent = "System.Net.Http.HttpRequestOut.Start"; private const string OnStopEvent = "System.Net.Http.HttpRequestOut.Stop"; private const string OnUnhandledExceptionEvent = "System.Net.Http.Exception"; diff --git a/test/OpenTelemetry.Instrumentation.Http.Tests/HttpClientTests.Basic.cs b/test/OpenTelemetry.Instrumentation.Http.Tests/HttpClientTests.Basic.cs index 6cab1e5b54..5addbd3e7e 100644 --- a/test/OpenTelemetry.Instrumentation.Http.Tests/HttpClientTests.Basic.cs +++ b/test/OpenTelemetry.Instrumentation.Http.Tests/HttpClientTests.Basic.cs @@ -385,7 +385,7 @@ public async Task ExportsSpansCreatedForRetries() [InlineData("Options", "OPTIONS", "Options")] [InlineData("Patch", "PATCH", "Patch")] [InlineData("Trace", "TRACE", "Trace")] - [InlineData("CUSTOM", "_OTHER", "CUSTOM")] // NET9 only sets "http.request.method_original" if the method is not a standard HTTP method. + [InlineData("CUSTOM", "_OTHER", "CUSTOM")] public async Task HttpRequestMethodIsSetOnActivityAsPerSpec(string originalMethod, string expectedMethod, string? expectedOriginalMethod) { var exportedItems = new List();