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 Firestore field deletion for wildcard fields #9140

Conversation

modular-magician
Copy link
Collaborator

You can update index configs for wildcard fields, but you can't update TTL configs. When we "delete" SFIs, we actually issue a PATCH with empty index and TTL configs. We put both indexConfig and ttlConfig in the update mask for this PATCH accordingly.

For wildcard fields, simply exclude ttlConfig from the update mask when issuing this PATCH to avoid the "unsupported" error.

Fixes hashicorp/terraform-provider-google#20397

firestore: fixed deletion of wildcard fields in `google_firestore_field`

Derived from GoogleCloudPlatform/magic-modules#12856

[upstream:7d08e89ac8686de13d9fdc30dc1f557925c3004d]

Signed-off-by: Modular Magician <magic-modules@google.com>
@modular-magician modular-magician requested a review from a team as a code owner January 24, 2025 16:57
@modular-magician modular-magician merged commit 2c238b9 into hashicorp:main Jan 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

firestore_field: unable to delete after applying the resource
1 participant