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

provider: Support default tags (resources aws_c*) #18728

Merged
merged 6 commits into from
Apr 21, 2021
Merged

Conversation

bflad
Copy link
Contributor

@bflad bflad commented Apr 9, 2021

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

Reference: #7926

Output from acceptance testing: Will be handled via CI, review, and daily acceptance testing

@bflad bflad requested a review from a team as a code owner April 9, 2021 21:05
@bflad bflad added the enhancement Requests to existing resources that expand the functionality or scope. label Apr 9, 2021
@ghost ghost added size/XL Managed by automation to categorize the size of a PR. service/cloud9 Issues and PRs that pertain to the cloud9 service. service/cloudformation Issues and PRs that pertain to the cloudformation service. service/cloudfront Issues and PRs that pertain to the cloudfront service. service/cloudtrail Issues and PRs that pertain to the cloudtrail service. service/cloudwatchlogs service/cloudwatch Issues and PRs that pertain to the cloudwatch service. service/codeartifact Issues and PRs that pertain to the codeartifact service. service/codebuild Issues and PRs that pertain to the codebuild service. service/codecommit Issues and PRs that pertain to the codecommit service. service/codepipeline Issues and PRs that pertain to the codepipeline service. service/codestarnotifications Issues and PRs that pertain to the codestarnotifications service. service/codestarconnections Issues and PRs that pertain to the codestarconnections service. service/configservice Issues and PRs that pertain to the configservice service. service/ec2 Issues and PRs that pertain to the ec2 service. documentation Introduces or discusses updates to documentation. labels Apr 9, 2021
@ghost ghost added the service/cloudhsmv2 Issues and PRs that pertain to the cloudhsmv2 service. label Apr 14, 2021
Copy link
Contributor

@anGie44 anGie44 left a comment

Choose a reason for hiding this comment

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

Just a change needed in the user_pool resource + rebase, otherwise LGTM

Output from acceptance testing:

```
--- PASS: TestAccAWSCognitoUserPool_basic (32.72s)
--- PASS: TestAccAWSCognitoUserPool_disappears (23.07s)
--- PASS: TestAccAWSCognitoUserPool_MfaConfiguration_SmsConfiguration (90.95s)
--- PASS: TestAccAWSCognitoUserPool_MfaConfiguration_SmsConfigurationAndSoftwareTokenMfaConfiguration (81.96s)
--- PASS: TestAccAWSCognitoUserPool_MfaConfiguration_SmsConfigurationToSoftwareTokenMfaConfiguration (52.93s)
--- PASS: TestAccAWSCognitoUserPool_MfaConfiguration_SoftwareTokenMfaConfiguration (46.95s)
--- PASS: TestAccAWSCognitoUserPool_MfaConfiguration_SoftwareTokenMfaConfigurationToSmsConfiguration (47.99s)
--- PASS: TestAccAWSCognitoUserPool_recovery (49.48s)
--- PASS: TestAccAWSCognitoUserPool_schemaAttributes (52.07s)
--- PASS: TestAccAWSCognitoUserPool_schemaAttributesModified (32.71s)
--- PASS: TestAccAWSCognitoUserPool_schemaAttributesRemoved (32.71s)
--- PASS: TestAccAWSCognitoUserPool_SmsAuthenticationMessage (45.81s)
--- PASS: TestAccAWSCognitoUserPool_SmsConfiguration (80.39s)
--- PASS: TestAccAWSCognitoUserPool_SmsConfiguration_ExternalId (75.83s)
--- PASS: TestAccAWSCognitoUserPool_SmsConfiguration_SnsCallerArn (73.17s)
--- PASS: TestAccAWSCognitoUserPool_SmsVerificationMessage (53.22s)
--- PASS: TestAccAWSCognitoUserPool_update (86.20s)
--- PASS: TestAccAWSCognitoUserPool_withAdminCreateUserConfiguration (43.93s)
--- PASS: TestAccAWSCognitoUserPool_withAdminCreateUserConfigurationAndPasswordPolicy (24.82s)
--- PASS: TestAccAWSCognitoUserPool_withAdvancedSecurityMode (69.48s)
--- PASS: TestAccAWSCognitoUserPool_withAliasAttributes (52.96s)
--- PASS: TestAccAWSCognitoUserPool_withDeviceConfiguration (43.98s)
--- PASS: TestAccAWSCognitoUserPool_withEmailConfiguration (28.09s)
--- PASS: TestAccAWSCognitoUserPool_withEmailVerificationMessage (44.74s)
--- PASS: TestAccAWSCognitoUserPool_withLambdaConfig (79.27s)
--- PASS: TestAccAWSCognitoUserPool_withPasswordPolicy (53.72s)
--- PASS: TestAccAWSCognitoUserPool_withTags (70.01s)
--- PASS: TestAccAWSCognitoUserPool_withUsernameConfiguration (53.49s)
--- PASS: TestAccAWSCognitoUserPool_withVerificationMessageTemplate (53.61s)
--- SKIP: TestAccAWSCognitoUserPool_withEmailConfigurationSource (0.00s)
```
@bflad
Copy link
Contributor Author

bflad commented Apr 19, 2021

Good catch on aws_cognito_user_pool -- updated and verified since the logic is a little different than other resources:

Output from acceptance testing:

