Skip to content

Optimize benchmarks pipeline, fix quota leaks and handle manual builds#851

Open
Mahalaxmibejugam wants to merge 4 commits into
fsspec:mainfrom
ankitaluthra1:benchmark-improvements
Open

Optimize benchmarks pipeline, fix quota leaks and handle manual builds#851
Mahalaxmibejugam wants to merge 4 commits into
fsspec:mainfrom
ankitaluthra1:benchmark-improvements

Conversation

@Mahalaxmibejugam
Copy link
Copy Markdown
Collaborator

@Mahalaxmibejugam Mahalaxmibejugam commented May 29, 2026

This PR improves the robustness and maintainability of the benchmarks Cloud Build pipeline in benchmarks-cloudbuild.yaml

  • Optimized Empty File Handling: Updated logic to use pipe() instead of open() + info() for empty files, reducing overhead and improving performance of read benchmarks.
  • Fixed Quota Issues: Added a cleanup-leaked-resources step at the beginning of the build to find and delete leaked VMs (older than 5 hours) with the prefix ${_INFRA_PREFIX}-vm-. This prevents failed or cancelled builds from exhausting project quotas.
  • Reduced Code Duplication: Combined the create-io-vm and create-metadata-vm steps into a single reusable create-vm step. It uses bash conditions to apply high-performance flags (like hyperdisk and GVNIC) only when _BENCHMARK_TYPE is IO.
  • Fixed Manual Build Failures: Added a conditional check during the installation of gcsfs on the VM. If the .git directory is missing (which happens during manual gcloud builds submit runs), it sets a dummy version 0.0.0 to prevent hatch-vcs from failing.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 29, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.13%. Comparing base (94efa8c) to head (48e30de).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #851   +/-   ##
=======================================
  Coverage   89.13%   89.13%           
=======================================
  Files          15       15           
  Lines        3130     3130           
=======================================
  Hits         2790     2790           
  Misses        340      340           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

If the benchmark run fails during the dataset creation phase, we want to
make sure that teardown would be done
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.

1 participant