Skip to content
Draft
Show file tree
Hide file tree
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
8 changes: 7 additions & 1 deletion .github/workflows/slo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ jobs:
matrix:
sdk:
- name: cpp-key-value
workload_type: table
preset: release-test-clang
dockerfile: tests/slo_workloads/Dockerfile
cache_scope: slo-key-value
Expand All @@ -103,6 +104,7 @@ jobs:
binary: tests/slo_workloads/key_value/slo-key-value
command: "--read-rps 1000 --write-rps 100"
- name: cpp-key-value-userver
workload_type: table
preset: release-test-clang
dockerfile: tests/slo_workloads/Dockerfile.userver
cache_scope: slo-userver-key-value
Expand All @@ -112,6 +114,7 @@ jobs:
binary: tests/slo_workloads/userver/key_value/slo-userver-key-value
command: "--read-rps 1000 --write-rps 100"
- name: cpp-topic
workload_type: topic
preset: release-test-clang
dockerfile: tests/slo_workloads/Dockerfile
cache_scope: slo-topic
Expand All @@ -122,6 +125,7 @@ jobs:
command: "--writer-count 20 --reader-count 5 --partition-count 10"
metrics_yaml_path: sdk-current/tests/slo_workloads/metrics-topic.yaml
- name: cpp-topic-userver
workload_type: topic
preset: release-test-clang
dockerfile: tests/slo_workloads/Dockerfile.userver
cache_scope: slo-userver-topic
Expand Down Expand Up @@ -280,7 +284,8 @@ jobs:
cache-to: type=gha,mode=max,scope=${{ matrix.sdk.cache_scope }}-${{ matrix.sdk.preset }}-baseline

- name: Run SLO Tests
uses: ydb-platform/ydb-slo-action/init@v2
# Pin legacy telemetry fixes until ydb-slo-action#81 is merged.
uses: ydb-platform/ydb-slo-action/init@d66bd1e10f893e5f70d542c4430a3cffb6d6f9f8
timeout-minutes: 30
env:
BUILDX_BUILDER: default
Expand All @@ -295,5 +300,6 @@ jobs:
workload_baseline_ref: ${{ steps.baseline.outputs.ref }}
workload_baseline_image: ydb-app-baseline
workload_baseline_command: ${{ matrix.sdk.command }}
workload_type: ${{ matrix.sdk.workload_type }}
metrics_yaml_path: ${{ matrix.sdk.metrics_yaml_path }}
fail_on_workload_error: "true"
34 changes: 5 additions & 29 deletions .github/workflows/slo_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,11 @@ name: SLO Report
on:
workflow_run:
workflows: ["SLO"]
types:
- completed
types: [completed]

jobs:
publish-slo-report:
if: github.event.workflow_run.conclusion != 'skipped'
if: github.event.workflow_run.event == 'pull_request'
runs-on: ubuntu-latest
name: Publish YDB SLO Report
permissions:
Expand All @@ -18,31 +17,8 @@ jobs:
pull-requests: write
steps:
- name: Publish YDB SLO Report
uses: ydb-platform/ydb-slo-action/report@v2
uses: ydb-platform/ydb-slo-action/report@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
github_run_id: ${{ github.event.workflow_run.id }}

remove-slo-label:
needs: publish-slo-report
if: github.event.workflow_run.conclusion != 'skipped' && github.event.workflow_run.event == 'pull_request'
runs-on: ubuntu-latest
name: Remove SLO Label
permissions:
pull-requests: write
steps:
- name: Remove SLO label from PR
env:
PRS: ${{ toJSON(github.event.workflow_run.pull_requests) }}
REPO: ${{ github.event.workflow_run.repository.full_name }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
set -euo pipefail
PR=$(jq -r '.[0].number' <<<"$PRS")
if [ "$PR" = "null" ] || [ -z "$PR" ]; then
echo "No pull requests associated with this workflow run"
exit 0
fi
gh pr edit "$PR" --repo "$REPO" --remove-label SLO || {
echo "SLO label not found on PR #${PR}, skipping"
}
github_workflows: SLO
remove_label: SLO
Loading