--- PASS: TestAccAWSCognitoUserPool_basic (32.72s)
--- PASS: TestAccAWSCognitoUserPool_disappears (23.07s)
--- PASS: TestAccAWSCognitoUserPool_MfaConfiguration_SmsConfiguration (90.95s)
--- PASS: TestAccAWSCognitoUserPool_MfaConfiguration_SmsConfigurationAndSoftwareTokenMfaConfiguration (81.96s)
--- PASS: TestAccAWSCognitoUserPool_MfaConfiguration_SmsConfigurationToSoftwareTokenMfaConfiguration (52.93s)
--- PASS: TestAccAWSCognitoUserPool_MfaConfiguration_SoftwareTokenMfaConfiguration (46.95s)
--- PASS: TestAccAWSCognitoUserPool_MfaConfiguration_SoftwareTokenMfaConfigurationToSmsConfiguration (47.99s)
--- PASS: TestAccAWSCognitoUserPool_recovery (49.48s)
--- PASS: TestAccAWSCognitoUserPool_schemaAttributes (52.07s)
--- PASS: TestAccAWSCognitoUserPool_schemaAttributesModified (32.71s)
--- PASS: TestAccAWSCognitoUserPool_schemaAttributesRemoved (32.71s)
--- PASS: TestAccAWSCognitoUserPool_SmsAuthenticationMessage (45.81s)
--- PASS: TestAccAWSCognitoUserPool_SmsConfiguration (80.39s)
--- PASS: TestAccAWSCognitoUserPool_SmsConfiguration_ExternalId (75.83s)
--- PASS: TestAccAWSCognitoUserPool_SmsConfiguration_SnsCallerArn (73.17s)
--- PASS: TestAccAWSCognitoUserPool_SmsVerificationMessage (53.22s)
--- PASS: TestAccAWSCognitoUserPool_update (86.20s)
--- PASS: TestAccAWSCognitoUserPool_withAdminCreateUserConfiguration (43.93s)
--- PASS: TestAccAWSCognitoUserPool_withAdminCreateUserConfigurationAndPasswordPolicy (24.82s)
--- PASS: TestAccAWSCognitoUserPool_withAdvancedSecurityMode (69.48s)
--- PASS: TestAccAWSCognitoUserPool_withAliasAttributes (52.96s)
--- PASS: TestAccAWSCognitoUserPool_withDeviceConfiguration (43.98s)
--- PASS: TestAccAWSCognitoUserPool_withEmailConfiguration (28.09s)
--- PASS: TestAccAWSCognitoUserPool_withEmailVerificationMessage (44.74s)
--- PASS: TestAccAWSCognitoUserPool_withLambdaConfig (79.27s)
--- PASS: TestAccAWSCognitoUserPool_withPasswordPolicy (53.72s)
--- PASS: TestAccAWSCognitoUserPool_withTags (70.01s)
--- PASS: TestAccAWSCognitoUserPool_withUsernameConfiguration (53.49s)
--- PASS: TestAccAWSCognitoUserPool_withVerificationMessageTemplate (53.61s)
--- SKIP: TestAccAWSCognitoUserPool_withEmailConfigurationSource (0.00s)

Comment on lines +240 to +241
"tags": tagsSchema(),
"tags_all": tagsSchemaComputed(),
Copy link
Contributor

@anGie44 anGie44 Apr 20, 2021

Choose a reason for hiding this comment

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

i missed this during first review @bflad : the Create method needs to pass in the new merged tags via nested func getAwsCloudWatchPutMetricAlarmInput

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated in 11eb3f1

@@ -38,8 +38,11 @@ func resourceAwsConfigAggregateAuthorization() *schema.Resource {
Required: true,
ForceNew: true,
},
"tags": tagsSchema(),
"tags": tagsSchema(),
Copy link
Contributor

Choose a reason for hiding this comment

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

missed on first review: resourceAwsConfigAggregateAuthorizationPut needs to be updated as well to pass in the new merged tags

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated in 11eb3f1

@bflad bflad merged commit be1b29d into main Apr 21, 2021
@bflad bflad deleted the f-default-tags-c branch April 21, 2021 17:12
@github-actions github-actions bot added this to the v3.38.0 milestone Apr 21, 2021
@ghost
Copy link

ghost commented Apr 30, 2021

This has been released in version 3.38.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!

@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 May 31, 2021
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/cloud9 Issues and PRs that pertain to the cloud9 service. service/cloudformation Issues and PRs that pertain to the cloudformation service. service/cloudfront Issues and PRs that pertain to the cloudfront service. service/cloudhsmv2 Issues and PRs that pertain to the cloudhsmv2 service. service/cloudtrail Issues and PRs that pertain to the cloudtrail service. service/cloudwatch Issues and PRs that pertain to the cloudwatch service. service/codeartifact Issues and PRs that pertain to the codeartifact service. service/codebuild Issues and PRs that pertain to the codebuild service. service/codecommit Issues and PRs that pertain to the codecommit service. service/codepipeline Issues and PRs that pertain to the codepipeline service. service/codestarconnections Issues and PRs that pertain to the codestarconnections service. service/codestarnotifications Issues and PRs that pertain to the codestarnotifications service. service/configservice Issues and PRs that pertain to the configservice service. service/ec2 Issues and PRs that pertain to the ec2 service. size/XL Managed by automation to categorize the size of a PR.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants