Skip to content

Monitors and estimates sizes of specified tables and columns in a large database cluster.

Notifications You must be signed in to change notification settings

MilhosOU/DBT_BigQuery_TableSizeWatcher

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

BQ_TableSizeWatcher

Description

Monitors and estimates sizes of specified tables and columns in a BigQuery cluster. This tool is indispensable for those managing large-scale BigQuery clusters, especially when dealing with billions of rows and potentially unstructured data.

Why This Tool Is Important

In the landscape of large BigQuery clusters, resource efficiency is non-negotiable. Tables can exponentially grow, affecting both costs and query performance. BQ_TableSizeWatcher offers granular visibility into the size footprint of individual tables and columns, enabling proactive management and optimization.

It's important to note that querying the size of each column in such massive datasets can result in significant expenses. Hence, specifying a sample size is vital for operational efficiency. Querying large tables in their entirety is both cost-prohibitive and resource-intensive. A sample provides a quick and economical size estimation, while maintaining a high degree of accuracy.

Variables

  • project: The BigQuery project ID.
  • schema: The BigQuery schema you want to monitor.
  • tables: List of tables to monitor.
  • sample_size: Number of rows to sample for size estimation. This is critical for cost-effective data observability.

How to Run

To run the model, set the variables as follows:

dbt build --select BQ_TableSizeWatcher --vars '{"schema": "<YOUR-SCHEMA>", "tables": [<YOUR-TABLES>], "sample_size": <YOUR-SAMPLE-SIZE>}'

Example Output

example-output

About

Monitors and estimates sizes of specified tables and columns in a large database cluster.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published