Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PartialSuccessTransmissionPolicy: Avoid unnecessary content deserializations #2446

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
21 changes: 12 additions & 9 deletions .github/workflows/build-and-test-BASE.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,32 @@
# Syntax: https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions
# .NET CLI: https://docs.microsoft.com/dotnet/core/tools/
# Description: The purpose of this build is to build and test on both Windows and Linux.
# Description: The purpose of this workflow is to compile and run unit tests.

name: Build And Test, BASE

on:
workflow_dispatch:
push:
branches: [ master, develop ]
branches: [ main ]
pull_request:
branches: [ master, develop ]
branches: [ main ]

jobs:
build-test-BASE:

runs-on: ${{ matrix.os }}

env:
SOLUTION: ./BASE/Microsoft.ApplicationInsights.sln

strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
framework: [netcoreapp3.1,net5.0,net6.0]
framework: [net452, net462, net472, net480, netcoreapp3.1, net5.0, net6.0]
include:
- os: ubuntu-latest
args: "--filter TestCategory!=WindowsOnly"
- os: ubuntu-latest
args: "--filter TestCategory!=WindowsOnly"

steps:
- uses: actions/checkout@v2
Expand All @@ -41,15 +44,15 @@ jobs:
dotnet-version: '6.0.x'

- name: Restore
run: dotnet restore ./BASE/Microsoft.ApplicationInsights.sln
run: dotnet restore ${{ env.SOLUTION }}

- name: Build
run: dotnet build ./BASE/Microsoft.ApplicationInsights.sln --configuration Release --no-restore
run: dotnet build ${{ env.SOLUTION }} --configuration Release --no-restore

- name: Test
id: test1
continue-on-error: true
run: dotnet test ./BASE/Microsoft.ApplicationInsights.sln --framework ${{ matrix.framework }} --configuration Release --no-build --logger:"console;verbosity=detailed" --logger:"trx;logfilename=${{ github.workspace }}/testResults.trx" ${{ matrix.args }}
run: dotnet test ${{ env.SOLUTION }} --framework ${{ matrix.framework }} --configuration Release --no-build --logger:"console;verbosity=detailed" --logger:"trx;logfilename=${{ github.workspace }}/testResults.trx" ${{ matrix.args }}

- name: Retry tests
if: steps.test1.outcome=='failure'
Expand Down
57 changes: 57 additions & 0 deletions .github/workflows/build-and-test-LOGGING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# Syntax: https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions
# .NET CLI: https://docs.microsoft.com/dotnet/core/tools/
# Description: The purpose of this workflow is to compile and run unit tests.

name: Build And Test, LOGGING

on:
workflow_dispatch:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
build-test-LOGGING:

runs-on: ${{ matrix.os }}

env:
SOLUTION: ./LOGGING/Logging.sln

strategy:
fail-fast: false
matrix:
os: [windows-latest]
framework: [net452, net462, net472, net480, netcoreapp3.1, net5.0, net6.0]

steps:
- uses: actions/checkout@v2

- uses: actions/setup-dotnet@v1
with:
dotnet-version: '3.1.x'

- uses: actions/setup-dotnet@v1
with:
dotnet-version: '5.0.x'

- uses: actions/setup-dotnet@v1
with:
dotnet-version: '6.0.x'

- name: Restore
run: dotnet restore ${{ env.SOLUTION }}

