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

Support AWS AppFlow: aws_appflow_connector_profile resource #23892

Merged
merged 64 commits into from
May 13, 2022

Conversation

szemek
Copy link
Contributor

@szemek szemek commented Mar 27, 2022

Community Note

  • Please vote on this pull request by adding a 👍 reaction to the original pull request comment to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for pull request followers and do not help prioritize the request

Relates #16253

@github-actions github-actions bot added size/XL Managed by automation to categorize the size of a PR. documentation Introduces or discusses updates to documentation. github_actions Pull requests that update Github_actions code provider Pertains to the provider itself, rather than any interaction with AWS. repository Repository modifications; GitHub Actions, developer docs, issue templates, codeowners, changelog. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. needs-triage Waiting for first response or review from a maintainer. labels Mar 27, 2022
@szemek szemek mentioned this pull request Mar 27, 2022
@zhelding zhelding self-assigned this Mar 28, 2022
@justinretzolk justinretzolk removed the needs-triage Waiting for first response or review from a maintainer. label Mar 30, 2022
@github-actions github-actions bot added service/appflow Issues and PRs that pertain to the appflow service. and removed repository Repository modifications; GitHub Actions, developer docs, issue templates, codeowners, changelog. github_actions Pull requests that update Github_actions code labels May 8, 2022
zhelding and others added 20 commits May 12, 2022 17:52
"name" is only unique to a particular AWS account. To ensure uniqueness
of IDs across multiple AWS accounts, we use "arn" instead.
Since these functions are not exported from the service package, we do
not generally include the service in these function names
This reverts commit 5918cea.

Connector profiles do not appear to support tagging.

The following AWS CLI operation errors out:
aws appflow tag-resource --resource-arn <profile_arn> --tags KeyName1=string

Returns "Invalud input resource arn"
@zhelding
Copy link
Contributor

Hi @szemek. Thank you so much for your work on this! We really appreciate your contribution here -- as well as your past PRs upon which it is based (i.e. #18183 + #19543).

Thank you also for keeping up with my numerous edits and tweaking the docs as necessary; it's been very helpful in closing things out here.

The major edits here revolved around acceptance testing: namely, our inability to reliably perform acceptance tests that rely upon non-AWS resources. As a result, we can only test connector profiles of connector_type = "Redshift".

Limiting ourselves to Redshift: we're able to get some passing acceptance tests!

Other changes mostly focused on adding a couple of missing attributes (i.e. config properties for SAPOData or custom connector profiles) -- and resolving build errors resulting from edits.

Code Notes

Context-Dependent Structs

As with AppFlow flows (#24017), AppFlow connector profiles have certain attributes representing structures with "context-dependent" members. As the underlying types of these structures are undocumented, we are not able to support their use.

Credentials are Write-Only

Credentials set by CreateConnectorProfile are not returned by any AppFlow API operation. Instead, a credentialsArn field is returned. It may be possible to somehow read from the resource to which credentialsArn directs us, but this would require further investigation.

Once we're green on all checks, I'll confirm the acceptance tests are still passing one last time, and then we can get this merged!

@zhelding
Copy link
Contributor

Acceptance tests passing on latest commit 7238c86:

❯ make testacc TESTS=TestAccAppFlowConnectorProfile PKG=appflow
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/appflow/... -v -count 1 -parallel 20 -run='TestAccAppFlowConnectorProfile'  -timeout 180m
=== RUN   TestAccAppFlowConnectorProfile_basic
=== PAUSE TestAccAppFlowConnectorProfile_basic
=== RUN   TestAccAppFlowConnectorProfile_update
=== PAUSE TestAccAppFlowConnectorProfile_update
=== RUN   TestAccAppFlowConnectorProfile_disappears
=== PAUSE TestAccAppFlowConnectorProfile_disappears
=== CONT  TestAccAppFlowConnectorProfile_basic
=== CONT  TestAccAppFlowConnectorProfile_disappears
=== CONT  TestAccAppFlowConnectorProfile_update
--- PASS: TestAccAppFlowConnectorProfile_disappears (219.21s)
--- PASS: TestAccAppFlowConnectorProfile_update (257.46s)
--- PASS: TestAccAppFlowConnectorProfile_basic (259.99s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/appflow    260.049s

Merging! 🚀

@zhelding zhelding merged commit c29c796 into hashicorp:main May 13, 2022
@github-actions github-actions bot added this to the v4.14.0 milestone May 13, 2022
@szemek szemek deleted the f-appflow-connector-profile branch May 13, 2022 09:24
@github-actions
Copy link

This functionality has been released in v4.14.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 Jun 13, 2022
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. provider Pertains to the provider itself, rather than any interaction with AWS. service/appflow Issues and PRs that pertain to the appflow 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

3 participants