terraform-google-bigquery icon indicating copy to clipboard operation
terraform-google-bigquery copied to clipboard

Create dependency between table and view creation

Open kawofong opened this issue 3 years ago • 1 comments

TL;DR

Currently, this module doesn't require the BigQuery views to be created after the BigQuery tables. However, I am using this module to scaffold my project BigQuery setup, which includes BQ tables and views (which depends on BQ tables declarations in the same module).

Terraform Resources

https://github.com/terraform-google-modules/terraform-google-bigquery/blob/master/main.tf#L105

Detailed design

Potential design:

1. Use [depends_on](https://www.terraform.io/language/meta-arguments/depends_on) to create dependency from [BQ view](https://github.com/terraform-google-modules/terraform-google-bigquery/blob/master/main.tf#L105) on [BQ table](https://github.com/terraform-google-modules/terraform-google-bigquery/blob/master/main.tf#L64)

1. Introduce a new TF module variable `create_view_after_table (bool)` that would control whether to create BQ tables before creating BQ views.

Additional information

No response

kawofong avatar Jun 17 '22 21:06 kawofong

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days

github-actions[bot] avatar Aug 16 '22 23:08 github-actions[bot]