Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix permadiff of encryption_configuration in resource_bigquery_table when API returns an empty object #16926

Conversation

modular-magician
Copy link
Collaborator

Sometimes the API returns a table with "encryptionConfiguration": {} when the input omits this field.

Without this change, the Terraform state file would end up with

"encryption_configuration": [
  {
    "kms_key_name": "",
     "kms_key_version": ""
  }
]

This would cause the subsequent plan to end up with a diff of - encryption_configuration {} # forces replacement.

With this change, the new Terraform state file would have:

"encryption_configuration": []

This would no longer result in a permadiff.

Release Note Template for Downstream PRs (will be copied)

bigquery: Fix permadiff of encryption_configuration in resource_bigquery_table when API returns an empty object

Derived from GoogleCloudPlatform/magic-modules#9757

…when API returns an empty object (hashicorp#9757)

[upstream:e13491302ec24b3bee4a10d88b319d2cfa14067b]

Signed-off-by: Modular Magician <magic-modules@google.com>
@modular-magician modular-magician merged commit 12fcca1 into hashicorp:main Jan 8, 2024
2 checks passed
Copy link

github-actions bot commented Feb 8, 2024

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 8, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant