Skip to content

Commit

Permalink
Make it possible to set legacyColumns in the config
Browse files Browse the repository at this point in the history
  • Loading branch information
spenes committed Aug 1, 2024
1 parent 04ea59c commit 26dee12
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,7 @@ module "bigquery_loader_pubsub" {
| <a name="input_user_provided_id"></a> [user\_provided\_id](#input\_user\_provided\_id) | An optional unique identifier to identify the telemetry events emitted by this stack | `string` | `""` | no |
| <a name="input_webhook_collector"></a> [webhook\_collector](#input\_webhook\_collector) | Collector address used to gather monitoring alerts | `string` | `""` | no |
| <a name="input_skip_schemas"></a> [skip\_schemas](#input\_skip\_schemas) | The list of schema keys which should be skipped (not loaded) to the warehouse | `list(string)` | `[]` | no |
| <a name="input_legacy_columns"></a> [legacy\_columns](#input\_legacy\_columns) | Schemas for which to use the legacy column style used by the v1 BigQuery Loader. For these columns, there is a column per _minor_ version of each schema. | `list(string)` | `[]` | no |
| <a name="input_healthcheck_enabled"></a> [healthcheck\_enabled](#input\_healthcheck\_enabled) | Whether or not to enable health check probe for GCP instance group | `bool` | `true` | no |

## Outputs
Expand Down
1 change: 1 addition & 0 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,7 @@ locals {
bigquery_service_account_json_b64 = var.bigquery_service_account_json_b64

skip_schemas = jsonencode(var.skip_schemas)
legacy_columns = jsonencode(var.legacy_columns)
webhook_collector = var.webhook_collector
tags = jsonencode(var.labels)

Expand Down
2 changes: 2 additions & 0 deletions templates/config.json.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@

"skipSchemas": ${skip_schemas}

"legacyColumns": ${legacy_columns}

%{ if webhook_collector != "" ~}
"monitoring": {
"webhook": {
Expand Down
6 changes: 6 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,12 @@ variable "skip_schemas" {
default = []
}

variable "legacy_columns" {
description = "Schemas for which to use the legacy column style used by the v1 BigQuery Loader. For these columns, there is a column per _minor_ version of each schema."
type = list(string)
default = []
}

variable "healthcheck_enabled" {
description = "Whether or not to enable health check probe for GCP instance group"
type = bool
Expand Down

0 comments on commit 26dee12

Please sign in to comment.