-
Notifications
You must be signed in to change notification settings - Fork 9.6k
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/azurerm: Locking route table on subnet create/delete #13791
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @whiskeyjay
Thanks for this contribution - it LGTM :)
I noticed a minor issue when running the tests - where the TestAccAzureRMSubnet_importBasic
test was failing due to the extra placeholders in the testAccAzureRMSubnet_basic
string not being present; so I've pushed a commit to fix that, and now the tests pass as expected:
$ envchain azurerm make testacc TEST=./builtin/providers/azurerm/ TESTARGS='-run=TestAccAzureRMSubnet'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/04/20 12:15:31 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/azurerm/ -v -run=TestAccAzureRMSubnet -timeout 120m
=== RUN TestAccAzureRMSubnet_importBasic
--- PASS: TestAccAzureRMSubnet_importBasic (188.28s)
=== RUN TestAccAzureRMSubnet_basic
--- PASS: TestAccAzureRMSubnet_basic (189.03s)
=== RUN TestAccAzureRMSubnet_disappears
--- PASS: TestAccAzureRMSubnet_disappears (185.91s)
PASS
ok github.com/hashicorp/terraform/builtin/providers/azurerm 563.241s
$ make testacc TEST=./builtin/providers/azurerm/ TESTARGS='-run=TestParseAzureResourceID'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/04/20 12:27:46 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/azurerm/ -v -run=TestParseAzureResourceID -timeout 120m
=== RUN TestParseAzureResourceID
--- PASS: TestParseAzureResourceID (0.00s)
PASS
ok github.com/hashicorp/terraform/builtin/providers/azurerm 0.019s
Thanks!
@tombuildsstuff Good catch, thanks! |
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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
This fix is very similar to #13637 by @tombuildsstuff - a similar error (429) can happen if the route table is being updated while trying to create/delete a subnet that uses the said route table.
Also, added a check in the resource id parser for empty string key or value (this can happen from Import command as users can manually type in a resource id).
The following script can repro the error intermittently:
Error message is:
Acc test results: