Skip to content
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

Add Terraform Support For Cloud SQL Preferred Zone Selection Feature #9341

Merged
merged 5 commits into from
Oct 26, 2023

Conversation

Khaledmohamedrefaat
Copy link
Contributor

@Khaledmohamedrefaat Khaledmohamedrefaat commented Oct 24, 2023

Add Terraform Support For Cloud SQL Preferred Zone Selection Feature

If this PR is for Terraform, I acknowledge that I have:

  • Searched through the issue tracker for an open issue that this either resolves or contributes to, commented on it to claim it, and written "fixes {url}" or "part of {url}" in this PR description. If there were no relevant open issues, I opened one and commented that I would like to work on it (not necessary for very small changes).
  • Ensured that all new fields I added that can be set by a user appear in at least one example (for generated resources) or third_party test (for handwritten resources or update tests).
  • Generated Terraform providers, and ran make test and make lint in the generated providers to ensure it passes unit and linter tests.
  • Ran relevant acceptance tests using my own Google Cloud project and credentials (If the acceptance tests do not yet pass or you are unable to run them, please let your reviewer know).
  • Read the Release Notes Guide before writing my release note below.

Release Note Template for Downstream PRs (will be copied)

composer: added `database_config.zone` field in `google_composer_environment`

Fixes hashicorp/terraform-provider-google/issues/16344

@modular-magician
Copy link
Collaborator

Hello! I am a robot. It looks like you are a: Community Contributor Googler Core Contributor. Tests will run automatically.

@trodge, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look.

You can help make sure that review is quick by doing a self-review and by running impacted tests locally.

@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

Terraform GA: Diff ( 5 files changed, 234 insertions(+), 53 deletions(-))
Terraform Beta: Diff ( 5 files changed, 234 insertions(+), 53 deletions(-))

@PeWu
Copy link
Member

PeWu commented Oct 24, 2023

LGTM

@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

Terraform GA: Diff ( 5 files changed, 232 insertions(+), 51 deletions(-))
Terraform Beta: Diff ( 5 files changed, 232 insertions(+), 51 deletions(-))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 3170
Passed tests 2843
Skipped tests: 320
Affected tests: 7

Action taken

Found 7 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccComposerEnvironment_UpdateComposerV2|TestAccComposerEnvironment_ComposerV2|TestAccContainerCluster_withGatewayApiConfig|TestAccContainerAwsCluster_BetaBasicHandWritten|TestAccContainerAwsCluster_BetaBasicEnumHandWritten|TestAccContainerAwsCluster_BasicEnumHandWritten|TestAccContainerAwsCluster_BasicHandWritten

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccComposerEnvironment_UpdateComposerV2[Debug log]
TestAccContainerAwsCluster_BetaBasicHandWritten[Debug log]

Rerun these tests in REPLAYING mode to catch issues

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccComposerEnvironment_ComposerV2[Error message] [Debug log]
TestAccContainerCluster_withGatewayApiConfig[Error message] [Debug log]
TestAccContainerAwsCluster_BetaBasicEnumHandWritten[Error message] [Debug log]
TestAccContainerAwsCluster_BasicEnumHandWritten[Error message] [Debug log]
TestAccContainerAwsCluster_BasicHandWritten[Error message] [Debug log]

$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$
View the build log or the debug log for each test

Copy link
Contributor

@trodge trodge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The error we're seeing in our tests is this:

Error: Error creating Network: googleapi: Error 409: The resource 'projects/ci-test-project-188019/global/networks/tf-test-composer-net-8380661580462607644' already exists, alreadyExists

I think this is caused by naming collision between different composer tests being run in parallel.

@modular-magician
Copy link
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

Terraform GA: Diff ( 5 files changed, 232 insertions(+), 51 deletions(-))
Terraform Beta: Diff ( 5 files changed, 232 insertions(+), 51 deletions(-))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 3173
Passed tests 2847
Skipped tests: 319
Affected tests: 7

Action taken

Found 7 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
TestAccBigQueryDataTable_bigtable|TestAccBigtableAppProfile_bigtableAppProfileSingleclusterExample|TestAccComposerEnvironment_ComposerV2|TestAccContainerCluster_withGatewayApiConfig|TestAccContainerAwsCluster_BasicEnumHandWritten|TestAccContainerAwsCluster_BetaBasicEnumHandWritten|TestAccContainerAwsCluster_BasicHandWritten

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccBigQueryDataTable_bigtable[Debug log]
TestAccBigtableAppProfile_bigtableAppProfileSingleclusterExample[Debug log]
TestAccComposerEnvironment_ComposerV2[Debug log]
TestAccContainerAwsCluster_BetaBasicEnumHandWritten[Debug log]

Rerun these tests in REPLAYING mode to catch issues

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccContainerCluster_withGatewayApiConfig[Error message] [Debug log]
TestAccContainerAwsCluster_BasicEnumHandWritten[Error message] [Debug log]
TestAccContainerAwsCluster_BasicHandWritten[Error message] [Debug log]

$\textcolor{red}{\textsf{Please fix these to complete your PR.}}$
View the build log or the debug log for each test

Copy link
Contributor

@trodge trodge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, opened hashicorp/terraform-provider-google#16380 for the test hiccup.

cloud.google.com/go/bigtable v1.19.0
github.com/GoogleCloudPlatform/declarative-resource-client-library v1.52.0
cloud.google.com/go/bigtable v1.20.0
github.com/GoogleCloudPlatform/declarative-resource-client-library v1.54.0
Copy link
Member

@c2thorn c2thorn Oct 26, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was this PR intended to upgrade every available dependency?

This upgrades the DCL library and seems completely unrelated to DCL changes. Were the test failures from #9341 (comment) addressed? I think they were caused by upgrading here without also upgrading the tpgtools go.mod

I can only imagine additional potential side effects from upgrading all of these imports at once. @trodge @Khaledmohamedrefaat

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have reverted this PR.

Please open a new one that updates only the necessary dependencies.

jiayimeow pushed a commit to jiayimeow/magic-modules that referenced this pull request Oct 31, 2023
…oogleCloudPlatform#9341)

* Adding support for cloud sql zone selection

* Fixing spaces/tabs indentation

* Fixing indetnation

* Fixing blank line

* Trigger Presubmits

---------

Co-authored-by: Khaled Hassan <[email protected]>
jiayimeow pushed a commit to jiayimeow/magic-modules that referenced this pull request Oct 31, 2023
BBBmau pushed a commit to BBBmau/magic-modules that referenced this pull request Nov 28, 2023
…oogleCloudPlatform#9341)

* Adding support for cloud sql zone selection

* Fixing spaces/tabs indentation

* Fixing indetnation

* Fixing blank line

* Trigger Presubmits

---------

Co-authored-by: Khaled Hassan <[email protected]>
BBBmau pushed a commit to BBBmau/magic-modules that referenced this pull request Nov 28, 2023
jialei-chen pushed a commit to jialei-chen/magic-modules that referenced this pull request Nov 29, 2023
…oogleCloudPlatform#9341)

* Adding support for cloud sql zone selection

* Fixing spaces/tabs indentation

* Fixing indetnation

* Fixing blank line

* Trigger Presubmits

---------

Co-authored-by: Khaled Hassan <[email protected]>
jialei-chen pushed a commit to jialei-chen/magic-modules that referenced this pull request Nov 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Terraform Support For Cloud SQL Preferred Zone Selection Feature
5 participants