Skip to content

Commit

Permalink
Merge pull request #9417 from terraform-providers/rfd-retry-ses
Browse files Browse the repository at this point in the history
Final retry when creating SES domain identity verification
  • Loading branch information
ryndaniels authored Jul 25, 2019
2 parents 24755e8 + 0432686 commit cbbe12b
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion aws/resource_aws_ses_domain_identity_verification.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,16 @@ func resourceAwsSesDomainIdentityVerificationCreate(d *schema.ResourceData, meta

return nil
})
if isResourceTimeoutError(err) {
var att *ses.IdentityVerificationAttributes
att, err = getAwsSesIdentityVerificationAttributes(conn, domainName)

if att != nil && aws.StringValue(att.VerificationStatus) != ses.VerificationStatusSuccess {
return fmt.Errorf("Expected domain verification Success, but was in state %s", aws.StringValue(att.VerificationStatus))
}
}
if err != nil {
return err
return fmt.Errorf("Error creating SES domain identity verification: %s", err)
}

log.Printf("[INFO] Domain verification successful for %s", domainName)
Expand Down

0 comments on commit cbbe12b

Please sign in to comment.