-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Update mutex on google_apigee_instance_attachment to lock globally #5911
Conversation
Co-authored-by: Stephen Lewis (Burrows) <[email protected]>
Hello! I am a robot who works on Magic Modules PRs. I have detected that you are a community contributor, so your PR will be assigned to someone with a commit-bit on this repo for initial review. Thanks for your contribution! A human will be with you soon. @melinath, please review this PR or find an appropriate assignee. |
I tested locally and it has worked. I cannot add a test case as in hashicorp/terraform-provider-google#11445 because only paid ApigeeOrgs can create multiple instances, and paid ApigeeOrgs cannot be automatically created/deleted in CI/CD tests. |
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 1 file changed, 2 insertions(+), 2 deletions(-)) |
Tests analyticsTotal tests: Action takenTriggering VCR tests in RECORDING mode for the following tests that failed during VCR: TestAccAccessContextManager|TestAccContainerCluster_withAuthenticatorGroupsConfig|TestAccComputeGlobalForwardingRule_externalCdnLbWithBackendBucketExample |
@xuchenma I don't think this is going to do exactly what you want it to. The mutex will be filled in by getting the Unfortunately there may not be a better solution than a global lock, since the terraform resource only has access to organization and environment. (But it would be better to make that explicit by giving it a hardcoded string as the mutex.) |
I see, thanks for the explanation! I updated it to lock on a hardcoded string. Tested locally, it worked for me. |
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 1 file changed, 2 insertions(+), 2 deletions(-)) |
Tests analyticsTotal tests: Action takenTriggering VCR tests in RECORDING mode for the following tests that failed during VCR: TestAccFirebaserulesRelease_BasicRelease|TestAccComputeForwardingRule_update|TestAccDatasourceGoogleServiceNetworkingPeeredDnsDomain_basic |
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.
it would be good to add the resource name to the global mutex name; for now I think this is the only one but we should still namespace it to be future-proof.
Got it, updated! |
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 1 file changed, 2 insertions(+), 2 deletions(-)) |
Tests analyticsTotal tests: Action takenTriggering VCR tests in RECORDING mode for the following tests that failed during VCR: TestAccFirebaserulesRelease_BasicRelease|TestAccServiceNetworkingPeeredDNSDomain_basic |
…oogleCloudPlatform#5911) * Add support IAM policy for the Environment of Apigee X * Add support IAM policy for the Environment of Apigee X * Add support IAM policy for the Environment of Apigee X * Add support IAM policy for the Environment of Apigee X * Revert all changes to test files. * Revert all changes to test files. * Revert all changes to test files. * Add primary_resource_name to fix tests. * Update iam_attributes.tf.erb to honor skip_test. * Don't reject skip_tests when example is nil. * Update mmv1/products/apigee/api.yaml Co-authored-by: Stephen Lewis (Burrows) <[email protected]> * Fix primary_resource_name for apigee organization name. * Update mutex on google_apigee_instance_attachment to lock on org_id. * Create a global lock on instance attachments. * update mutex name to apigeeInstanceAttachments Co-authored-by: Stephen Lewis (Burrows) <[email protected]>
This PR updates the mutex on google_apigee_instance_attachment to create a global lock.
It solves hashicorp/terraform-provider-google#11445.
If this PR is for Terraform, I acknowledge that I have:
make test
andmake lint
to ensure it passes unit and linter tests.Release Note Template for Downstream PRs (will be copied)