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

r/aws_elasticache_parameter_group: reset ID if deleted manually #32669

Merged
merged 4 commits into from
Jul 25, 2023

Conversation

tthompson-figma
Copy link
Contributor

@tthompson-figma tthompson-figma commented Jul 24, 2023

Description

If a parameter group in state is not found in AWS during resource read, reset the group's ID to force its recreation instead of failing immediately.

Relations

Closes #18338.
Closes #32244.

Output from Acceptance Testing

Running now, will post when complete!

% make testacc PKG=elasticache

@github-actions
Copy link

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.

@github-actions github-actions bot added size/XS Managed by automation to categorize the size of a PR. service/elasticache Issues and PRs that pertain to the elasticache service. needs-triage Waiting for first response or review from a maintainer. labels Jul 24, 2023
@justinretzolk justinretzolk added bug Addresses a defect in current functionality. and removed needs-triage Waiting for first response or review from a maintainer. labels Jul 24, 2023
@github-actions github-actions bot added size/L Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. and removed size/XS Managed by automation to categorize the size of a PR. labels Jul 25, 2023
Copy link
Contributor

@ewbankkit ewbankkit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀.

% make testacc TESTARGS='-run=TestAccElastiCacheParameterGroup_' PKG=elasticache ACCTEST_PARALLELISM=2
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/elasticache/... -v -count 1 -parallel 2  -run=TestAccElastiCacheParameterGroup_ -timeout 180m
=== RUN   TestAccElastiCacheParameterGroup_basic
=== PAUSE TestAccElastiCacheParameterGroup_basic
=== RUN   TestAccElastiCacheParameterGroup_disappears
=== PAUSE TestAccElastiCacheParameterGroup_disappears
=== RUN   TestAccElastiCacheParameterGroup_addParameter
=== PAUSE TestAccElastiCacheParameterGroup_addParameter
=== RUN   TestAccElastiCacheParameterGroup_removeAllParameters
=== PAUSE TestAccElastiCacheParameterGroup_removeAllParameters
=== RUN   TestAccElastiCacheParameterGroup_RemoveReservedMemoryParameter_allParameters
=== PAUSE TestAccElastiCacheParameterGroup_RemoveReservedMemoryParameter_allParameters
=== RUN   TestAccElastiCacheParameterGroup_RemoveReservedMemoryParameter_remainingParameters
=== PAUSE TestAccElastiCacheParameterGroup_RemoveReservedMemoryParameter_remainingParameters
=== RUN   TestAccElastiCacheParameterGroup_switchReservedMemoryParameter
=== PAUSE TestAccElastiCacheParameterGroup_switchReservedMemoryParameter
=== RUN   TestAccElastiCacheParameterGroup_updateReservedMemoryParameter
=== PAUSE TestAccElastiCacheParameterGroup_updateReservedMemoryParameter
=== RUN   TestAccElastiCacheParameterGroup_uppercaseName
=== PAUSE TestAccElastiCacheParameterGroup_uppercaseName
=== RUN   TestAccElastiCacheParameterGroup_description
=== PAUSE TestAccElastiCacheParameterGroup_description
=== RUN   TestAccElastiCacheParameterGroup_tags
=== PAUSE TestAccElastiCacheParameterGroup_tags
=== CONT  TestAccElastiCacheParameterGroup_basic
=== CONT  TestAccElastiCacheParameterGroup_switchReservedMemoryParameter
--- PASS: TestAccElastiCacheParameterGroup_basic (29.90s)
=== CONT  TestAccElastiCacheParameterGroup_removeAllParameters
--- PASS: TestAccElastiCacheParameterGroup_switchReservedMemoryParameter (50.46s)
=== CONT  TestAccElastiCacheParameterGroup_RemoveReservedMemoryParameter_remainingParameters
--- PASS: TestAccElastiCacheParameterGroup_removeAllParameters (43.21s)
=== CONT  TestAccElastiCacheParameterGroup_RemoveReservedMemoryParameter_allParameters
--- PASS: TestAccElastiCacheParameterGroup_RemoveReservedMemoryParameter_remainingParameters (46.75s)
=== CONT  TestAccElastiCacheParameterGroup_addParameter
--- PASS: TestAccElastiCacheParameterGroup_RemoveReservedMemoryParameter_allParameters (45.52s)
=== CONT  TestAccElastiCacheParameterGroup_disappears
--- PASS: TestAccElastiCacheParameterGroup_disappears (19.90s)
=== CONT  TestAccElastiCacheParameterGroup_description
--- PASS: TestAccElastiCacheParameterGroup_addParameter (44.32s)
=== CONT  TestAccElastiCacheParameterGroup_tags
--- PASS: TestAccElastiCacheParameterGroup_description (25.69s)
=== CONT  TestAccElastiCacheParameterGroup_uppercaseName
--- PASS: TestAccElastiCacheParameterGroup_uppercaseName (26.70s)
=== CONT  TestAccElastiCacheParameterGroup_updateReservedMemoryParameter
--- PASS: TestAccElastiCacheParameterGroup_tags (63.77s)
--- PASS: TestAccElastiCacheParameterGroup_updateReservedMemoryParameter (43.74s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/elasticache	239.845s

@ewbankkit
Copy link
Contributor

@tthompson-figma Thanks for the contribution 🎉 👏.

@ewbankkit ewbankkit merged commit cc99f0b into hashicorp:main Jul 25, 2023
40 checks passed
@github-actions github-actions bot added this to the v5.10.0 milestone Jul 25, 2023
@tthompson-figma
Copy link
Contributor Author

@ewbankkit Thanks for running the tests and finishing up!!

}

return tfresource.AssertSinglePtrResult(output.CacheParameterGroups)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oooh TIL!

@github-actions
Copy link

This functionality has been released in v5.10.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!

@github-actions
Copy link

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 Aug 27, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Addresses a defect in current functionality. service/elasticache Issues and PRs that pertain to the elasticache service. size/L Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
4 participants