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

feat(aws_s3_bucket_metric): add support for access_point configuration in s3 bucket metric filter #35590

Conversation

amartin-isp
Copy link
Contributor

@amartin-isp amartin-isp commented Feb 1, 2024

Description

Add support for filtering by access_point for S3 bucket metric configuration

Relations

References

Output from Acceptance Testing

λ make testacc TESTS=TestAccS3BucketMetric PKG=s3
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/s3/... -v -count 1 -parallel 20 -run='TestAccS3BucketMetric'  -timeout 360m
=== RUN   TestAccS3BucketMetric_basic
=== PAUSE TestAccS3BucketMetric_basic
=== RUN   TestAccS3BucketMetric_withEmptyFilter
=== PAUSE TestAccS3BucketMetric_withEmptyFilter
=== RUN   TestAccS3BucketMetric_withFilterAccessPoint
=== PAUSE TestAccS3BucketMetric_withFilterAccessPoint
=== RUN   TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndMultiTags
=== PAUSE TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndMultiTags
=== RUN   TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndSingleTag
=== PAUSE TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndSingleTag
=== RUN   TestAccS3BucketMetric_withFilterAccessPointAndPrefix
=== PAUSE TestAccS3BucketMetric_withFilterAccessPointAndPrefix
=== RUN   TestAccS3BucketMetric_withFilterAccessPointAndMultipleTags
=== PAUSE TestAccS3BucketMetric_withFilterAccessPointAndMultipleTags
=== RUN   TestAccS3BucketMetric_withFilterAccessPointAndSingleTag
=== PAUSE TestAccS3BucketMetric_withFilterAccessPointAndSingleTag
=== RUN   TestAccS3BucketMetric_withFilterPrefix
=== PAUSE TestAccS3BucketMetric_withFilterPrefix
=== RUN   TestAccS3BucketMetric_withFilterPrefixAndMultipleTags
=== PAUSE TestAccS3BucketMetric_withFilterPrefixAndMultipleTags
=== RUN   TestAccS3BucketMetric_withFilterPrefixAndSingleTag
=== PAUSE TestAccS3BucketMetric_withFilterPrefixAndSingleTag
=== RUN   TestAccS3BucketMetric_withFilterMultipleTags
=== PAUSE TestAccS3BucketMetric_withFilterMultipleTags
=== RUN   TestAccS3BucketMetric_withFilterSingleTag
=== PAUSE TestAccS3BucketMetric_withFilterSingleTag
=== RUN   TestAccS3BucketMetric_directoryBucket
=== PAUSE TestAccS3BucketMetric_directoryBucket
=== CONT  TestAccS3BucketMetric_basic
=== CONT  TestAccS3BucketMetric_withFilterAccessPointAndSingleTag
=== CONT  TestAccS3BucketMetric_withFilterMultipleTags
=== CONT  TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndSingleTag
=== CONT  TestAccS3BucketMetric_directoryBucket
=== CONT  TestAccS3BucketMetric_withFilterSingleTag
=== CONT  TestAccS3BucketMetric_withFilterAccessPointAndPrefix
=== CONT  TestAccS3BucketMetric_withFilterAccessPoint
=== CONT  TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndMultiTags
=== CONT  TestAccS3BucketMetric_withFilterAccessPointAndMultipleTags
=== CONT  TestAccS3BucketMetric_withFilterPrefixAndMultipleTags
=== CONT  TestAccS3BucketMetric_withFilterPrefixAndSingleTag
=== CONT  TestAccS3BucketMetric_withEmptyFilter
=== CONT  TestAccS3BucketMetric_withFilterPrefix
--- PASS: TestAccS3BucketMetric_withEmptyFilter (9.36s)
--- PASS: TestAccS3BucketMetric_directoryBucket (26.58s)
--- PASS: TestAccS3BucketMetric_basic (51.02s)
--- PASS: TestAccS3BucketMetric_withFilterAccessPointAndSingleTag (70.89s)
--- PASS: TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndMultiTags (72.80s)
--- PASS: TestAccS3BucketMetric_withFilterPrefixAndSingleTag (76.48s)
--- PASS: TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndSingleTag (79.05s)
--- PASS: TestAccS3BucketMetric_withFilterAccessPointAndPrefix (79.45s)
--- PASS: TestAccS3BucketMetric_withFilterMultipleTags (79.52s)
--- PASS: TestAccS3BucketMetric_withFilterPrefix (79.70s)
--- PASS: TestAccS3BucketMetric_withFilterPrefixAndMultipleTags (79.93s)
--- PASS: TestAccS3BucketMetric_withFilterAccessPoint (80.00s)
--- PASS: TestAccS3BucketMetric_withFilterAccessPointAndMultipleTags (80.00s)
--- PASS: TestAccS3BucketMetric_withFilterSingleTag (80.01s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/s3	85.863s

@github-actions github-actions bot added the size/XL Managed by automation to categorize the size of a PR. label Feb 1, 2024
Copy link

github-actions bot commented Feb 1, 2024

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/s3 Issues and PRs that pertain to the s3 service. labels Feb 1, 2024
@terraform-aws-provider terraform-aws-provider bot added the needs-triage Waiting for first response or review from a maintainer. label Feb 1, 2024
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Welcome @amartin-isp 👋

It looks like this is your first Pull Request submission to the Terraform AWS Provider! If you haven’t already done so please make sure you have checked out our CONTRIBUTOR guide and FAQ to make sure your contribution is adhering to best practice and has all the necessary elements in place for a successful approval.

Also take a look at our FAQ which details how we prioritize Pull Requests for inclusion.

Thanks again, and welcome to the community! 😃

@amartin-isp amartin-isp changed the title feat(aws_s3_bucket_metric): adding support for access_point configuration in s3 bucket metric filter feat(aws_s3_bucket_metric): add support for access_point configuration in s3 bucket metric filter Feb 1, 2024
@github-actions github-actions bot added the documentation Introduces or discusses updates to documentation. label Feb 1, 2024
@amartin-isp amartin-isp marked this pull request as ready for review February 1, 2024 02:46
@ewbankkit ewbankkit added enhancement Requests to existing resources that expand the functionality or scope. and removed needs-triage Waiting for first response or review from a maintainer. labels Feb 1, 2024
@amartin-isp
Copy link
Contributor Author

amartin-isp commented Feb 1, 2024

Hi @ewbankkit, I think I was able to address the failures in Acceptance Test Linting / terrafmt with my last commit. I'm not sure how to address the ones in ProviderLint Checks / providerlint though.

@amartin-isp
Copy link
Contributor Author

Hi @ewbankkit, I think I was able to address the failures in Acceptance Test Linting / terrafmt with my last commit. I'm not sure how to address the ones in ProviderLint Checks / providerlint though.

My last commit should address the ProviderLint Checks / providerlint failures as well.

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=TestAccS3BucketMetric_' PKG=s3 ACCTEST_PARALLELISM=3
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/s3/... -v -count 1 -parallel 3  -run=TestAccS3BucketMetric_ -timeout 360m
=== RUN   TestAccS3BucketMetric_basic
=== PAUSE TestAccS3BucketMetric_basic
=== RUN   TestAccS3BucketMetric_withEmptyFilter
=== PAUSE TestAccS3BucketMetric_withEmptyFilter
=== RUN   TestAccS3BucketMetric_withFilterAccessPoint
=== PAUSE TestAccS3BucketMetric_withFilterAccessPoint
=== RUN   TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndMultiTags
=== PAUSE TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndMultiTags
=== RUN   TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndSingleTag
=== PAUSE TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndSingleTag
=== RUN   TestAccS3BucketMetric_withFilterAccessPointAndPrefix
=== PAUSE TestAccS3BucketMetric_withFilterAccessPointAndPrefix
=== RUN   TestAccS3BucketMetric_withFilterAccessPointAndMultipleTags
=== PAUSE TestAccS3BucketMetric_withFilterAccessPointAndMultipleTags
=== RUN   TestAccS3BucketMetric_withFilterAccessPointAndSingleTag
=== PAUSE TestAccS3BucketMetric_withFilterAccessPointAndSingleTag
=== RUN   TestAccS3BucketMetric_withFilterPrefix
=== PAUSE TestAccS3BucketMetric_withFilterPrefix
=== RUN   TestAccS3BucketMetric_withFilterPrefixAndMultipleTags
=== PAUSE TestAccS3BucketMetric_withFilterPrefixAndMultipleTags
=== RUN   TestAccS3BucketMetric_withFilterPrefixAndSingleTag
=== PAUSE TestAccS3BucketMetric_withFilterPrefixAndSingleTag
=== RUN   TestAccS3BucketMetric_withFilterMultipleTags
=== PAUSE TestAccS3BucketMetric_withFilterMultipleTags
=== RUN   TestAccS3BucketMetric_withFilterSingleTag
=== PAUSE TestAccS3BucketMetric_withFilterSingleTag
=== RUN   TestAccS3BucketMetric_directoryBucket
=== PAUSE TestAccS3BucketMetric_directoryBucket
=== CONT  TestAccS3BucketMetric_basic
=== CONT  TestAccS3BucketMetric_withFilterAccessPointAndSingleTag
=== CONT  TestAccS3BucketMetric_withFilterMultipleTags
--- PASS: TestAccS3BucketMetric_basic (27.57s)
=== CONT  TestAccS3BucketMetric_directoryBucket
--- PASS: TestAccS3BucketMetric_directoryBucket (12.06s)
=== CONT  TestAccS3BucketMetric_withFilterSingleTag
--- PASS: TestAccS3BucketMetric_withFilterMultipleTags (44.50s)
=== CONT  TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndSingleTag
--- PASS: TestAccS3BucketMetric_withFilterAccessPointAndSingleTag (44.59s)
=== CONT  TestAccS3BucketMetric_withFilterAccessPointAndMultipleTags
--- PASS: TestAccS3BucketMetric_withFilterSingleTag (43.37s)
=== CONT  TestAccS3BucketMetric_withFilterAccessPointAndPrefix
--- PASS: TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndSingleTag (45.64s)
=== CONT  TestAccS3BucketMetric_withFilterAccessPoint
--- PASS: TestAccS3BucketMetric_withFilterAccessPointAndMultipleTags (45.59s)
=== CONT  TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndMultiTags
--- PASS: TestAccS3BucketMetric_withFilterAccessPointAndPrefix (43.30s)
=== CONT  TestAccS3BucketMetric_withEmptyFilter
--- PASS: TestAccS3BucketMetric_withEmptyFilter (2.67s)
=== CONT  TestAccS3BucketMetric_withFilterPrefixAndMultipleTags
--- PASS: TestAccS3BucketMetric_withFilterAccessPointAndPrefixAndMultiTags (45.42s)
=== CONT  TestAccS3BucketMetric_withFilterPrefixAndSingleTag
--- PASS: TestAccS3BucketMetric_withFilterAccessPoint (45.48s)
=== CONT  TestAccS3BucketMetric_withFilterPrefix
--- PASS: TestAccS3BucketMetric_withFilterPrefixAndMultipleTags (43.55s)
--- PASS: TestAccS3BucketMetric_withFilterPrefix (44.07s)
--- PASS: TestAccS3BucketMetric_withFilterPrefixAndSingleTag (44.13s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/s3	190.884s

@ewbankkit ewbankkit merged commit 93a43de into hashicorp:main Feb 6, 2024
43 checks passed
@github-actions github-actions bot added this to the v5.36.0 milestone Feb 6, 2024
@amartin-isp amartin-isp deleted the f-aws_s3_bucket_metric-add-filter-accesspoint branch February 6, 2024 18:03
Copy link

github-actions bot commented Feb 8, 2024

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

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 Mar 10, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Introduces or discusses updates to documentation. enhancement Requests to existing resources that expand the functionality or scope. service/s3 Issues and PRs that pertain to the s3 service. size/XL 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
Development

Successfully merging this pull request may close these issues.

None yet

2 participants