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

Final retries for ELB resources #9765

Merged
merged 1 commit into from
Aug 16, 2019
Merged

Final retries for ELB resources #9765

merged 1 commit into from
Aug 16, 2019

Conversation

ryndaniels
Copy link
Contributor

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" comments, they generate extra noise for pull request followers and do not help prioritize the request

Relates #7873

Release note for CHANGELOG:

BUG FIXES
* resource/aws_elb: Final retries after timeouts creating and updating ELBs
* resource/aws_elb_attachment: Final retry after timout creating ELB attachment

Output from acceptance testing:

NOTE test failure is not new

$ make testacc TESTARGS="-run=TestAccAWSELB"                         
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./... -v -parallel 20 -run=TestAccAWSELB -timeout 120m
?       github.com/terraform-providers/terraform-provider-aws   [no test files]
=== RUN   TestAccAWSELBAttachment_basic
=== PAUSE TestAccAWSELBAttachment_basic
=== RUN   TestAccAWSELBAttachment_drift
=== PAUSE TestAccAWSELBAttachment_drift
=== RUN   TestAccAWSELB_importBasic
=== PAUSE TestAccAWSELB_importBasic
=== RUN   TestAccAWSELB_basic
=== PAUSE TestAccAWSELB_basic
=== RUN   TestAccAWSELB_disappears
=== PAUSE TestAccAWSELB_disappears
=== RUN   TestAccAWSELB_fullCharacterRange
=== PAUSE TestAccAWSELB_fullCharacterRange
=== RUN   TestAccAWSELB_AccessLogs_enabled
=== PAUSE TestAccAWSELB_AccessLogs_enabled
=== RUN   TestAccAWSELB_AccessLogs_disabled
=== PAUSE TestAccAWSELB_AccessLogs_disabled
=== RUN   TestAccAWSELB_namePrefix
=== PAUSE TestAccAWSELB_namePrefix
=== RUN   TestAccAWSELB_generatedName
=== PAUSE TestAccAWSELB_generatedName
=== RUN   TestAccAWSELB_generatesNameForZeroValue
=== PAUSE TestAccAWSELB_generatesNameForZeroValue
=== RUN   TestAccAWSELB_availabilityZones
=== PAUSE TestAccAWSELB_availabilityZones
=== RUN   TestAccAWSELB_tags
=== PAUSE TestAccAWSELB_tags
=== RUN   TestAccAWSELB_Listener_SSLCertificateID_IAMServerCertificate
=== PAUSE TestAccAWSELB_Listener_SSLCertificateID_IAMServerCertificate
=== RUN   TestAccAWSELB_swap_subnets
=== PAUSE TestAccAWSELB_swap_subnets
=== RUN   TestAccAWSELB_InstanceAttaching
=== PAUSE TestAccAWSELB_InstanceAttaching
=== RUN   TestAccAWSELB_listener
=== PAUSE TestAccAWSELB_listener
=== RUN   TestAccAWSELB_HealthCheck
=== PAUSE TestAccAWSELB_HealthCheck
=== RUN   TestAccAWSELBUpdate_HealthCheck
=== PAUSE TestAccAWSELBUpdate_HealthCheck
=== RUN   TestAccAWSELB_Timeout
=== PAUSE TestAccAWSELB_Timeout
=== RUN   TestAccAWSELBUpdate_Timeout
=== PAUSE TestAccAWSELBUpdate_Timeout
=== RUN   TestAccAWSELB_ConnectionDraining
=== PAUSE TestAccAWSELB_ConnectionDraining
=== RUN   TestAccAWSELBUpdate_ConnectionDraining
=== PAUSE TestAccAWSELBUpdate_ConnectionDraining
=== RUN   TestAccAWSELB_SecurityGroups
=== PAUSE TestAccAWSELB_SecurityGroups
=== CONT  TestAccAWSELBAttachment_basic
=== CONT  TestAccAWSELB_SecurityGroups
=== CONT  TestAccAWSELB_importBasic
=== CONT  TestAccAWSELBUpdate_Timeout
=== CONT  TestAccAWSELB_generatesNameForZeroValue
=== CONT  TestAccAWSELB_namePrefix
=== CONT  TestAccAWSELB_Timeout
=== CONT  TestAccAWSELBUpdate_HealthCheck
=== CONT  TestAccAWSELB_HealthCheck
=== CONT  TestAccAWSELB_listener
=== CONT  TestAccAWSELB_InstanceAttaching
=== CONT  TestAccAWSELB_swap_subnets
=== CONT  TestAccAWSELB_Listener_SSLCertificateID_IAMServerCertificate
=== CONT  TestAccAWSELB_tags
=== CONT  TestAccAWSELB_AccessLogs_disabled
=== CONT  TestAccAWSELB_basic
=== CONT  TestAccAWSELB_disappears
=== CONT  TestAccAWSELBUpdate_ConnectionDraining
=== CONT  TestAccAWSELB_availabilityZones
=== CONT  TestAccAWSELB_generatedName
--- PASS: TestAccAWSELB_generatesNameForZeroValue (78.70s)
=== CONT  TestAccAWSELB_AccessLogs_enabled
--- PASS: TestAccAWSELB_disappears (99.32s)
=== CONT  TestAccAWSELB_fullCharacterRange
--- PASS: TestAccAWSELB_availabilityZones (106.87s)
=== CONT  TestAccAWSELB_ConnectionDraining
--- PASS: TestAccAWSELB_SecurityGroups (127.35s)
=== CONT  TestAccAWSELBAttachment_drift
--- PASS: TestAccAWSELB_importBasic (141.14s)
--- PASS: TestAccAWSELB_ConnectionDraining (46.77s)
--- PASS: TestAccAWSELB_AccessLogs_disabled (179.85s)
--- PASS: TestAccAWSELB_Listener_SSLCertificateID_IAMServerCertificate (183.13s)
--- PASS: TestAccAWSELBUpdate_ConnectionDraining (188.44s)
--- PASS: TestAccAWSELB_InstanceAttaching (190.42s)
--- PASS: TestAccAWSELB_fullCharacterRange (94.47s)
--- PASS: TestAccAWSELB_AccessLogs_enabled (125.78s)
--- PASS: TestAccAWSELB_HealthCheck (214.15s)
--- PASS: TestAccAWSELB_basic (230.86s)
--- PASS: TestAccAWSELBAttachment_drift (125.03s)
--- PASS: TestAccAWSELB_Timeout (253.26s)
--- PASS: TestAccAWSELB_namePrefix (275.97s)
--- PASS: TestAccAWSELB_generatedName (280.78s)
--- PASS: TestAccAWSELBUpdate_HealthCheck (289.43s)
--- PASS: TestAccAWSELB_tags (292.36s)
--- PASS: TestAccAWSELBUpdate_Timeout (297.26s)
--- FAIL: TestAccAWSELB_listener (357.93s)
    testing.go:568: Step 4 error: errors during plan:
        
        Error: insufficient items for attribute "listener"; must have at least 1
        
        
    testing.go:629: Error destroying resource! WARNING: Dangling resources
        may exist. The full state and error is shown below.
        
        Error: errors during refresh: insufficient items for attribute "listener"; must have at least 1
        
        State: <nil>
