terraform-provider-aws
terraform-provider-aws copied to clipboard
Adding Forcenew for `data_type` in SSM parameter
Description
When an SSM parameter is created with a data_type: text and is changed to data_type: aws:ec2:image and vice versa, the provider tries to perform an in-place replacement instead of force replacement where it needs to destroy the SSM parameter and recreate it with correct data_type
Relations
Closes #35959
Output from Acceptance Testing
➜ make testacc TESTS=TestParameterShouldUpdate PKG=ssm
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/ssm/... -v -count 1 -parallel 20 -run='TestParameterShouldUpdate' -timeout 360m
=== RUN TestParameterShouldUpdate
=== PAUSE TestParameterShouldUpdate
=== CONT TestParameterShouldUpdate
--- PASS: TestParameterShouldUpdate (0.00s)
PASS
ok github.com/hashicorp/terraform-provider-aws/internal/service/ssm 6.602s
Community Note
Voting for Prioritization
- Please vote on this pull request by adding a 👍 reaction to the original post to help the community and maintainers prioritize this pull request.
- Please see our prioritization guide for information on how we prioritize.
- Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.
For Submitters
- Review the contribution guide relating to the type of change you are making to ensure all of the necessary steps have been taken.
- For new resources and data sources, use skaff to generate scaffolding with comments detailing common expectations.
- Whether or not the branch has been rebased will not impact prioritization, but doing so is always a welcome surprise.
LGTM! 🚀 Thank you so much for your contribution!
> make testacc TESTARGS="-run=TestAccSSMParameter_DataType_" PKG=ssm
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go1.21.8 test ./internal/service/ssm/... -v -count 1 -parallel 20 -run=TestAccSSMParameter_DataType_ -timeout 360m
=== RUN TestAccSSMParameter_DataType_ec2Image
=== PAUSE TestAccSSMParameter_DataType_ec2Image
=== RUN TestAccSSMParameter_DataType_ssmIntegration
=== PAUSE TestAccSSMParameter_DataType_ssmIntegration
=== RUN TestAccSSMParameter_DataType_update
=== PAUSE TestAccSSMParameter_DataType_update
=== CONT TestAccSSMParameter_DataType_ec2Image
=== CONT TestAccSSMParameter_DataType_update
=== CONT TestAccSSMParameter_DataType_ssmIntegration
--- PASS: TestAccSSMParameter_DataType_ssmIntegration (14.44s)
--- PASS: TestAccSSMParameter_DataType_ec2Image (16.47s)
--- PASS: TestAccSSMParameter_DataType_update (25.48s)
PASS
ok github.com/hashicorp/terraform-provider-aws/internal/service/ssm 31.337s
This functionality has been released in v5.43.0 of the Terraform AWS 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!
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.