Skip to content

Commit

Permalink
Update minimum target framework from net461 to net462 (#226)
Browse files Browse the repository at this point in the history
upstream instrumentation updated theirs since net461 was end of lifed in April 2022
  • Loading branch information
vreynolds authored Aug 3, 2022
1 parent 5730151 commit b946052
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions src/Honeycomb.OpenTelemetry/Honeycomb.OpenTelemetry.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>netstandard2.0;netstandard2.1;net461</TargetFrameworks>
<TargetFrameworks>netstandard2.0;netstandard2.1;net462</TargetFrameworks>
<GenerateDocumentationFile>true</GenerateDocumentationFile>

<!-- For SourceLink. See: https://github.com/dotnet/sourcelink#using-source-link-in-net-projects -->
Expand Down Expand Up @@ -39,7 +39,7 @@
</ItemGroup>

<Choose>
<When Condition=" '$(TargetFramework)' == 'net461' ">
<When Condition=" '$(TargetFramework)' == 'net462' ">
<ItemGroup>
<PackageReference Include="Microsoft.AspNet.WebApi" Version="5.2.7" />
<PackageReference Include="OpenTelemetry.Instrumentation.AspNet" Version="1.0.0-rc9.1" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
using OpenTelemetry.Trace;
using System;

#if NET461
#if NET462
using System.Collections.Generic;
#endif

Expand Down Expand Up @@ -88,7 +88,7 @@ public static TracerProviderBuilder AddHoneycomb(this TracerProviderBuilder buil

if (options.InstrumentHttpClient)
{
#if NET461
#if NET462
builder.AddHttpClientInstrumentation();
#else
builder.AddHttpClientInstrumentation(options.ConfigureHttpClientInstrumentationOptions);
Expand All @@ -106,7 +106,7 @@ public static TracerProviderBuilder AddHoneycomb(this TracerProviderBuilder buil
options.ConfigureStackExchangeRedisClientInstrumentationOptions);
}

#if NET461
#if NET462
builder.AddAspNetInstrumentation(opts =>
opts.Enrich = (activity, eventName, _) =>
{
Expand Down

0 comments on commit b946052

Please sign in to comment.