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

New resource: aws_globalaccelerator_custom_routing_accelerator #28922

Conversation

jlsalmon
Copy link
Contributor

@jlsalmon jlsalmon commented Jan 17, 2023

Description

This is a revival of #22162, rebased on main and refactored to conform to the latest SDK style.

Note: I have not added new resources for the AllowCustomRoutingTraffic and DenyCustromRoutingTraffic API methods, because it's currently not clear to me what the best way of approaching these might be. Also, my current use case doesn't require me to manage these via Terraform (my application is responsible for updating these at runtime). I would suggest these could be implemented in a follow-up PR.

Relations

Relates #16690.
Closes #22162.
Closes #27839.

References

Output from Acceptance Testing

$ make testacc TESTS=TestAccXXX PKG=ec2

...

@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 provider Pertains to the provider itself, rather than any interaction with AWS. service/globalaccelerator Issues and PRs that pertain to the globalaccelerator service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. size/XL Managed by automation to categorize the size of a PR. and removed tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. provider Pertains to the provider itself, rather than any interaction with AWS. service/globalaccelerator Issues and PRs that pertain to the globalaccelerator service. labels Jan 17, 2023
@jlsalmon jlsalmon changed the title aws_globalaccelerator_custom_routing_accelerator New resource: aws_globalaccelerator_custom_routing_accelerator Jan 17, 2023
@github-actions github-actions bot added the needs-triage Waiting for first response or review from a maintainer. label Jan 17, 2023
@github-actions
Copy link

Thank you for your contribution! 🚀

Please note that typically Go dependency changes are handled in this repository by dependabot or the maintainers. This is to prevent pull request merge conflicts and further delay reviews of contributions. Remove any changes to the go.mod or go.sum files and commit them into this pull request.

Additional details:

  • Check open pull requests with the dependencies label to view other dependency updates.
  • If this pull request includes an update the AWS Go SDK (or any other dependency) version, only updates submitted via dependabot will be merged. This pull request will need to remove these changes and will need to be rebased after the existing dependency update via dependabot has been merged for this pull request to be reviewed.
  • If this pull request is for supporting a new AWS service:
    • Ensure the new AWS service changes are following the Contributing Guide section on new services, in particular that the dependency addition and initial provider support are in a separate pull request from other changes (e.g. new resources). Contributions not following this item will not be reviewed until the changes are split.
    • If this pull request is already a separate pull request from the above item, you can ignore this message.

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 @jlsalmon 👋

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! 😃

@jlsalmon jlsalmon force-pushed the aws_globalaccelerator_custom_routing_accelerator branch from 6a4eda1 to 91c1de7 Compare January 17, 2023 01:33
@github-actions github-actions bot added provider Pertains to the provider itself, rather than any interaction with AWS. service/globalaccelerator Issues and PRs that pertain to the globalaccelerator service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. labels Jan 17, 2023
@jlsalmon jlsalmon force-pushed the aws_globalaccelerator_custom_routing_accelerator branch from 91c1de7 to 459d7c2 Compare January 17, 2023 01:45
@justinretzolk justinretzolk added new-resource Introduces a new resource. and removed needs-triage Waiting for first response or review from a maintainer. labels Jan 17, 2023
@amontalban
Copy link

Thank you for doing this @jlsalmon we cannot wait to have this in the AWS provider!

@justinretzolk let me know if you need some feedback on testing this.

@amontalban
Copy link

@johnsonaj @ewbankkit what is needed to get this merged? Currently we are using a bunch of local-exec resources to deal with custom global accelerators.

…ests.

Acceptance test output:

