Repository navigation
fix(adapter-pg): map commit-time write conflicts to P2034 #25955
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Benchmark | |
| # Run on `push` only for main, if not it will trigger `push` & `pull_request` on PRs at the same time | |
| on: | |
| push: | |
| branches: | |
| - v7 | |
| - '*.*.x' | |
| paths-ignore: | |
| # Any update here needs to be done for `pull_request` (see below) and all files | |
| # (test.yml, benchmark.yml, publish.yml, bundle-size.yml, ci-aux-files.yml) | |
| - '*.md' | |
| # - '*.bench.ts' -> should not be ignored in this workflow | |
| - 'LICENSE' | |
| - '.dockerignore' | |
| - 'scripts/ci/publish.ts' | |
| - '.github/CODEOWNERS' | |
| - '.github/ISSUE_TEMPLATE/**' | |
| - '.github/DISCUSSION_TEMPLATE/**' | |
| - '.devcontainer/**' | |
| - '.vscode/**' | |
| - 'graphs/**' | |
| - 'sandbox/**' | |
| pull_request: | |
| paths-ignore: | |
| # Any update here needs to be done for `branches` (see above) and all files | |
| # (test.yml, benchmark.yml, publish.yml, bundle-size.yml, ci-aux-files.yml) | |
| - '*.md' | |
| # - '*.bench.ts' -> should not be ignored in this workflow | |
| - 'LICENSE' | |
| - '.dockerignore' | |
| - 'scripts/ci/publish.ts' | |
| - '.github/CODEOWNERS' | |
| - '.github/ISSUE_TEMPLATE/**' | |
| - '.github/DISCUSSION_TEMPLATE/**' | |
| - '.devcontainer/**' | |
| - '.vscode/**' | |
| - 'graphs/**' | |
| - 'sandbox/**' | |
| workflow_dispatch: | |
| env: | |
| PRISMA_TELEMETRY_INFORMATION: 'prisma benchmark.yml' | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| benchmark: | |
| name: Benchmark | |
| runs-on: ubuntu-latest | |
| # Only run on the main repo (not on forks): neither the CodSpeed token nor write | |
| # access to the `gh-pages` benchmark history is available to a fork. | |
| if: github.repository == 'prisma/orm' | |
| steps: | |
| - uses: actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0 | |
| - name: Install & build | |
| uses: ./.github/actions/setup | |
| with: | |
| node-version: '20.19.0' | |
| skip-tsc: false | |
| - name: Run benchmarks | |
| run: pnpm run bench | |
| - name: Store benchmark result | |
| if: ${{ github.ref == 'refs/heads/v7' }} | |
| uses: rhysd/github-action-benchmark@52576c92bccf6ac60c8223ec7eb2565637cae9ba # v1.22.1 | |
| with: | |
| name: Benchmark.js Benchmark | |
| tool: 'benchmarkjs' | |
| output-file-path: output.txt | |
| # Note: must use personal access token | |
| github-token: ${{ secrets.GITHUB_TOKEN }} | |
| auto-push: true | |
| # This step only records history for the chart at | |
| # https://prisma.github.io/prisma/dev/bench/. Alerting stays off because the | |
| # wall-clock throughput of GitHub-hosted runners varies by more than 2x between | |
| # jobs, which is wider than the spread this comparison would need to resolve: it | |
| # compares a commit against its immediate predecessor only, so a fast runner on | |
| # one commit manufactures an alert on the next, while a genuine regression | |
| # smaller than the machine-to-machine spread goes unreported. The CodSpeed step | |
| # below measures the same benchmarks under simulation and owns regression | |
| # detection. | |
| comment-on-alert: false | |
| fail-on-alert: false | |
| - name: Run benchmarks for Codspeed | |
| uses: CodSpeedHQ/action@f22792bfac16f3e14eb9fbea76f4a48e9cc22b93 # v4.19.1 | |
| with: | |
| mode: simulation | |
| run: pnpm run bench-stdout-only | |
| token: ${{ secrets.CODSPEED_TOKEN }} | |
| env: | |
| CODSPEED_BENCHMARK: true |