github open-telemetry/opentelemetry-dotnet 1.6.0-beta.2
1.6.0-beta.2 of instrumentation libraries

pre-release12 months ago

OpenTelemetry.Instrumentation.AspNetCore

This new metric is only available for users who opt-in to the new semantic convention by configuring the OTEL_SEMCONV_STABILITY_OPT_IN environment variable to either http (to emit only the new metric) or http/dup (to emit both the new and old metrics). (#4802)

  • New metric: http.server.request.duration
    • Unit: s (seconds)
    • Histogram Buckets: 0, 0.005, 0.01, 0.025, 0.05, 0.075, 0.1, 0.25, 0.5, 0.75, 1, 2.5, 5, 7.5, 10
  • Old metric: http.server.duration
    • Unit: ms (milliseconds)
    • Histogram Buckets: 0, 5, 10, 25, 50, 75, 100, 250, 500, 750, 1000, 2500, 5000, 7500, 10000

Note: the older http.server.duration metric and OTEL_SEMCONV_STABILITY_OPT_IN environment variable will eventually be removed after the HTTP semantic conventions are marked stable. At which time this instrumentation can publish a stable release. Refer to the specification for more information regarding the new HTTP semantic conventions for both spans and metrics.

  • Following metrics will now be enabled by default when targeting .NET8.0 or newer framework:

    • Meter : Microsoft.AspNetCore.Hosting

      • http.server.request.duration
      • http.server.active_requests
    • Meter : Microsoft.AspNetCore.Server.Kestrel

      • kestrel.active_connections
      • kestrel.connection.duration
      • kestrel.rejected_connections
      • kestrel.queued_connections
      • kestrel.queued_requests
      • kestrel.upgraded_connections
      • kestrel.tls_handshake.duration
      • kestrel.active_tls_handshakes
    • Meter : Microsoft.AspNetCore.Http.Connections

      • signalr.server.connection.duration
      • signalr.server.active_connections
    • Meter : Microsoft.AspNetCore.Routing

      • aspnetcore.routing.match_attempts
    • Meter : Microsoft.AspNetCore.Diagnostics

      • aspnetcore.diagnostics.exceptions
    • Meter : Microsoft.AspNetCore.RateLimiting

      • aspnetcore.rate_limiting.active_request_leases
      • aspnetcore.rate_limiting.request_lease.duration
      • aspnetcore.rate_limiting.queued_requests
      • aspnetcore.rate_limiting.request.time_in_queue
      • aspnetcore.rate_limiting.requests

    For details about each individual metric check ASP.NET Core docs page.

    NOTES:

    • When targeting .NET8.0 framework or newer, http.server.request.duration metric will only follow v1.22.0 semantic conventions specification. Ability to switch behavior to older conventions using OTEL_SEMCONV_STABILITY_OPT_IN environment variable is not available.
    • Users can opt-out of metrics that are not required using views.
      (#4934)
  • Added network.protocol.name dimension to http.server.request.duration metric. This change only affects users setting OTEL_SEMCONV_STABILITY_OPT_IN to http or http/dup. (#4934)

  • Breaking: Removed Enrich and Filter support for metrics instrumentation. With this change, AspNetCoreMetricsInstrumentationOptions is no longer available. (#4981)

    • Enrich migration:

      An enrichment API for the http.server.request.duration metric is available inside AspNetCore for users targeting .NET 8.0 (or newer). For details see: Enrich the ASP.NET Core request
      metric
      .

    • Filter migration:

      There is no comparable filter mechanism currently available for any .NET version. Please share your feedback if you are impacted by this feature gap.

      Note
      The View API may be used to drop dimensions.

  • Updated description for http.server.request.duration metrics to match spec definition. (#4990)

OpenTelemetry.Instrumentation.Http

This new metric is only available for users who opt-in to the new semantic convention by configuring the OTEL_SEMCONV_STABILITY_OPT_IN environment variable to either http (to emit only the new metric) or http/dup (to emit both the new and old metrics). (#4870)

  • New metric: http.client.request.duration
    • Unit: s (seconds)
    • Histogram Buckets: 0, 0.005, 0.01, 0.025, 0.05, 0.075, 0.1, 0.25, 0.5, 0.75, 1, 2.5, 5, 7.5, 10
  • Old metric: http.client.duration
    • Unit: ms (milliseconds)
    • Histogram Buckets: 0, 5, 10, 25, 50, 75, 100, 250, 500, 750, 1000, 2500, 5000, 7500, 10000

Note: The older http.client.duration metric and OTEL_SEMCONV_STABILITY_OPT_IN environment variable will eventually be removed after the HTTP semantic conventions are marked stable. At which time this instrumentation can publish a stable release. Refer to the specification for more information regarding the new HTTP semantic conventions:

  • http-spans

  • http-metrics

  • Added support for publishing http.client.duration & http.client.request.duration metrics on .NET Framework for HttpWebRequest. (#4870)

  • Following HttpClient metrics will now be enabled by default when targeting .NET8.0 framework or newer.

    • Meter : System.Net.Http

      • http.client.request.duration
      • http.client.active_requests
      • http.client.open_connections
      • http.client.connection.duration
      • http.client.request.time_in_queue
    • Meter : System.Net.NameResolution

      • dns.lookups.duration

    For details about each individual metric check System.Net metrics docs page.

    NOTES:

    • When targeting .NET8.0 framework or newer, http.client.request.duration metric will only follow v1.22.0 semantic conventions specification. Ability to switch behavior to older conventions using OTEL_SEMCONV_STABILITY_OPT_IN environment variable is
      not available.
    • Users can opt-out of metrics that are not required using views.
      (#4931)
  • 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)

  • Updated description for http.client.request.duration metrics to match spec definition. (#4990)

Don't miss a new opentelemetry-dotnet release

NewReleases is sending notifications on new releases.