-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Switching a policy for individual members causes a race condition #1613
Comments
We already have a lock... The mutex key is It looks like the bug was caused by an etag mismatch. We have code handling 409 (Conflict) and it should retry. However, it seems from the error message that the error was wrapped twice. The retry logic probably failed to retry because the double wraping hid the fact that the underlying error was a 409. |
Ah, we have a mutex for the _member and _binding resources but not for _policy. @Stono, do you have a config you could share that reproduces the error? That would help me test a fix. |
ahh @danawillow I don't now i'm afraid, but long story short we had a and in one commit, we removed |
Cool, got it. Just sent out #1645. Note though that although this fixes the error in question, there will still be a potential race condition left depending on which resource acquires the lock first. If the |
I'm in the same situation. Tried to build the provider based on #1645 and it's not working. It's entirely possible I don't know what I'm doing, but here's what I did...
And I got the same error:
Ran it twice, just to be sure. Any help greatly appreciated. |
@biff2005 can you run |
Here you go... Thanks for the assistance! |
Ah, ok. That's a different error message- this one is a 400 invalid_argument. Is that the entire debug output? The error message |
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. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 hashibot-feedback@hashicorp.com. Thanks! |
Hola!
We were migrating away from
google_project_iam_policy
in favour of a bunch ofgoogle_project_iam_member
resources.The terraform apply tried to simultaneously delete the existing policy whilst creating the members, resulting in:
Might be worth a lock across policy, and member resources?
The text was updated successfully, but these errors were encountered: