Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 8, 2026

Implements automated performance tracking for pull requests to surface regressions before merge.

Changes

  • Benchmark execution: Modified to output JSON format for structured comparison

    ./casbin_benchmark --benchmark_format=json --benchmark_out=benchmark_result.json
  • GitHub Action integration: Added benchmark-action/github-action-benchmark@v1

    • Compares PR benchmarks against master baseline
    • Posts automated PR comments with performance deltas
    • Stores results on master for historical tracking
    • Alert threshold: 150% (flags >50% performance degradation)
    • Non-blocking: warns but doesn't fail CI
  • Permissions: Added contents: write and pull-requests: write for result storage and PR comments

Behavior

On PRs: Runs benchmarks, compares to master baseline, posts comment with performance comparison

On master: Runs benchmarks and persists results for future PR comparisons

Original prompt

This section details on the original issue you should resolve

<issue_title>ci: automated PR performance benchmark comparison</issue_title>
<issue_description>We should implement a CI workflow to execute benchmarks on each PR:

  • show performance delta between the new changes and the main branch.

  • use automated comments to display benchmark results directly.

  • ensure new features do not slow down the library.</issue_description>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@hsluoyz hsluoyz marked this pull request as ready for review January 8, 2026 06:04
Copilot AI and others added 3 commits January 8, 2026 06:10
- Modified benchmark workflow to output JSON format
- Added github-action-benchmark to compare PR vs master
- Enabled automated PR comments with performance delta
- Set alert threshold at 150% performance degradation

Co-authored-by: hsluoyz <[email protected]>
Copilot AI changed the title [WIP] Add CI workflow for automated PR performance benchmarking ci: add automated PR benchmark comparison with performance alerts Jan 8, 2026
Copilot AI requested a review from hsluoyz January 8, 2026 06:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ci: automated PR performance benchmark comparison

3 participants