Skip to content

We use a batch size of 1 for network BDNs in order to stress the netw… #113

We use a batch size of 1 for network BDNs in order to stress the netw…

We use a batch size of 1 for network BDNs in order to stress the netw… #113

name: Garnet CI BDN.benchmark
on:
workflow_dispatch:
push:
branches:
- main
env:
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1
DOTNET_NOLOGO: true
permissions:
actions: write
deployments: write # permission to deploy GitHub pages website
contents: write # permission to update benchmark contents in continuousbenchmark branch
jobs:
changes:
name: Check for changes
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v4
- name: Apply filter
uses: dorny/paths-filter@v3
id: filter
with:
filters: |
website:
- 'website/**'
bdnbenchmark:
- '!((*.md)|(website/**))'
# Job to build and run BDN.benchmark
build-run-bdnbenchmark:
name: BDNBenchmark
needs: [changes]
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ ubuntu-latest, windows-latest ]
framework: [ 'net8.0' ]
configuration: [ 'Release' ]
test: [ 'Operations.BasicOperations', 'Operations.ObjectOperations', 'Operations.HashObjectOperations', 'Cluster.ClusterMigrate', 'Cluster.ClusterOperations', 'Lua.LuaScripts', 'Operations.CustomOperations', 'Operations.RawStringOperations', 'Operations.ScriptOperations','Network.BasicOperations', 'Network.RawStringOperations' ]
steps:
- name: Check out code
uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Install dependencies
run: dotnet restore
- name: Run BDN.benchmark Perf Test
run: ./test/BDNPerfTests/run_bdnperftest.ps1 ${{ matrix.test }}
shell: pwsh
continue-on-error: false
- name: Upload test results to artifacts
uses: actions/upload-artifact@v4
with:
name: Results-${{ matrix.os }}-${{ matrix.framework }}-${{ matrix.configuration }}-${{ matrix.test }}
path: |
./test/BDNPerfTests/results
if: ${{ always() }}
- name: Upload Error Log to artifacts
uses: actions/upload-artifact@v4
with:
name: ErrorLog-${{ matrix.os }}-${{ matrix.framework }}-${{ matrix.configuration }}-${{ matrix.test }}
path: |
./test/BDNPerfTests/errorlog
if: ${{ always() }}
# Run `github-action-benchmark` action for the Continuous Benchmarking Charts (https://microsoft.github.io/garnet/charts/)
- name: Store benchmark result for charts
uses: benchmark-action/github-action-benchmark@v1
with:
name: ${{matrix.test}} (${{matrix.os}} ${{matrix.framework}} ${{matrix.configuration}})
tool: 'benchmarkdotnet'
output-file-path: ./test/BDNPerfTests/BenchmarkDotNet.Artifacts/results/BDN.benchmark.${{ matrix.test }}-report-full-compressed.json
github-token: ${{ secrets.GITHUB_TOKEN }}
auto-push: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
save-data-file: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
summary-always: true
gh-pages-branch: 'continuousbenchmark'
benchmark-data-dir-path: 'website/static/charts'
max-items-in-chart: 50
alert-threshold: '110%'
comment-always: true
fail-on-alert: false