Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 44 additions & 0 deletions .github/workflows/stresshouse-benchmark-compare.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Benchmark this PR's build vs `main` on StressHouse and comment the comparison
# on the PR.
#
# Thin caller: the logic lives in the shared reusable workflow
# ClickHouse/integrations-shared-workflows/.github/workflows/clickhouse-benchmark.yml,
# so behaviour can be adjusted in one place. It uses the Workflow Auth app to
# start the central `StressHouse dispatch` workflow in
# ClickHouse/clickhouse-client-benchmarks; when the run finishes, StressHouse
# posts a sticky comparison comment back onto this PR.
#
# Trigger: a `/benchmark-compare` PR comment from a maintainer, or manually from
# the Actions tab (supply the PR number).
---
name: StressHouse Benchmark (PR vs main)

on:
issue_comment:
types: [created]
workflow_dispatch:
inputs:
pr_number:
description: "PR number to benchmark and comment on."
required: true
type: string

permissions:
contents: read
pull-requests: write

jobs:
benchmark:
# Comment path: only on PRs, only `/benchmark-compare`, only from someone
# with write access. Manual path: always allowed.
if: >-
github.event_name == 'workflow_dispatch' ||
(github.event.issue.pull_request &&
startsWith(github.event.comment.body, '/benchmark-compare') &&
Comment thread
chernser marked this conversation as resolved.
contains(fromJSON('["OWNER","MEMBER","COLLABORATOR"]'), github.event.comment.author_association))
uses: ClickHouse/integrations-shared-workflows/.github/workflows/clickhouse-benchmark.yml@main

Check failure on line 39 in .github/workflows/stresshouse-benchmark-compare.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Use full commit SHA hash for this dependency.

See more on https://sonarcloud.io/project/issues?id=ClickHouse_clickhouse-java&issues=AZ9bsGAq7Ck9GhP6NnoS&open=AZ9bsGAq7Ck9GhP6NnoS&pullRequest=2922

Check failure

Code scanning / SonarCloud

External GitHub Actions and workflows should be pinned to a commit hash High

Use full commit SHA hash for this dependency. See more on SonarQube Cloud
Comment thread
chernser marked this conversation as resolved.
Dismissed
with:
client: clickhouse-java
profile: pr-compare
pr_number: ${{ github.event.issue.number || inputs.pr_number }}
secrets: inherit

Check warning on line 44 in .github/workflows/stresshouse-benchmark-compare.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Only pass required secrets to this workflow.

See more on https://sonarcloud.io/project/issues?id=ClickHouse_clickhouse-java&issues=AZ9bsGAq7Ck9GhP6NnoR&open=AZ9bsGAq7Ck9GhP6NnoR&pullRequest=2922

Check warning

Code scanning / SonarCloud

External reusable workflows should not inherit all repository secrets Medium

Only pass required secrets to this workflow. See more on SonarQube Cloud
Comment thread
chernser marked this conversation as resolved.
Dismissed
Loading