--- PASS: TestAccAWSELBAttachment_basic (394.43s)
--- PASS: TestAccAWSELB_swap_subnets (398.89s)
FAIL
FAIL    github.com/terraform-providers/terraform-provider-aws/aws       401.028s
make: *** [testacc] Error 1

 make testacc TESTARGS="-run=TestAccAWSELBAttachment_basic"
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./... -v -parallel 20 -run=TestAccAWSELBAttachment_basic -timeout 120m
?       github.com/terraform-providers/terraform-provider-aws   [no test files]
=== RUN   TestAccAWSELBAttachment_basic
=== PAUSE TestAccAWSELBAttachment_basic
=== CONT  TestAccAWSELBAttachment_basic
--- PASS: TestAccAWSELBAttachment_basic (206.90s)
PASS
ok      github.com/terraform-providers/terraform-provider-aws/aws       208.275s

@ryndaniels ryndaniels requested a review from a team August 14, 2019 15:11
@ghost ghost added size/S Managed by automation to categorize the size of a PR. service/elb Issues and PRs that pertain to the elb service. labels Aug 14, 2019
@ryndaniels ryndaniels added the bug Addresses a defect in current functionality. label Aug 14, 2019
@ryndaniels ryndaniels added this to the v2.24.0 milestone Aug 14, 2019
Copy link
Contributor

@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.

LGTM 🚀

(test failure known on master)

--- PASS: TestAccAWSELB_generatedName (13.61s)
--- PASS: TestAccAWSELB_Timeout (13.62s)
--- PASS: TestAccAWSELB_tags (20.08s)
--- PASS: TestAccAWSELB_disappears (36.81s)
--- PASS: TestAccAWSELB_importBasic (57.68s)
--- PASS: TestAccAWSELBAttachment_drift (68.13s)
--- PASS: TestAccAWSELB_availabilityZones (84.99s)
--- PASS: TestAccAWSELB_generatesNameForZeroValue (87.81s)
--- PASS: TestAccAWSELBAttachment_basic (99.99s)
--- PASS: TestAccAWSELB_fullCharacterRange (103.45s)
--- PASS: TestAccAWSELBUpdate_ConnectionDraining (83.91s)
--- PASS: TestAccAWSELB_SecurityGroups (79.36s)
--- PASS: TestAccAWSELB_ConnectionDraining (122.23s)
--- PASS: TestAccAWSELB_AccessLogs_disabled (164.14s)
--- PASS: TestAccAWSELBUpdate_HealthCheck (166.39s)
--- PASS: TestAccAWSELBUpdate_Timeout (158.77s)
--- PASS: TestAccAWSELB_AccessLogs_enabled (173.56s)
--- PASS: TestAccAWSELB_namePrefix (196.69s)
--- PASS: TestAccAWSELB_swap_subnets (203.10s)
--- PASS: TestAccAWSELB_HealthCheck (223.53s)
--- PASS: TestAccAWSELB_basic (226.21s)
--- FAIL: TestAccAWSELB_listener (235.55s)
--- PASS: TestAccAWSELB_Listener_SSLCertificateID_IAMServerCertificate (256.59s)
--- PASS: TestAccAWSELB_InstanceAttaching (319.40s)

log.Printf("[DEBUG] Duplicate listener found for ELB (%s), retrying", d.Id())
return resource.RetryableError(awsErr)
}
if awsErr.Code() == "CertificateNotFound" && strings.Contains(awsErr.Message(), "Server Certificate not found for the key: arn") {
Copy link
Contributor

Choose a reason for hiding this comment

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

😍

@bflad bflad modified the milestones: v2.24.0, v2.25.0 Aug 15, 2019
@ryndaniels ryndaniels merged commit d99e0f1 into master Aug 16, 2019
@ryndaniels ryndaniels deleted the rfd-retry-elb branch August 16, 2019 07:38
@ghost
Copy link

ghost commented Aug 23, 2019

This has been released in version 2.25.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 Nov 1, 2019

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 Nov 1, 2019
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/elb Issues and PRs that pertain to the elb service. size/S 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