-
Notifications
You must be signed in to change notification settings - Fork 27
FEAT: Refine Perf Benchmarking, test across different OSs and add it to CI #315
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
📊 Code Coverage Report
Diff CoverageDiff: main...HEAD, staged and unstaged changesNo lines with coverage information in this diff. 📋 Files Needing Attention📉 Files with overall lowest coverage (click to expand)mssql_python.pybind.ddbc_bindings.cpp: 70.7%
mssql_python.pybind.connection.connection_pool.cpp: 78.9%
mssql_python.ddbc_bindings.py: 79.6%
mssql_python.pybind.connection.connection.cpp: 81.2%
mssql_python.connection.py: 82.9%
mssql_python.cursor.py: 83.4%
mssql_python.auth.py: 87.1%
mssql_python.pooling.py: 87.7%
mssql_python.helpers.py: 88.9%
mssql_python.row.py: 90.9%🔗 Quick Links
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds comprehensive performance benchmarking capabilities comparing mssql-python against pyodbc using real-world queries on the AdventureWorks2022 database. The benchmarking is integrated into the CI/CD pipeline to run automatically on both Windows (SQL Server 2022) and Ubuntu (containerized SQL Server 2022).
Key Changes:
- New
perf-benchmarking.pyscript with statistical analysis of query performance - Pipeline integration to download, restore, and benchmark against AdventureWorks2022
- ODBC Driver 18 installation automation for both Windows and Linux environments
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 7 comments.
| File | Description |
|---|---|
eng/pipelines/pr-validation-pipeline.yml |
Adds three new pipeline steps: AdventureWorks2022 database restore (Windows), ODBC Driver 18 installation and benchmark execution (Windows), and Ubuntu container-based benchmarking with database restore and ODBC setup |
benchmarks/perf-benchmarking.py |
New standalone benchmarking script with statistical analysis comparing mssql-python vs pyodbc across complex queries, large datasets, and CTEs |
benchmarks/README.md |
Updated documentation describing both benchmark scripts, their usage, features, and requirements |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Work Item / Issue Reference
Summary
This pull request introduces a comprehensive performance benchmarking workflow for comparing
mssql-pythonandpyodbcon real-world SQL Server workloads. The changes include a new benchmark script targeting the AdventureWorks2022 database, enhancements to the documentation, and updates to CI pipelines to automate database setup and benchmark execution on both Windows and Ubuntu environments.Benchmarking infrastructure and documentation:
benchmarks/perf-benchmarking.pyfor real-world query performance comparisons betweenmssql-pythonandpyodbc, including statistical analysis, speedup calculations, and detailed reporting.benchmarks/README.mdwith instructions and key features for running both the new and existing benchmark scripts, clarifying usage, output, and requirements.CI/CD pipeline automation:
eng/pipelines/pr-validation-pipeline.ymlto automatically download and restore the AdventureWorks2022 database for both Windows and Ubuntu environments, ensuring benchmarks run against a realistic dataset. [1] [2]These changes provide a robust framework for evaluating and monitoring database driver performance in CI, helping guide future optimizations and ensuring reliability across platforms.