diff --git a/.github/workflows/build-and-test-SHIM.yml b/.github/workflows/build-and-test-SHIM.yml index b86b850ce..e41efbb8f 100644 --- a/.github/workflows/build-and-test-SHIM.yml +++ b/.github/workflows/build-and-test-SHIM.yml @@ -17,17 +17,29 @@ jobs: runs-on: ${{ matrix.os }} env: - SOLUTION: ./Everything.sln TEST_RESULTS_DIRECTORY: ${{ github.workspace }}/TestResults strategy: fail-fast: false matrix: os: [ubuntu-latest, windows-latest] - framework: [net462, net472, net480, net481, net8.0, net9.0, net10.0] + framework: [net8.0, net9.0, net10.0, net462, net472, net480, net481] + exclude: + # .NET Framework doesn't run on Linux + - os: ubuntu-latest + framework: net462 + - os: ubuntu-latest + framework: net472 + - os: ubuntu-latest + framework: net480 + - os: ubuntu-latest + framework: net481 include: - os: ubuntu-latest args: "--filter TestCategory!=WindowsOnly" + solution: ./Everything.Linux.slnf + - os: windows-latest + solution: ./Everything.Windows.slnf steps: - uses: actions/checkout@v6 @@ -44,15 +56,15 @@ jobs: 10.0.x - name: Restore - run: dotnet restore ${{ env.SOLUTION }} + run: dotnet restore ${{ matrix.solution }} - name: Build - run: dotnet build ${{ env.SOLUTION }} --configuration Release --no-restore + run: dotnet build ${{ matrix.solution }} --configuration Release --no-restore - name: Test id: test1 continue-on-error: true - run: dotnet test ${{ env.SOLUTION }} --framework ${{ matrix.framework }} --configuration Release --no-build --results-directory ${{ env.TEST_RESULTS_DIRECTORY }} --logger:"console;verbosity=detailed" --logger:"trx;logfileprefix=testResults_" ${{ matrix.args }} + run: dotnet test ${{ matrix.solution }} --framework ${{ matrix.framework }} --configuration Release --no-build --results-directory ${{ env.TEST_RESULTS_DIRECTORY }} --logger:"console;verbosity=detailed" --logger:"trx;logfileprefix=testResults_" ${{ matrix.args }} - name: Retry tests if: steps.test1.outcome=='failure' diff --git a/BASE/src/Microsoft.ApplicationInsights/Microsoft.ApplicationInsights.csproj b/BASE/src/Microsoft.ApplicationInsights/Microsoft.ApplicationInsights.csproj index 766540a7f..6649471f8 100644 --- a/BASE/src/Microsoft.ApplicationInsights/Microsoft.ApplicationInsights.csproj +++ b/BASE/src/Microsoft.ApplicationInsights/Microsoft.ApplicationInsights.csproj @@ -4,8 +4,8 @@ Microsoft.ApplicationInsights Microsoft.ApplicationInsights - net10.0;net9.0;net8.0;netstandard2.0;net462 - netstandard2.0;net8.0;net9.0;net10.0 + net10.0;net9.0;net8.0;net462 + net8.0;net9.0;net10.0 9.0 @@ -31,10 +31,9 @@ All - - + diff --git a/CHANGELOG.md b/CHANGELOG.md index c4d539472..b48d7b23b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ## Unreleased +- [Removed `netstandard2.0` target framework from `Microsoft.ApplicationInsights`, `Microsoft.ApplicationInsights.AspNetCore`, and `Microsoft.ApplicationInsights.WorkerService` packages.](https://github.com/microsoft/ApplicationInsights-dotnet/pull/3091) - [The JavaScript in `Microsoft.ApplicationInsights.AspNetCore` has been updated to version 10.](https://github.com/microsoft/ApplicationInsights-dotnet/pull/3078) - [Centralized package version management](https://github.com/microsoft/ApplicationInsights-dotnet/pull/3080) - [Update OpenTelemetry dependencies](https://github.com/microsoft/ApplicationInsights-dotnet/pull/3080), [#3092](https://github.com/microsoft/ApplicationInsights-dotnet/pull/3092) diff --git a/Everything.Linux.slnf b/Everything.Linux.slnf new file mode 100644 index 000000000..bc4ec5274 --- /dev/null +++ b/Everything.Linux.slnf @@ -0,0 +1,17 @@ +{ + "solution": { + "path": "Everything.sln", + "projects": [ + "BASE\\src\\Microsoft.ApplicationInsights\\Microsoft.ApplicationInsights.csproj", + "examples\\BasicConsoleApp\\BasicConsoleApp.csproj", + "examples\\AspNetCoreWebApp\\AspNetCoreWebApp.csproj", + "examples\\WorkerService\\WorkerService.csproj", + "NETCORE\\src\\Microsoft.ApplicationInsights.AspNetCore\\Microsoft.ApplicationInsights.AspNetCore.csproj", + "NETCORE\\src\\Microsoft.ApplicationInsights.WorkerService\\Microsoft.ApplicationInsights.WorkerService.csproj", + "NETCORE\\test\\IntegrationTests.WebApp\\IntegrationTests.WebApp.csproj", + "NETCORE\\test\\IntegrationTests.WorkerApp\\IntegrationTests.WorkerApp.csproj", + "NETCORE\\test\\IntegrationTests.Tests\\IntegrationTests.Tests.csproj", + "NETCORE\\test\\WorkerIntegrationTests.Tests\\WorkerIntegrationTests.Tests.csproj" + ] + } +} diff --git a/Everything.Windows.slnf b/Everything.Windows.slnf new file mode 100644 index 000000000..27e5862d9 --- /dev/null +++ b/Everything.Windows.slnf @@ -0,0 +1,23 @@ +{ + "solution": { + "path": "Everything.sln", + "projects": [ + "BASE\\src\\Microsoft.ApplicationInsights\\Microsoft.ApplicationInsights.csproj", + "BASE\\Test\\Microsoft.ApplicationInsights.Test\\Microsoft.ApplicationInsights.Tests\\Microsoft.ApplicationInsights.Tests.csproj", + "examples\\BasicConsoleApp\\BasicConsoleApp.csproj", + "examples\\NLogConsoleApp\\NLogConsoleApp.csproj", + "examples\\AspNetCoreWebApp\\AspNetCoreWebApp.csproj", + "examples\\WorkerService\\WorkerService.csproj", + "LOGGING\\src\\NLogTarget\\NLogTarget.csproj", + "LOGGING\\test\\NLogTarget.Tests\\NLogTarget.Tests.csproj", + "NETCORE\\src\\Microsoft.ApplicationInsights.AspNetCore\\Microsoft.ApplicationInsights.AspNetCore.csproj", + "NETCORE\\src\\Microsoft.ApplicationInsights.WorkerService\\Microsoft.ApplicationInsights.WorkerService.csproj", + "NETCORE\\test\\IntegrationTests.WebApp\\IntegrationTests.WebApp.csproj", + "NETCORE\\test\\IntegrationTests.WorkerApp\\IntegrationTests.WorkerApp.csproj", + "NETCORE\\test\\IntegrationTests.Tests\\IntegrationTests.Tests.csproj", + "NETCORE\\test\\WorkerIntegrationTests.Tests\\WorkerIntegrationTests.Tests.csproj", + "WEB\\Src\\Web\\Web\\Web.csproj", + "WEB\\Src\\Web\\Web.Tests\\Web.Tests.csproj" + ] + } +} diff --git a/NETCORE/src/Microsoft.ApplicationInsights.AspNetCore/Microsoft.ApplicationInsights.AspNetCore.csproj b/NETCORE/src/Microsoft.ApplicationInsights.AspNetCore/Microsoft.ApplicationInsights.AspNetCore.csproj index a4c6afce7..ae9f56bf1 100644 --- a/NETCORE/src/Microsoft.ApplicationInsights.AspNetCore/Microsoft.ApplicationInsights.AspNetCore.csproj +++ b/NETCORE/src/Microsoft.ApplicationInsights.AspNetCore/Microsoft.ApplicationInsights.AspNetCore.csproj @@ -3,9 +3,7 @@ Microsoft.ApplicationInsights.AspNetCore - net10.0;net9.0;net8.0;netstandard2.0; - - netstandard2.0 + net10.0;net9.0;net8.0 $(DefineConstants);AI_ASPNETCORE_WEB; true @@ -19,10 +17,6 @@ $(PackageTags)aspnetcore; - - 1701;1702 - - diff --git a/NETCORE/src/Microsoft.ApplicationInsights.WorkerService/Microsoft.ApplicationInsights.WorkerService.csproj b/NETCORE/src/Microsoft.ApplicationInsights.WorkerService/Microsoft.ApplicationInsights.WorkerService.csproj index b16a59443..18e56a133 100644 --- a/NETCORE/src/Microsoft.ApplicationInsights.WorkerService/Microsoft.ApplicationInsights.WorkerService.csproj +++ b/NETCORE/src/Microsoft.ApplicationInsights.WorkerService/Microsoft.ApplicationInsights.WorkerService.csproj @@ -3,7 +3,7 @@ Microsoft.ApplicationInsights.WorkerService - net10.0;net9.0;net8.0;netstandard2.0; + net10.0;net9.0;net8.0 $(DefineConstants);AI_ASPNETCORE_WORKER;