% make testacc TESTARGS='-run=TestAccGlobalAcceleratorCustomRoutingListener_' PKG=globalaccelerator ACCTEST_PARALLELISM=2
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/globalaccelerator/... -v -count 1 -parallel 2  -run=TestAccGlobalAcceleratorCustomRoutingListener_ -timeout 180m
=== RUN   TestAccGlobalAcceleratorCustomRoutingListener_basic
=== PAUSE TestAccGlobalAcceleratorCustomRoutingListener_basic
=== RUN   TestAccGlobalAcceleratorCustomRoutingListener_disappears
=== PAUSE TestAccGlobalAcceleratorCustomRoutingListener_disappears
=== CONT  TestAccGlobalAcceleratorCustomRoutingListener_basic
=== CONT  TestAccGlobalAcceleratorCustomRoutingListener_disappears
--- PASS: TestAccGlobalAcceleratorCustomRoutingListener_disappears (127.17s)
--- PASS: TestAccGlobalAcceleratorCustomRoutingListener_basic (161.18s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/globalaccelerator	169.708s
…ance tests.

Acceptance test output:

% make testacc TESTARGS='-run=TestAccGlobalAcceleratorCustomRoutingEndpointGroup_' PKG=globalaccelerator ACCTEST_PARALLELISM=2
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/globalaccelerator/... -v -count 1 -parallel 2  -run=TestAccGlobalAcceleratorCustomRoutingEndpointGroup_ -timeout 180m
=== RUN   TestAccGlobalAcceleratorCustomRoutingEndpointGroup_basic
=== PAUSE TestAccGlobalAcceleratorCustomRoutingEndpointGroup_basic
=== RUN   TestAccGlobalAcceleratorCustomRoutingEndpointGroup_disappears
=== PAUSE TestAccGlobalAcceleratorCustomRoutingEndpointGroup_disappears
=== CONT  TestAccGlobalAcceleratorCustomRoutingEndpointGroup_basic
=== CONT  TestAccGlobalAcceleratorCustomRoutingEndpointGroup_disappears
--- PASS: TestAccGlobalAcceleratorCustomRoutingEndpointGroup_disappears (170.89s)
--- PASS: TestAccGlobalAcceleratorCustomRoutingEndpointGroup_basic (184.21s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/globalaccelerator	190.387s
…obalAcceleratorCustomRoutingEndpointGroup_endpointConfiguration'.

Acceptance test output:

% make testacc TESTARGS='-run=TestAccGlobalAcceleratorCustomRoutingEndpointGroup_endpointConfiguration' PKG=globalaccelerator ACCTEST_PARALLELISM=2
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/globalaccelerator/... -v -count 1 -parallel 2  -run=TestAccGlobalAcceleratorCustomRoutingEndpointGroup_endpointConfiguration -timeout 180m
=== RUN   TestAccGlobalAcceleratorCustomRoutingEndpointGroup_endpointConfiguration
=== PAUSE TestAccGlobalAcceleratorCustomRoutingEndpointGroup_endpointConfiguration
=== CONT  TestAccGlobalAcceleratorCustomRoutingEndpointGroup_endpointConfiguration
--- PASS: TestAccGlobalAcceleratorCustomRoutingEndpointGroup_endpointConfiguration (649.93s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/globalaccelerator	655.144s
@ewbankkit ewbankkit added new-data-source Introduces a new data source. and removed provider Pertains to the provider itself, rather than any interaction with AWS. labels Mar 29, 2023
@github-actions github-actions bot added client-connections Pertains to the AWS Client and service connections. documentation Introduces or discusses updates to documentation. generators Relates to code generators. provider Pertains to the provider itself, rather than any interaction with AWS. and removed provider Pertains to the provider itself, rather than any interaction with AWS. labels Mar 29, 2023
@jlsalmon
Copy link
Contributor Author

Many thanks @ewbankkit for giving this some fresh momentum! 🙏

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=TestAccGlobalAccelerator' PKG=globalaccelerator ACCTEST_PARALLELISM=3 
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/globalaccelerator/... -v -count 1 -parallel 3  -run=TestAccGlobalAccelerator -timeout 180m
=== RUN   TestAccGlobalAcceleratorAcceleratorDataSource_basic
=== PAUSE TestAccGlobalAcceleratorAcceleratorDataSource_basic
=== RUN   TestAccGlobalAcceleratorAccelerator_basic
=== PAUSE TestAccGlobalAcceleratorAccelerator_basic
=== RUN   TestAccGlobalAcceleratorAccelerator_ipAddressType_dualStack
=== PAUSE TestAccGlobalAcceleratorAccelerator_ipAddressType_dualStack
=== RUN   TestAccGlobalAcceleratorAccelerator_byoip
=== PAUSE TestAccGlobalAcceleratorAccelerator_byoip
=== RUN   TestAccGlobalAcceleratorAccelerator_disappears
=== PAUSE TestAccGlobalAcceleratorAccelerator_disappears
=== RUN   TestAccGlobalAcceleratorAccelerator_update
=== PAUSE TestAccGlobalAcceleratorAccelerator_update
=== RUN   TestAccGlobalAcceleratorAccelerator_attributes
=== PAUSE TestAccGlobalAcceleratorAccelerator_attributes
=== RUN   TestAccGlobalAcceleratorAccelerator_tags
=== PAUSE TestAccGlobalAcceleratorAccelerator_tags
=== RUN   TestAccGlobalAcceleratorCustomRoutingAcceleratorDataSource_basic
=== PAUSE TestAccGlobalAcceleratorCustomRoutingAcceleratorDataSource_basic
=== RUN   TestAccGlobalAcceleratorCustomRoutingAccelerator_basic
=== PAUSE TestAccGlobalAcceleratorCustomRoutingAccelerator_basic
=== RUN   TestAccGlobalAcceleratorCustomRoutingAccelerator_disappears
=== PAUSE TestAccGlobalAcceleratorCustomRoutingAccelerator_disappears
=== RUN   TestAccGlobalAcceleratorCustomRoutingAccelerator_tags
=== PAUSE TestAccGlobalAcceleratorCustomRoutingAccelerator_tags
=== RUN   TestAccGlobalAcceleratorCustomRoutingAccelerator_update
=== PAUSE TestAccGlobalAcceleratorCustomRoutingAccelerator_update
=== RUN   TestAccGlobalAcceleratorCustomRoutingEndpointGroup_basic
=== PAUSE TestAccGlobalAcceleratorCustomRoutingEndpointGroup_basic
=== RUN   TestAccGlobalAcceleratorCustomRoutingEndpointGroup_disappears
=== PAUSE TestAccGlobalAcceleratorCustomRoutingEndpointGroup_disappears
=== RUN   TestAccGlobalAcceleratorCustomRoutingEndpointGroup_endpointConfiguration
=== PAUSE TestAccGlobalAcceleratorCustomRoutingEndpointGroup_endpointConfiguration
=== RUN   TestAccGlobalAcceleratorCustomRoutingListener_basic
=== PAUSE TestAccGlobalAcceleratorCustomRoutingListener_basic
=== RUN   TestAccGlobalAcceleratorCustomRoutingListener_disappears
=== PAUSE TestAccGlobalAcceleratorCustomRoutingListener_disappears
=== RUN   TestAccGlobalAcceleratorEndpointGroup_basic
=== PAUSE TestAccGlobalAcceleratorEndpointGroup_basic
=== RUN   TestAccGlobalAcceleratorEndpointGroup_disappears
=== PAUSE TestAccGlobalAcceleratorEndpointGroup_disappears
=== RUN   TestAccGlobalAcceleratorEndpointGroup_ALBEndpoint_clientIP
=== PAUSE TestAccGlobalAcceleratorEndpointGroup_ALBEndpoint_clientIP
=== RUN   TestAccGlobalAcceleratorEndpointGroup_instanceEndpoint
=== PAUSE TestAccGlobalAcceleratorEndpointGroup_instanceEndpoint
=== RUN   TestAccGlobalAcceleratorEndpointGroup_multiRegion
=== PAUSE TestAccGlobalAcceleratorEndpointGroup_multiRegion
=== RUN   TestAccGlobalAcceleratorEndpointGroup_portOverrides
=== PAUSE TestAccGlobalAcceleratorEndpointGroup_portOverrides
=== RUN   TestAccGlobalAcceleratorEndpointGroup_tcpHealthCheckProtocol
=== PAUSE TestAccGlobalAcceleratorEndpointGroup_tcpHealthCheckProtocol
=== RUN   TestAccGlobalAcceleratorEndpointGroup_update
=== PAUSE TestAccGlobalAcceleratorEndpointGroup_update
=== RUN   TestAccGlobalAcceleratorListener_basic
=== PAUSE TestAccGlobalAcceleratorListener_basic
=== RUN   TestAccGlobalAcceleratorListener_disappears
=== PAUSE TestAccGlobalAcceleratorListener_disappears
=== RUN   TestAccGlobalAcceleratorListener_update
=== PAUSE TestAccGlobalAcceleratorListener_update
=== CONT  TestAccGlobalAcceleratorAcceleratorDataSource_basic
=== CONT  TestAccGlobalAcceleratorCustomRoutingEndpointGroup_endpointConfiguration
=== CONT  TestAccGlobalAcceleratorCustomRoutingAcceleratorDataSource_basic
--- PASS: TestAccGlobalAcceleratorCustomRoutingAcceleratorDataSource_basic (78.48s)
=== CONT  TestAccGlobalAcceleratorCustomRoutingEndpointGroup_disappears
--- PASS: TestAccGlobalAcceleratorAcceleratorDataSource_basic (102.36s)
=== CONT  TestAccGlobalAcceleratorCustomRoutingEndpointGroup_basic
--- PASS: TestAccGlobalAcceleratorCustomRoutingEndpointGroup_disappears (158.80s)
=== CONT  TestAccGlobalAcceleratorCustomRoutingAccelerator_update
--- PASS: TestAccGlobalAcceleratorCustomRoutingEndpointGroup_basic (171.04s)
=== CONT  TestAccGlobalAcceleratorCustomRoutingAccelerator_tags
--- PASS: TestAccGlobalAcceleratorCustomRoutingAccelerator_update (122.01s)
=== CONT  TestAccGlobalAcceleratorCustomRoutingAccelerator_disappears
--- PASS: TestAccGlobalAcceleratorCustomRoutingAccelerator_tags (98.65s)
=== CONT  TestAccGlobalAcceleratorCustomRoutingAccelerator_basic
--- PASS: TestAccGlobalAcceleratorCustomRoutingAccelerator_disappears (81.47s)
=== CONT  TestAccGlobalAcceleratorEndpointGroup_multiRegion
--- PASS: TestAccGlobalAcceleratorCustomRoutingAccelerator_basic (86.07s)
=== CONT  TestAccGlobalAcceleratorListener_update
--- PASS: TestAccGlobalAcceleratorCustomRoutingEndpointGroup_endpointConfiguration (609.49s)
=== CONT  TestAccGlobalAcceleratorListener_disappears
--- PASS: TestAccGlobalAcceleratorListener_update (168.67s)
=== CONT  TestAccGlobalAcceleratorListener_basic
--- PASS: TestAccGlobalAcceleratorEndpointGroup_multiRegion (198.87s)
=== CONT  TestAccGlobalAcceleratorEndpointGroup_disappears
--- PASS: TestAccGlobalAcceleratorListener_disappears (142.72s)
=== CONT  TestAccGlobalAcceleratorEndpointGroup_update
--- PASS: TestAccGlobalAcceleratorListener_basic (144.53s)
=== CONT  TestAccGlobalAcceleratorEndpointGroup_instanceEndpoint
--- PASS: TestAccGlobalAcceleratorEndpointGroup_disappears (190.83s)
=== CONT  TestAccGlobalAcceleratorEndpointGroup_tcpHealthCheckProtocol
--- PASS: TestAccGlobalAcceleratorEndpointGroup_update (230.74s)
=== CONT  TestAccGlobalAcceleratorEndpointGroup_portOverrides
--- PASS: TestAccGlobalAcceleratorEndpointGroup_tcpHealthCheckProtocol (194.03s)
=== CONT  TestAccGlobalAcceleratorCustomRoutingListener_disappears
--- PASS: TestAccGlobalAcceleratorCustomRoutingListener_disappears (141.66s)
=== CONT  TestAccGlobalAcceleratorEndpointGroup_basic
--- PASS: TestAccGlobalAcceleratorEndpointGroup_portOverrides (228.17s)
=== CONT  TestAccGlobalAcceleratorAccelerator_disappears
=== CONT  TestAccGlobalAcceleratorAccelerator_tags
--- PASS: TestAccGlobalAcceleratorAccelerator_disappears (70.78s)
--- PASS: TestAccGlobalAcceleratorEndpointGroup_basic (192.83s)
=== CONT  TestAccGlobalAcceleratorAccelerator_attributes
--- PASS: TestAccGlobalAcceleratorAccelerator_tags (87.98s)
=== CONT  TestAccGlobalAcceleratorEndpointGroup_ALBEndpoint_clientIP
--- PASS: TestAccGlobalAcceleratorEndpointGroup_instanceEndpoint (729.22s)
=== CONT  TestAccGlobalAcceleratorAccelerator_update
--- PASS: TestAccGlobalAcceleratorAccelerator_attributes (265.62s)
=== CONT  TestAccGlobalAcceleratorAccelerator_ipAddressType_dualStack
--- PASS: TestAccGlobalAcceleratorAccelerator_update (145.80s)
=== CONT  TestAccGlobalAcceleratorCustomRoutingListener_basic
--- PASS: TestAccGlobalAcceleratorAccelerator_ipAddressType_dualStack (77.30s)
=== CONT  TestAccGlobalAcceleratorAccelerator_basic
--- PASS: TestAccGlobalAcceleratorAccelerator_basic (76.17s)
=== CONT  TestAccGlobalAcceleratorAccelerator_byoip
    accelerator_test.go:349: Environment variable GLOBALACCELERATOR_BYOIP_IPV4_ADDRESS not set
--- SKIP: TestAccGlobalAcceleratorAccelerator_byoip (0.14s)
--- PASS: TestAccGlobalAcceleratorCustomRoutingListener_basic (134.26s)
--- PASS: TestAccGlobalAcceleratorEndpointGroup_ALBEndpoint_clientIP (796.89s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/globalaccelerator	2172.714s

@ewbankkit
Copy link
Contributor

@jlsalmon @YvanGuidoin Thanks for the contribution 🎉 👏.

@ewbankkit ewbankkit merged commit 245f593 into hashicorp:main Mar 30, 2023
45 checks passed
@github-actions github-actions bot added this to the v4.61.0 milestone Mar 30, 2023
@amontalban
Copy link

Thank you very much @ewbankkit !!

@github-actions
Copy link

This functionality has been released in v4.61.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

github-actions bot commented May 1, 2023

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 May 1, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
client-connections Pertains to the AWS Client and service connections. documentation Introduces or discusses updates to documentation. generators Relates to code generators. new-data-source Introduces a new data source. new-resource Introduces a new resource. service/globalaccelerator Issues and PRs that pertain to the globalaccelerator 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.

[Enhancement]: Add support for a DualStackDnsName attribute in aws_globalaccelerator_accelerator
5 participants