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/aws_cloudtrail: Increase IAM retry threshold from 15 seconds to 1 minute #5499

Merged
merged 2 commits into from
Aug 10, 2018

Conversation

bflad
Copy link
Contributor

@bflad bflad commented Aug 10, 2018

IAM can take upwards of a minute to fully propagate changes due to its eventually consistent nature. Found via daily acceptance testing:

        --- FAIL: TestAccAWSCloudTrail/Trail/cloudwatch (21.00s)
        	testing.go:518: Step 0 error: Error applying: 1 error occurred:
        			* aws_cloudtrail.test: 1 error occurred:
        			* aws_cloudtrail.test: InvalidCloudWatchLogsLogGroupArnException: Access denied. Check the permissions for your role.
        			status code: 400, request id: 7ce4eabc-65dc-4cd6-9e87-4240a5dde616

Changes proposed in this pull request:

  • Increase IAM retry threshold from 15 seconds to 1 minute during creation and update

Output from acceptance testing:

$ make testacc TEST=./aws TESTARGS='-run=TestAccAWSCloudTrail'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -run=TestAccAWSCloudTrail -timeout 120m
=== RUN   TestAccAWSCloudTrailServiceAccount_basic
--- PASS: TestAccAWSCloudTrailServiceAccount_basic (14.58s)
=== RUN   TestAccAWSCloudTrail_importBasic
--- PASS: TestAccAWSCloudTrail_importBasic (49.68s)
=== RUN   TestAccAWSCloudTrail
=== RUN   TestAccAWSCloudTrail/Trail
=== RUN   TestAccAWSCloudTrail/Trail/kmsKey
=== RUN   TestAccAWSCloudTrail/Trail/tags
=== RUN   TestAccAWSCloudTrail/Trail/eventSelector
=== RUN   TestAccAWSCloudTrail/Trail/basic
=== RUN   TestAccAWSCloudTrail/Trail/cloudwatch
=== RUN   TestAccAWSCloudTrail/Trail/enableLogging
=== RUN   TestAccAWSCloudTrail/Trail/isMultiRegion
=== RUN   TestAccAWSCloudTrail/Trail/logValidation
--- PASS: TestAccAWSCloudTrail (702.12s)
    --- PASS: TestAccAWSCloudTrail/Trail (702.12s)
        --- PASS: TestAccAWSCloudTrail/Trail/kmsKey (68.54s)
        --- PASS: TestAccAWSCloudTrail/Trail/tags (100.72s)
        --- PASS: TestAccAWSCloudTrail/Trail/eventSelector (91.26s)
        --- PASS: TestAccAWSCloudTrail/Trail/basic (74.80s)
        --- PASS: TestAccAWSCloudTrail/Trail/cloudwatch (93.76s)
        --- PASS: TestAccAWSCloudTrail/Trail/enableLogging (101.92s)
        --- PASS: TestAccAWSCloudTrail/Trail/isMultiRegion (96.86s)
        --- PASS: TestAccAWSCloudTrail/Trail/logValidation (74.27s)
=== RUN   TestAccAWSCloudTrail_include_global_service_events
--- PASS: TestAccAWSCloudTrail_include_global_service_events (45.22s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	812.286s

@bflad bflad added bug Addresses a defect in current functionality. service/cloudtrail Issues and PRs that pertain to the cloudtrail service. labels Aug 10, 2018
@bflad bflad requested a review from a team August 10, 2018 13:27
@ghost ghost added the size/XS Managed by automation to categorize the size of a PR. label Aug 10, 2018
Copy link
Contributor

@tombuildsstuff tombuildsstuff left a comment

Choose a reason for hiding this comment

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

LGTM

@bflad
Copy link
Contributor Author

bflad commented Aug 10, 2018

TravisCI failure unrelated, merging!

@bflad bflad merged commit 8a59154 into master Aug 10, 2018
@bflad bflad deleted the b-aws_cloudtrail-increase-iam-retry-threshold branch August 10, 2018 14:01
@bflad bflad added this to the v1.32.0 milestone Aug 10, 2018
bflad added a commit that referenced this pull request Aug 10, 2018
@bflad
Copy link
Contributor Author

bflad commented Aug 16, 2018

This has been released in version 1.32.0 of the AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

@ghost
Copy link

ghost commented Apr 4, 2020

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 and limited conversation to collaborators Apr 4, 2020
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. service/cloudtrail Issues and PRs that pertain to the cloudtrail service. size/XS 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