[ADAP-622] [Regression] Authorised views grant_access_to
exceeded rate limit error
#770
Closed
2 tasks done
Labels
Is this a regression in a recent version of dbt-bigquery?
Current Behavior
When creating many authorized views on a single dataset in a short amount of time, the bigquery update dataset limit of 5 update operations per 10 seconds is quickly reached.
This is unavoidable and expected the first time the authorized views are created, but on subsequent dbt runs when the authorized views already exist, I am now also seeing this limit being hit which previously was not happening.
When the dbt logs show this warning:
BigQuery logs are giving this error
Expected/Previous Behavior
Previously when an authorized view already existed in a dataset, using
grant_access_to
would show thealready exists in dataset
warning but not cause an additional unnecessary dataset update.Steps To Reproduce
With dbt-bigquery >= v1.4.2, create a lot of authorized views (>5) on a single dataset and do two dbt runs.
After the second run, in gcp logs explorer run the following query to view rate exceeded errors
Relevant log output
No response
Environment
Additional Context
This issue is due to a recent change with the BigQueryAdapter grant_access_to() method which now will call the bigquery patch.dataset api even when the authorized view already exists in the dataset.
I don't believe this is expected behaviour because of the relatively low limit for this operation, calling it when unnecessary has the potential to significantly impact performance.
The text was updated successfully, but these errors were encountered: