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

FLPROD-1301: Fixing managed headers update bug #3260

Merged
merged 2 commits into from
Apr 26, 2024

Conversation

WowVeryLogin
Copy link
Contributor

Currently managed headers provider won't change the state of resource not present in the tf state. This means customers can't disable managed headers rules by deleting them from tf config. Fixing it with test.

Copy link
Contributor

github-actions bot commented Apr 22, 2024

changelog detected ✅

@WowVeryLogin WowVeryLogin force-pushed the denis/FLPROD-1301 branch 5 times, most recently from 96aace5 to ea1cec3 Compare April 23, 2024 08:57
Currently managed headers provider won't change the state of resource not present in the tf state.
This means customers can't disable managed headers rules by deleting them from tf config. Fixing it with test.
@jacobbednarz
Copy link
Member

i believe what you're seeing here is a side effect of zero value handling in the legacy SDKv2. while this works, it may have unintended side effects and bugs down the road. check out #2170 for more in depth details of this as the final mitigation option may be to upgrade to the newer implementation. for now, we're 👌

acceptance tests are passing

TF_ACC=1 go test ./internal/sdkv2provider -v -run "^TestAccCloudflareManagedHeaders" -count 1 -timeout 120m -parallel 1
=== RUN   TestAccCloudflareManagedHeaders
=== PAUSE TestAccCloudflareManagedHeaders
=== CONT  TestAccCloudflareManagedHeaders
--- PASS: TestAccCloudflareManagedHeaders (21.27s)
PASS
ok  	github.com/cloudflare/terraform-provider-cloudflare/internal/sdkv2provider	22.191s

@jacobbednarz jacobbednarz merged commit 91a9c59 into cloudflare:master Apr 26, 2024
9 checks passed
@github-actions github-actions bot added this to the v4.31.0 milestone Apr 26, 2024
github-actions bot pushed a commit that referenced this pull request Apr 26, 2024
Copy link
Contributor

github-actions bot commented May 1, 2024

This functionality has been released in v4.31.0 of the Terraform Cloudflare Provider.

Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 1, 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.

2 participants