Skip to content

r/aws_prometheus_scraper_logging_configuration#47466

Open
bonclay7 wants to merge 6 commits intohashicorp:mainfrom
bonclay7:f-aws_prometheus_scraper_logging_configuration
Open

r/aws_prometheus_scraper_logging_configuration#47466
bonclay7 wants to merge 6 commits intohashicorp:mainfrom
bonclay7:f-aws_prometheus_scraper_logging_configuration

Conversation

@bonclay7
Copy link
Copy Markdown
Contributor

Rollback Plan

If a change needs to be reverted, we will publish an updated version of the library.

Changes to Security Controls

Are there any changes to security controls (access controls, encryption, logging) in this pull request? If so, explain.

Description

Relations

Closes #45126

References

Output from Acceptance Testing

% make testacc TESTS=TestAccXXX PKG=ec2
make fmt && make build && make testacc TESTARGS='-run=TestAccAMPScraperLoggingConfiguration_' PKG=amp ACCTEST_PARALLELISM=1 AWS_REGION=us-east-1 AWS_DEFAULT_REGION=us-east-1
make: Building provider...
make: Verifying source code with gofmt...
==> Checking that code complies with gofmt requirements...
make: Running acceptance tests on branch: 🌿 f-aws_prometheus_scraper_logging_configuration 🌿...
TF_ACC=1 go test ./internal/service/amp/... -v -count 1 -parallel 1  -run=TestAccAMPScraperLoggingConfiguration_ -timeout 360m -vet=off
2026/04/15 11:59:55 Creating Terraform AWS Provider (SDKv2-style)...
2026/04/15 11:59:55 Initializing Terraform AWS Provider (SDKv2-style)...
=== RUN   TestAccAMPScraperLoggingConfiguration_basic
=== PAUSE TestAccAMPScraperLoggingConfiguration_basic
=== RUN   TestAccAMPScraperLoggingConfiguration_scraperComponents
=== PAUSE TestAccAMPScraperLoggingConfiguration_scraperComponents
=== RUN   TestAccAMPScraperLoggingConfiguration_disappears
=== PAUSE TestAccAMPScraperLoggingConfiguration_disappears
=== CONT  TestAccAMPScraperLoggingConfiguration_basic
--- PASS: TestAccAMPScraperLoggingConfiguration_basic (2639.04s)
=== CONT  TestAccAMPScraperLoggingConfiguration_disappears
--- PASS: TestAccAMPScraperLoggingConfiguration_disappears (2721.87s)
=== CONT  TestAccAMPScraperLoggingConfiguration_scraperComponents
--- PASS: TestAccAMPScraperLoggingConfiguration_scraperComponents (2684.64s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/amp        8045.748s
...

Probably should rise ACCTEST_PARALLELISM if you want to reproduce

bonclay7 and others added 3 commits March 31, 2026 16:48
Implements hashicorp#45126. Adds a new resource for managing Amazon Managed
Service for Prometheus scraper logging configuration via the
UpdateScraperLoggingConfiguration API (upsert pattern, since no
dedicated create endpoint exists).
@bonclay7 bonclay7 requested a review from a team as a code owner April 15, 2026 15:15
@github-actions
Copy link
Copy Markdown
Contributor

Community Guidelines

This comment is added to every new Pull Request to provide quick reference to how the Terraform AWS Provider is maintained. Please review the information below, and thank you for contributing to the community that keeps the provider thriving! 🚀

Voting for Prioritization

  • Please vote on this Pull Request by adding a 👍 reaction to the original post to help the community and maintainers prioritize it.
  • Please see our prioritization guide for additional information on how the maintainers handle prioritization.
  • Please do not leave +1 or other comments that do not add relevant new information or questions; they generate extra noise for others following the Pull Request and do not help prioritize the request.

Pull Request Authors

  • Review the contribution guide relating to the type of change you are making to ensure all of the necessary steps have been taken.
  • Whether or not the branch has been rebased will not impact prioritization, but doing so is always a welcome surprise.

@dosubot dosubot Bot added the new-resource Introduces a new resource. label Apr 15, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 15, 2026

✅ Thank you for correcting the previously detected issues! The maintainers appreciate your efforts to make the review process as smooth as possible.

@github-actions github-actions Bot added needs-triage Waiting for first response or review from a maintainer. documentation Introduces or discusses updates to documentation. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. generators Relates to code generators. service/amp Issues and PRs that pertain to the amp service. size/XL Managed by automation to categorize the size of a PR. partner Contribution from a partner. labels Apr 15, 2026
@justinretzolk justinretzolk removed the needs-triage Waiting for first response or review from a maintainer. label Apr 15, 2026
@github-actions github-actions Bot added the linter Pertains to changes to or issues with the various linters. label Apr 15, 2026
Comment thread internal/service/amp/scraper_logging_configuration.go Outdated
bonclay7 added a commit to bonclay7/terraform-provider-aws that referenced this pull request Apr 17, 2026
- Resource schema with scraper_id, logging_destination, and optional scraper_components
- CRUD implementation with smerr patterns, proper input declarations, and waiters
- Manual expand/flatten for scraper_components with autoflex bypass
- Conditional flatten to avoid API-defaulted components overriding user config
- VCR-compatible acceptance tests (basic, disappears, scraperComponents)
- Documentation with examples, argument/attribute reference, timeouts, and import
- Changelog entry for PR hashicorp#47466
- Resource schema with scraper_id, logging_destination, and optional scraper_components
- CRUD implementation with smerr patterns, proper input declarations, and waiters
- Manual expand/flatten for scraper_components with autoflex bypass
- Conditional flatten to avoid API-defaulted components overriding user config
- VCR-compatible acceptance tests (basic, disappears, scraperComponents)
- Documentation with examples, argument/attribute reference, timeouts, and import
- Changelog entry for PR hashicorp#47466
@bonclay7 bonclay7 force-pushed the f-aws_prometheus_scraper_logging_configuration branch from aca4ccb to 184b529 Compare April 17, 2026 14:27
@bonclay7
Copy link
Copy Markdown
Contributor Author

bonclay7 commented Apr 17, 2026

% make fmt && make build && make testacc TESTARGS='-run=TestAccAMPScraperLoggingConfiguration_' PKG=amp ACCTEST_PARALLELISM=4 AWS_REGION=us-east-1 AWS_DEFAULT_REGION=us-east-1

  make: Fixing source code with gofmt...                                                                                                  
  gofmt -s -w ./internal ./names ./.ci/providerlint/helper ./.ci/providerlint/main.go ./.ci/providerlint/passes                           
  make: Verifying source code with gofmt...                                                                                               
  ==> Checking that code complies with gofmt requirements...                                                                              
  make: Building provider...                                                                                                              
  make: Verifying source code with gofmt...                                                                                               
  ==> Checking that code complies with gofmt requirements...                                                                              
  make: Running acceptance tests on branch: 🌿 f-aws_prometheus_scraper_logging_configuration 🌿...                                       
  TF_ACC=1 go1.26.2 test ./internal/service/amp/... -v -count 1 -parallel 4  -run=TestAccAMPScraperLoggingConfiguration_ -timeout 360m    
  -vet=off                                                                                                                                
  2026/04/17 12:38:37 Creating Terraform AWS Provider (SDKv2-style)...                                                                    
  2026/04/17 12:38:37 Initializing Terraform AWS Provider (SDKv2-style)...                                                                
  === RUN   TestAccAMPScraperLoggingConfiguration_basic                                                                                   
  === PAUSE TestAccAMPScraperLoggingConfiguration_basic                                                                                   
  === RUN   TestAccAMPScraperLoggingConfiguration_scraperComponents                                                                       
  === PAUSE TestAccAMPScraperLoggingConfiguration_scraperComponents                                                                       
  === RUN   TestAccAMPScraperLoggingConfiguration_disappears                                                                              
  === PAUSE TestAccAMPScraperLoggingConfiguration_disappears                                                                              
  === CONT  TestAccAMPScraperLoggingConfiguration_basic                                                                                   
  === CONT  TestAccAMPScraperLoggingConfiguration_disappears                                                                              
  === CONT  TestAccAMPScraperLoggingConfiguration_scraperComponents                                                                       
  --- PASS: TestAccAMPScraperLoggingConfiguration_scraperComponents (2390.58s)                                                            
  --- PASS: TestAccAMPScraperLoggingConfiguration_basic (2491.39s)                                                                        
  --- PASS: TestAccAMPScraperLoggingConfiguration_disappears (2521.05s)                                                                   
  PASS                                                                                                                                    
  ok    github.com/hashicorp/terraform-provider-aws/internal/service/amp  2521.215s 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Introduces or discusses updates to documentation. generators Relates to code generators. linter Pertains to changes to or issues with the various linters. new-resource Introduces a new resource. partner Contribution from a partner. service/amp Issues and PRs that pertain to the amp 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.

New resource: aws_prometheus_scraper_logging_configuration

3 participants