-
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
Race condition in aws_internet_gateway creation #1657
Comments
I too have seen this happen. I took a look through the code and nothing jumped out at me as the obvious culprit. Thanks for the repro case. Tagged and we'll get this figured out. |
Interestingly, I could never get this to repro with |
@bitglue Good evidence even further its a race condition, since the logging probably adds enough delay to mask it. |
I've been running this in a loop on my machine for about 10 minutes now, and I haven't been able to get this error. I actually think this is likely fixed with #1781 since I did fix some race conditions around interpolations in there. Or... it could just be my computer. @phinze or @bitglue can you test with latest master? Thanks! |
I can no longer reproduce, so I guess it's either fixed or gone into hiding. Or it's not a race condition in Terraform, but something having to do with AWS eventual consistency that was precipitated by some transient condition at Amazon. (add this to the list of issues potentially addressed by #1732) |
Waiting on your PR for #1732 :) But this is most certainly a TF core issue that was fixed or hiding. Variables not being found can't be caused by eventual consistency in providers since those are done as atomic units. The only way this would be caused would be two nodes happening in parallel. |
Yeah, I know. I might get to it some day if these issues continue to irk me. Still want to reference that issue so I can have a reference when that day comes. I don't know if I communicated it clearly, but sometimes when I file an issue, I'm just probing to see if the idea would even be entertained before I go through the work of making a PR. Had the response been "sounds interesting -- would like to see a PR" right off the bat, we probably could have saved some time. We'll see how the recent changes re. modules and dependencies go, and if they lower the annoyance below my tolerance. |
Not to open that discussion, but it is interesting, and as I believe we both agree its not a binary 1/0 thing (the graph doesn't go away, the retries won't never exist). I think we'll converge towards an agreeable ground over time. |
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. |
I have a configuration which sets up a VPC with an internet gateway:
If I
apply
anddestroy
this repeatedly, sometimes onapply
I get:Other times, it works fine. I'm guessing there's a race condition in the creation of one of these resources. Using
master
.The text was updated successfully, but these errors were encountered: