From b2936b0cd64e1b119f2ffbb0e2b2b2262786168e Mon Sep 17 00:00:00 2001 From: Henrik Ingo Date: Mon, 20 Jan 2025 04:49:52 +0200 Subject: [PATCH 1/3] =?UTF-8?q?Add=20Nyrki=C3=B6=20change=20point=20detect?= =?UTF-8?q?ion=20to=20'cargo=20bench'=20workflow?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This adds a separate push-only.yml workflow. For now pull request API wasn't integrated yet, so shouldn't run on PRs. --- .github/workflows/push_only.yml | 34 +++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .github/workflows/push_only.yml diff --git a/.github/workflows/push_only.yml b/.github/workflows/push_only.yml new file mode 100644 index 000000000..5126b6d03 --- /dev/null +++ b/.github/workflows/push_only.yml @@ -0,0 +1,34 @@ +name: Benchmarks+Nyrkiö + +# Pull request support isn't integrated to the github-action-benchmark so run only post-merge +on: + push: + branches: [ "main" ] + +env: + CARGO_TERM_COLOR: always + +jobs: + bench: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Bench + run: cargo bench | tee output.txt + + - name: Analyze benchmark result with Nyrkiö + uses: nyrkio/github-action-benchmark@v1 + with: + name: turso + tool: criterion + output-file-path: output.txt + fail-on-alert: true + # Nyrkiö configuration + nyrkio-enable: true + # Get yours from https://nyrkio.com/docs/getting-started + nyrkio-token: ${{ secrets.NYRKIO_JWT_TOKEN }} + + # Old way... + # Explicitly set this to null. We don't want threshold based alerts today. + external-data-json-path: null + gh-repository: null From b87b80a422d616e15891ab6b7dd01dd9ea80dc18 Mon Sep 17 00:00:00 2001 From: Henrik Ingo Date: Mon, 20 Jan 2025 05:12:32 +0200 Subject: [PATCH 2/3] Remove version from github-action-benchmark. For now. --- .github/workflows/push_only.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push_only.yml b/.github/workflows/push_only.yml index 5126b6d03..90e91648a 100644 --- a/.github/workflows/push_only.yml +++ b/.github/workflows/push_only.yml @@ -17,7 +17,7 @@ jobs: run: cargo bench | tee output.txt - name: Analyze benchmark result with Nyrkiö - uses: nyrkio/github-action-benchmark@v1 + uses: nyrkio/github-action-benchmark with: name: turso tool: criterion From ea0b1c3f2ae05ae5517534c830fa29001eb707c9 Mon Sep 17 00:00:00 2001 From: Henrik Ingo Date: Mon, 20 Jan 2025 05:17:22 +0200 Subject: [PATCH 3/3] Needs a speicif git sha if not version --- .github/workflows/push_only.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/push_only.yml b/.github/workflows/push_only.yml index 90e91648a..504417c12 100644 --- a/.github/workflows/push_only.yml +++ b/.github/workflows/push_only.yml @@ -17,7 +17,7 @@ jobs: run: cargo bench | tee output.txt - name: Analyze benchmark result with Nyrkiö - uses: nyrkio/github-action-benchmark + uses: nyrkio/github-action-benchmark@ec6fe57 with: name: turso tool: criterion