- name: Build
run: dotnet build ${{ env.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 --logger:"console;verbosity=detailed" --logger:"trx;logfilename=${{ github.workspace }}/testResults.trx" ${{ matrix.args }}

- name: Retry tests
if: steps.test1.outcome=='failure'
run: pwsh -f ./.scripts/build_RetryTests.ps1 -TestResultFile ${{ github.workspace }}/testResults.trx -WorkingDirectory ${{ github.workspace }}

22 changes: 13 additions & 9 deletions .github/workflows/build-and-test-NETCORE.yml
Original file line number Diff line number Diff line change
@@ -1,28 +1,32 @@
# Syntax: https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions
# .NET CLI: https://docs.microsoft.com/dotnet/core/tools/
# Description: The purpose of this build is to build and test on both Windows and Linux.
# Description: The purpose of this workflow is to compile and run unit tests.

name: Build And Test, NETCORE

on:
workflow_dispatch:
push:
branches: [ master, develop ]
branches: [ main ]
pull_request:
branches: [ master, develop ]
branches: [ main ]

jobs:
build-test-NETCORE:

runs-on: ${{ matrix.os }}

env:
SOLUTION: ./NETCORE/ApplicationInsights.AspNetCore.sln

strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
framework: [netcoreapp3.1,net5.0,net6.0]
framework: [net452, net462, net472, net480, netcoreapp3.1, net5.0, net6.0]
include:
- os: ubuntu-latest
args: "--filter TestCategory!=WindowsOnly"
- os: ubuntu-latest
args: "--filter TestCategory!=WindowsOnly"

steps:
- uses: actions/checkout@v2
Expand All @@ -40,15 +44,15 @@ jobs:
dotnet-version: '6.0.x'

- name: Restore
run: dotnet restore ./NETCORE/ApplicationInsights.AspNetCore.sln
run: dotnet restore ${{ env.SOLUTION }}

- name: Build
run: dotnet build ./NETCORE/ApplicationInsights.AspNetCore.sln --configuration Release --no-restore
run: dotnet build ${{ env.SOLUTION }} --configuration Release --no-restore

- name: Test
id: test1
continue-on-error: true
run: dotnet test ./NETCORE/ApplicationInsights.AspNetCore.sln --framework ${{ matrix.framework }} --configuration Release --no-build --logger:"console;verbosity=detailed" --logger:"trx;logfilename=${{ github.workspace }}/testResults.trx" ${{ matrix.args }}
run: dotnet test ${{ env.SOLUTION }} --framework ${{ matrix.framework }} --configuration Release --no-build --logger:"console;verbosity=detailed" --logger:"trx;logfilename=${{ github.workspace }}/testResults.trx" ${{ matrix.args }}

- name: Retry tests
if: steps.test1.outcome=='failure'
Expand Down
57 changes: 57 additions & 0 deletions .github/workflows/build-and-test-WEB.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# Syntax: https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions
# .NET CLI: https://docs.microsoft.com/dotnet/core/tools/
# Description: The purpose of this workflow is to compile and run unit tests.

name: Build And Test, WEB

on:
workflow_dispatch:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
build-test-WEB:

runs-on: ${{ matrix.os }}

env:
SOLUTION: ./WEB/Src/Microsoft.ApplicationInsights.Web.sln

strategy:
fail-fast: false
matrix:
os: [windows-latest]
framework: [net452, net462, net472, net480, netcoreapp3.1, net5.0, net6.0]

steps:
- uses: actions/checkout@v2

- uses: actions/setup-dotnet@v1
with:
dotnet-version: '3.1.x'

- uses: actions/setup-dotnet@v1
with:
dotnet-version: '5.0.x'

- uses: actions/setup-dotnet@v1
with:
dotnet-version: '6.0.x'

- name: Restore
run: dotnet restore ${{ env.SOLUTION }}

- name: Build
run: dotnet build ${{ env.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 --logger:"console;verbosity=detailed" --logger:"trx;logfilename=${{ github.workspace }}/testResults.trx" ${{ matrix.args }}

- name: Retry tests
if: steps.test1.outcome=='failure'
run: pwsh -f ./.scripts/build_RetryTests.ps1 -TestResultFile ${{ github.workspace }}/testResults.trx -WorkingDirectory ${{ github.workspace }}

29 changes: 0 additions & 29 deletions .github/workflows/examples-sanity.yml

This file was deleted.

10 changes: 5 additions & 5 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Syntax: https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions
# .NET CLI: https://docs.microsoft.com/dotnet/core/tools/
# Description: The purpose of this workflow is to build the DEVELOP branch and push to MyGet.
# Description: The purpose of this workflow is to build the MAIN branch and push to MyGet.

name: Nightly

Expand All @@ -18,7 +18,7 @@ jobs:
fail-fast: false
matrix:
os: [windows-latest]
branch: [develop]
branch: [main]
solution: [./ProjectsForSigning.sln]

steps:
Expand Down Expand Up @@ -48,11 +48,11 @@ jobs:
- name: Build
run: dotnet build -p:NightlyBuild=True -p:PublicRelease=True ${{ matrix.solution }} --configuration Release --no-restore

- name: Find nuget directory # Find path of 'bin/release/nuget'
- name: Find nuget directory # Find path of 'bin/release/nuget' and assign to environment variable
shell: pwsh
run: |
$dir = Join-Path (Get-Item '${{ github.workspace }}').Parent "bin/Release/NuGet"
Write-Host "Found directory: '$dir'"
$dir = "./bin/Release/NuGet"
Test-Path $dir -PathType Container
echo "NUGET_DIRECTORY=$dir" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf-8 -Append

- name: List files
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/redfield-sanity-check.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
# Syntax: https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions
# .NET CLI: https://docs.microsoft.com/dotnet/core/tools/
# Description: The purpose of this build is to compile and test with redfield flag.
# Description: The purpose of this workflow is to compile and run unit tests with redfield flag.

name: Redfield Validation

on:
workflow_dispatch:
push:
branches: [ master, develop ]
branches: [ main ]
pull_request:
branches: [ master, develop ]
branches: [ main ]

jobs:
build-test-REDFIELD:
Expand Down
42 changes: 42 additions & 0 deletions .github/workflows/sanity.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# Syntax: https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions
# .NET CLI: https://docs.microsoft.com/dotnet/core/tools/
# Description: The purpose of this workflow is to verify that every solution in the repo successfully compiles.

name: Sanity Build

on:
workflow_dispatch:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
sanity-build:

runs-on: windows-latest

strategy:
fail-fast: false
matrix:
solution: [
./NETCORE/ApplicationInsights.AspNetCore.sln,
./Everything.sln,
./examples/Examples.sln,
./IntegrationTests.sln,
./LOGGING/Logging.sln,
./BASE/Microsoft.ApplicationInsights.sln,
./WEB/Src/Microsoft.ApplicationInsights.Web.sln]

steps:
- uses: actions/checkout@v2

- uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.x

- name: Restore
run: dotnet restore ${{ matrix.solution }}

- name: Build
run: dotnet build ${{ matrix.solution }}
3 changes: 3 additions & 0 deletions .pipelines/00_helloworld.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
cd /D "%~dp0..\"

echo hello world: %* || exit /b 1
3 changes: 3 additions & 0 deletions .pipelines/00_list_versions.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
cd /D "%~dp0..\"

dotnet --version && dotnet --list-sdks && dotnet --list-runtimes || exit /b 1
3 changes: 3 additions & 0 deletions .pipelines/01_restore.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
cd /D "%~dp0..\"

dotnet restore .\ProjectsForSigning.sln || exit /b 1
3 changes: 3 additions & 0 deletions .pipelines/02_build.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
cd /D "%~dp0..\"

dotnet build .\ProjectsForSigning.sln %* --configuration Release --no-restore || exit /b 1
9 changes: 9 additions & 0 deletions .pipelines/03_pack.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
cd /D "%~dp0..\"

dotnet pack .\ProjectsForSigning.sln %* --configuration Release --no-restore --no-build || exit /b 1


setlocal enabledelayedexpansion
powershell.exe -ExecutionPolicy Unrestricted -NoProfile -WindowStyle Hidden -File "./.scripts/release_GenerateReleaseMetadata.ps1" -artifactsPath "./bin/Release/NuGet" -sourcePath "./" -outPath "./bin/Release/NuGet"
endlocal
exit /B %ERRORLEVEL%
4 changes: 4 additions & 0 deletions .pipelines/04_test.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
cd /D "%~dp0..\"

echo "TODO: VALIDATE SIGNED DLLs."
echo "TODO: VALIDATE SIGNED NUPKGs."
Loading