Skip to content

Commit

Permalink
[HttpClient & ASP.NET Core] Change metric descriptions as per spec (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
vishweshbankwar committed Oct 26, 2023
1 parent f7b4ae1 commit 74ad003
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
4 changes: 4 additions & 0 deletions src/OpenTelemetry.Instrumentation.AspNetCore/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,10 @@ to `http` or `http/dup`.
> The [View API](https://github.com/open-telemetry/opentelemetry-dotnet/tree/main/docs/metrics/customizing-the-sdk#select-specific-tags)
may be used to drop dimensions.

* Updated description for `http.server.request.duration` metrics to match spec
definition.
([#4990](https://github.com/open-telemetry/opentelemetry-dotnet/pull/4990))

## 1.5.1-beta.1

Released 2023-Jul-20
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ internal HttpInMetricsListener(string name, Meter meter, AspNetCoreMetricsInstru

if (this.emitNewAttributes)
{
this.httpServerRequestDuration = meter.CreateHistogram<double>(HttpServerRequestDurationMetricName, "s", "Measures the duration of inbound HTTP requests.");
this.httpServerRequestDuration = meter.CreateHistogram<double>(HttpServerRequestDurationMetricName, "s", "Duration of HTTP server requests.");
}
}

Expand Down
6 changes: 5 additions & 1 deletion src/OpenTelemetry.Instrumentation.Http/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,15 @@

([#4931](https://github.com/open-telemetry/opentelemetry-dotnet/pull/4931))

* Added `url.scheme` attribute to `http.client.request.duration` metric. The
* Added `url.scheme` attribute to `http.client.request.duration` metric. The
metric will be emitted when `OTEL_SEMCONV_STABILITY_OPT_IN` environment
variable is set to `http` or `http/dup`.
([#4989](https://github.com/open-telemetry/opentelemetry-dotnet/pull/4989))

* Updated description for `http.client.request.duration` metrics to match spec
definition.
([#4990](https://github.com/open-telemetry/opentelemetry-dotnet/pull/4990))

## 1.5.1-beta.1

Released 2023-Jul-20
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ internal sealed class HttpHandlerMetricsDiagnosticListener : ListenerHandler
internal static readonly string MeterVersion = AssemblyName.Version.ToString();
internal static readonly Meter Meter = new(MeterName, MeterVersion);
private static readonly Histogram<double> HttpClientDuration = Meter.CreateHistogram<double>("http.client.duration", "ms", "Measures the duration of outbound HTTP requests.");
private static readonly Histogram<double> HttpClientRequestDuration = Meter.CreateHistogram<double>("http.client.request.duration", "s", "Measures the duration of outbound HTTP requests.");
private static readonly Histogram<double> HttpClientRequestDuration = Meter.CreateHistogram<double>("http.client.request.duration", "s", "Duration of HTTP client requests.");

private static readonly PropertyFetcher<HttpRequestMessage> StopRequestFetcher = new("Request");
private static readonly PropertyFetcher<HttpResponseMessage> StopResponseFetcher = new("Response");
Expand Down

0 comments on commit 74ad003

Please sign in to comment.