Closed bogdan-grozoiu closed 4 years ago
We believe that this is caused by race conditions with the API due to the volume of requests, so we are going to add some brief delays in here to help it out.
Using a count resource in large record counts used to skip a mutex of one api call causing this to happen it appears to work in .12 release of Terraform tried with 150 records at a time
Can you please verify if this is still an issue (see example below)
Thanks
resource "akamai_dns_record" "a_record" { count = 150 zone = "${local.zone}" name = "www-${count.index}.akavadev1.net" recordtype = "A" active = true ttl = 300 target = ["10.0.0.${count.index}"] }
akamai_dns_record.a_record[48]: Creation complete after 8s [id=akavadev1.net-www-48.akavadev1.net-
Apply complete! Resources: 150 added, 0 changed, 0 destroyed. akamai_dns_record.a_record[7]: Destruction complete after 3s
Destroy complete! Resources: 150 destroyed.
Terraform Version
Terraform v0.12.5 Akamai Provider v0.1.1
Affected Resource(s)
Terraform Configuration Files
Expected Behavior
The Akamai Provider to create all the DNS records in the DNS Zone and also to completely remove them.
Actual Behavior
The Akamai Provider creates all the DNS records in the DNS Zone and also reports as successful their removal, without removing all of them.
Steps to Reproduce
terraform init
Initializing provider plugins...
Terraform has been successfully initialized!
You may now begin working with Terraform. Try running "terraform plan" to see any changes that are required for your infrastructure. All Terraform commands should now work.
If you ever set or change modules or backend configuration for Terraform, rerun this command to reinitialize your working directory. If you forget, other commands will detect it and remind you to do so if necessary.
Plan: 84 to add, 0 to change, 0 to destroy.
Note: You didn't specify an "-out" parameter to save this plan, so Terraform can't guarantee that exactly these actions will be performed if "terraform apply" is subsequently run.
No changes. Infrastructure is up-to-date.
This means that Terraform did not detect any differences between your configuration and real physical resources that exist. As a result, no actions need to be performed.
Destroy complete! Resources: 84 destroyed.