GoogleCloudPlatform / bigquery-utils

Useful scripts, udfs, views, and other utilities for migration and data warehouse operations in BigQuery.
https://cloud.google.com/bigquery/
Apache License 2.0
1.07k stars 269 forks source link

Updated daily and hourly utilization to use JOBS_TIMELINE #345

Closed geoffmc closed 1 year ago

geoffmc commented 1 year ago

Current implementation uses the JOBS table which doesn't account for long running jobs. In the hourly_utilization query, if a job runs for multiple hours, then all of the slot usage gets counted in the first hour. Using JOBS_TIMELINE, this usage gets broken across each hour that it runs.

google-cla[bot] commented 1 year ago

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.