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

SuppressEquivalentJsonDiffs on redrive_allow_policy for aws_sqs_queue_redrive_allow_policy #40604

Merged
merged 21 commits into from
Dec 18, 2024

Conversation

t0yv0
Copy link
Contributor

@t0yv0 t0yv0 commented Dec 17, 2024

Description

redrive_allow_policy field on aws_sqs_queue_redrive_allow_policy is made more robust to ignore non-semantic JSON whitespace changes for purposes of planning.

Relations

Closes #40119

References

Output from Acceptance Testing

> TF_ACC=1 go test -run TestAccSQSQueueRedriveAllowPolicy_by_queue -test.v
2024/12/17 16:22:20 Initializing Terraform AWS Provider...
=== RUN   TestAccSQSQueueRedriveAllowPolicy_by_queue
=== PAUSE TestAccSQSQueueRedriveAllowPolicy_by_queue
=== CONT  TestAccSQSQueueRedriveAllowPolicy_by_queue
--- PASS: TestAccSQSQueueRedriveAllowPolicy_by_queue (124.55s)
PASS

@t0yv0 t0yv0 requested a review from a team as a code owner December 17, 2024 21:26
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 tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. service/sqs Issues and PRs that pertain to the sqs service. needs-triage Waiting for first response or review from a maintainer. labels Dec 17, 2024
@t0yv0 t0yv0 changed the title Fix 40119 SuppressEquivalentJsonDiffs on redrive_allow_policy for aws_sqs_queue_redrive_allow_policy Dec 17, 2024
@ewbankkit ewbankkit added bug Addresses a defect in current functionality. and removed needs-triage Waiting for first response or review from a maintainer. labels Dec 18, 2024
@ewbankkit ewbankkit self-assigned this Dec 18, 2024
@github-actions github-actions bot added the prioritized Part of the maintainer teams immediate focus. To be addressed within the current quarter. label Dec 18, 2024
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=TestAccSQSQueueRedriveAllowPolicy_\|TestAccSQSQueueDataSource_' PKG=sqs ACCTEST_PARALLELISM=3
make: Verifying source code with gofmt...
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go1.23.3 test ./internal/service/sqs/... -v -count 1 -parallel 3  -run=TestAccSQSQueueRedriveAllowPolicy_\|TestAccSQSQueueDataSource_ -timeout 360m
2024/12/18 14:34:30 Initializing Terraform AWS Provider...
=== RUN   TestAccSQSQueueDataSource_tags
=== PAUSE TestAccSQSQueueDataSource_tags
=== RUN   TestAccSQSQueueDataSource_tags_NullMap
=== PAUSE TestAccSQSQueueDataSource_tags_NullMap
=== RUN   TestAccSQSQueueDataSource_tags_EmptyMap
=== PAUSE TestAccSQSQueueDataSource_tags_EmptyMap
=== RUN   TestAccSQSQueueDataSource_tags_DefaultTags_nonOverlapping
=== PAUSE TestAccSQSQueueDataSource_tags_DefaultTags_nonOverlapping
=== RUN   TestAccSQSQueueDataSource_tags_IgnoreTags_Overlap_DefaultTag
=== PAUSE TestAccSQSQueueDataSource_tags_IgnoreTags_Overlap_DefaultTag
=== RUN   TestAccSQSQueueDataSource_tags_IgnoreTags_Overlap_ResourceTag
=== PAUSE TestAccSQSQueueDataSource_tags_IgnoreTags_Overlap_ResourceTag
=== RUN   TestAccSQSQueueDataSource_basic
=== PAUSE TestAccSQSQueueDataSource_basic
=== RUN   TestAccSQSQueueRedriveAllowPolicy_basic
=== PAUSE TestAccSQSQueueRedriveAllowPolicy_basic
=== RUN   TestAccSQSQueueRedriveAllowPolicy_disappears
=== PAUSE TestAccSQSQueueRedriveAllowPolicy_disappears
=== RUN   TestAccSQSQueueRedriveAllowPolicy_Disappears_queue
=== PAUSE TestAccSQSQueueRedriveAllowPolicy_Disappears_queue
=== RUN   TestAccSQSQueueRedriveAllowPolicy_update
=== PAUSE TestAccSQSQueueRedriveAllowPolicy_update
=== RUN   TestAccSQSQueueRedriveAllowPolicy_byQueue
=== PAUSE TestAccSQSQueueRedriveAllowPolicy_byQueue
=== CONT  TestAccSQSQueueDataSource_tags
=== CONT  TestAccSQSQueueDataSource_basic
=== CONT  TestAccSQSQueueDataSource_tags_DefaultTags_nonOverlapping
--- PASS: TestAccSQSQueueDataSource_tags (41.01s)
=== CONT  TestAccSQSQueueDataSource_tags_IgnoreTags_Overlap_ResourceTag
--- PASS: TestAccSQSQueueDataSource_tags_DefaultTags_nonOverlapping (41.02s)
=== CONT  TestAccSQSQueueDataSource_tags_IgnoreTags_Overlap_DefaultTag
--- PASS: TestAccSQSQueueDataSource_basic (41.42s)
=== CONT  TestAccSQSQueueRedriveAllowPolicy_Disappears_queue
--- PASS: TestAccSQSQueueDataSource_tags_IgnoreTags_Overlap_DefaultTag (39.47s)
=== CONT  TestAccSQSQueueRedriveAllowPolicy_byQueue
--- PASS: TestAccSQSQueueDataSource_tags_IgnoreTags_Overlap_ResourceTag (39.66s)
=== CONT  TestAccSQSQueueRedriveAllowPolicy_update
--- PASS: TestAccSQSQueueRedriveAllowPolicy_Disappears_queue (133.18s)
=== CONT  TestAccSQSQueueRedriveAllowPolicy_disappears
--- PASS: TestAccSQSQueueRedriveAllowPolicy_byQueue (118.37s)
=== CONT  TestAccSQSQueueRedriveAllowPolicy_basic
--- PASS: TestAccSQSQueueRedriveAllowPolicy_update (151.87s)
=== CONT  TestAccSQSQueueDataSource_tags_NullMap
--- PASS: TestAccSQSQueueDataSource_tags_NullMap (39.20s)
=== CONT  TestAccSQSQueueDataSource_tags_EmptyMap
--- PASS: TestAccSQSQueueDataSource_tags_EmptyMap (39.32s)
--- PASS: TestAccSQSQueueRedriveAllowPolicy_basic (125.54s)
--- PASS: TestAccSQSQueueRedriveAllowPolicy_disappears (164.93s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/sqs	344.877s

@@ -68,16 +66,6 @@ func dataSourceQueueRead(ctx context.Context, d *schema.ResourceData, meta inter
d.Set(names.AttrARN, attributesOutput)
d.Set(names.AttrURL, queueURL)

if errs.IsUnsupportedOperationInPartitionError(meta.(*conns.AWSClient).Partition(ctx), err) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Is this needed as part of the change? Thanks.

Copy link
Member

@jar-b jar-b left a comment

Choose a reason for hiding this comment

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

LGTM 🚀

@ewbankkit
Copy link
Contributor

@t0yv0 Thanks for the contribution 🎉 👏.

@ewbankkit ewbankkit merged commit a4c1943 into hashicorp:main Dec 18, 2024
36 checks passed
@github-actions github-actions bot added this to the v5.82.0 milestone Dec 18, 2024
Copy link

This functionality has been released in v5.82.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 github-actions bot removed the prioritized Part of the maintainer teams immediate focus. To be addressed within the current quarter. label Dec 19, 2024
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 Jan 19, 2025
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/sqs Issues and PRs that pertain to the sqs service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: Permadiff in redrive_allow_policy attribute of aws_sqs_queue_redrive_allow_policy
3 participants