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

resource/dms_endpoint: add support for extraConnectionAttributes in create/read ops and handle diffs #16827

Merged
merged 1 commit into from
Jan 12, 2021

Conversation

anGie44
Copy link
Contributor

@anGie44 anGie44 commented Dec 17, 2020

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

Closes #8009
Closes #8000

Release note for CHANGELOG:

resource/dms_endpoint: add support for `extra_connection_attributes` on create and read and prevent diffs between the API response and configured value

Output from acceptance testing:

--- PASS: TestAccAwsDmsEndpoint_Elasticsearch (172.07s)
--- PASS: TestAccAwsDmsEndpoint_Elasticsearch_ErrorRetryDuration (181.10s)
--- PASS: TestAccAwsDmsEndpoint_S3_ExtraConnectionAttributes (192.49s)
--- PASS: TestAccAwsDmsEndpoint_Elasticsearch_ExtraConnectionAttributes (192.98s)
--- PASS: TestAccAwsDmsEndpoint_MongoDb (193.97s)
--- PASS: TestAccAwsDmsEndpoint_Elasticsearch_FullLoadErrorPercentage (202.25s)
--- PASS: TestAccAwsDmsEndpoint_Db2 (222.04s)
--- PASS: TestAccAwsDmsEndpoint_DocDB (233.58s)
--- PASS: TestAccAwsDmsEndpoint_basic (233.69s)
--- PASS: TestAccAwsDmsEndpoint_Kafka_Broker (242.55s)
--- PASS: TestAccAwsDmsEndpoint_DynamoDb (242.66s)
--- PASS: TestAccAwsDmsEndpoint_Kafka_Topic (244.66s)
--- PASS: TestAccAwsDmsEndpoint_S3 (255.30s)
--- PASS: TestAccAwsDmsEndpoint_MongoDb_Update (268.29s)
--- PASS: TestAccAwsDmsEndpoint_Kinesis (276.50s)

@anGie44 anGie44 requested a review from a team as a code owner December 17, 2020 20:18
@ghost ghost added size/XL Managed by automation to categorize the size of a PR. service/databasemigrationservice tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. labels Dec 17, 2020
@anGie44 anGie44 added the bug Addresses a defect in current functionality. label Dec 17, 2020
@@ -396,6 +403,7 @@ func resourceAwsDmsEndpointCreate(d *schema.ResourceData, meta interface{}) erro
BucketFolder: aws.String(d.Get("s3_settings.0.bucket_folder").(string)),
BucketName: aws.String(d.Get("s3_settings.0.bucket_name").(string)),
CompressionType: aws.String(d.Get("s3_settings.0.compression_type").(string)),
DatePartitionEnabled: aws.Bool(d.Get("s3_settings.0.date_partition_enabled").(bool)),
Copy link
Contributor Author

Choose a reason for hiding this comment

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

the API returns this value in extra_connection_attributes by default so adding it to the schema helps calculating the diff appropriately

@bflad bflad self-assigned this Jan 12, 2021
Copy link
Member

@bflad bflad left a comment

Choose a reason for hiding this comment

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

Great! 🚀 Could you also check issue #8000 and PRs #5607 / #14620 since they look similar?

Output from acceptance testing in AWS Commercial:

--- PASS: TestAccAwsDmsEndpoint_basic (43.30s)
--- PASS: TestAccAwsDmsEndpoint_Db2 (45.39s)
--- PASS: TestAccAwsDmsEndpoint_DocDB (43.68s)
--- PASS: TestAccAwsDmsEndpoint_DynamoDb (53.37s)
--- PASS: TestAccAwsDmsEndpoint_Elasticsearch (41.06s)
--- PASS: TestAccAwsDmsEndpoint_Elasticsearch_ErrorRetryDuration (41.01s)
--- PASS: TestAccAwsDmsEndpoint_Elasticsearch_ExtraConnectionAttributes (47.91s)
--- PASS: TestAccAwsDmsEndpoint_Elasticsearch_FullLoadErrorPercentage (40.98s)
--- PASS: TestAccAwsDmsEndpoint_Kafka_Broker (45.37s)
--- PASS: TestAccAwsDmsEndpoint_Kafka_Topic (44.68s)
--- PASS: TestAccAwsDmsEndpoint_Kinesis (79.14s)
--- PASS: TestAccAwsDmsEndpoint_MongoDb (27.42s)
--- PASS: TestAccAwsDmsEndpoint_MongoDb_Update (51.38s)
--- PASS: TestAccAwsDmsEndpoint_S3 (55.06s)
--- PASS: TestAccAwsDmsEndpoint_S3_ExtraConnectionAttributes (40.85s)

Output from acceptance testing in AWS GovCloud (US):

--- PASS: TestAccAwsDmsEndpoint_basic (52.91s)
--- PASS: TestAccAwsDmsEndpoint_Db2 (51.46s)
--- PASS: TestAccAwsDmsEndpoint_DocDB (50.24s)
--- PASS: TestAccAwsDmsEndpoint_DynamoDb (58.01s)
--- PASS: TestAccAwsDmsEndpoint_Elasticsearch (46.42s)
--- PASS: TestAccAwsDmsEndpoint_Elasticsearch_ErrorRetryDuration (44.74s)
--- PASS: TestAccAwsDmsEndpoint_Elasticsearch_ExtraConnectionAttributes (47.78s)
--- PASS: TestAccAwsDmsEndpoint_Elasticsearch_FullLoadErrorPercentage (47.42s)
--- PASS: TestAccAwsDmsEndpoint_Kafka_Broker (52.21s)
--- PASS: TestAccAwsDmsEndpoint_Kafka_Topic (51.37s)
--- PASS: TestAccAwsDmsEndpoint_Kinesis (87.21s)
--- PASS: TestAccAwsDmsEndpoint_MongoDb (37.55s)
--- PASS: TestAccAwsDmsEndpoint_MongoDb_Update (55.80s)
--- PASS: TestAccAwsDmsEndpoint_S3 (57.88s)
--- PASS: TestAccAwsDmsEndpoint_S3_ExtraConnectionAttributes (47.20s)

@anGie44 anGie44 added this to the v3.24.0 milestone Jan 12, 2021
@anGie44 anGie44 merged commit edb235e into master Jan 12, 2021
@anGie44 anGie44 deleted the b-dms-endpoint-extra-connection-attr branch January 12, 2021 20:40
anGie44 added a commit that referenced this pull request Jan 12, 2021
@ghost
Copy link

ghost commented Jan 15, 2021

This has been released in version 3.24.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 for triage. Thanks!

@ghost
Copy link

ghost commented Feb 12, 2021

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!

@ghost ghost locked as resolved and limited conversation to collaborators Feb 12, 2021
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. 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
2 participants