Skip to content

feat: add load-test payload worker for base-load-test integration #5

feat: add load-test payload worker for base-load-test integration

feat: add load-test payload worker for base-load-test integration #5

Workflow file for this run

name: Load Test
on:
pull_request:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
build-binaries:
name: Build binaries
uses: ./.github/workflows/_build-binaries.yaml
with:
base_reth_node_version: feature/load-test-benchmark
load-test:
name: Run load test benchmark
runs-on: ubuntu-latest
needs: [build-binaries]
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12.1
with:
egress-policy: audit
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up Go
uses: actions/setup-go@4dc6199c7b1a012772edbd06daecab0f50c9053c # v6.1.0
- name: Download base-reth-node
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
name: base-reth-node
path: ${{ runner.temp }}/bin/
- name: Download builder
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
name: builder
path: ${{ runner.temp }}/bin/
- name: Download base-load-test
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
name: base-load-test
path: ${{ runner.temp }}/bin/
- name: Make binaries executable
run: chmod +x ${{ runner.temp }}/bin/*
- name: Run load test benchmark
run: |
mkdir -p ${{ runner.temp }}/data-dir
mkdir -p ${{ runner.temp }}/output
go run benchmark/cmd/main.go \
--log.level info \
run \
--config configs/examples/load-test.yml \
--root-dir ${{ runner.temp }}/data-dir \
--output-dir ${{ runner.temp }}/output \
--builder-bin ${{ runner.temp }}/bin/builder \
--base-reth-node-bin ${{ runner.temp }}/bin/base-reth-node \
--load-test-bin ${{ runner.temp }}/bin/base-load-test
- name: Setup Node.js
if: always()
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
node-version: "20"
- name: Build Report
if: always()
run: |
cp -r ${{ runner.temp }}/output/ ./output/ || true
pushd report
npm install
npm run build
popd
- name: Upload Output
if: always()
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
with:
name: load-test-output
path: ${{ runner.temp }}/output/
retention-days: 7
- name: Upload Report
if: always()
uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4.5.0
with:
name: load-test-report
path: report/dist/
retention-days: 7