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 location field to google_network_services_mesh #12991

Merged
merged 3 commits into from
Feb 10, 2025

Conversation

AshZhang
Copy link
Member

@AshZhang AshZhang commented Feb 6, 2025

Adds a new location field to google_network_services_mesh.

In the future, this will allow creating a regional Mesh resource, but currently regional Meshes are internal-only and not yet publicly available, so only the value 'global' may be set. If omitted, the location defaults to 'global'.

Release Note Template for Downstream PRs (will be copied)

See Write release notes for guidance.

networkservices: added `location` field to `google_network_services_mesh` resource

@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.

google provider: Diff ( 1 file changed, 27 insertions(+), 8 deletions(-))
google-beta provider: Diff ( 5 files changed, 196 insertions(+), 22 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 1 insertion(+), 1 deletion(-))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 58
Passed tests: 56
Skipped tests: 1
Affected tests: 1

Click here to see the affected service packages
  • networkservices

Action taken

Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccNetworkServicesMesh_networkServicesMeshLocationExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

🟢 Tests passed during RECORDING mode:
TestAccNetworkServicesMesh_networkServicesMeshLocationExample [Debug log]

🟢 No issues found for passed tests after REPLAYING rerun.


🟢 All tests passed!

View the build log or the debug log for each test

@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.

google provider: Diff ( 1 file changed, 27 insertions(+), 8 deletions(-))
google-beta provider: Diff ( 5 files changed, 196 insertions(+), 22 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 1 insertion(+), 1 deletion(-))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 58
Passed tests: 57
Skipped tests: 1
Affected tests: 0

Click here to see the affected service packages
  • networkservices

🟢 All tests passed!

View the build log

@AshZhang AshZhang marked this pull request as ready for review February 7, 2025 00:19
Copy link

github-actions bot commented Feb 7, 2025

Hello! I am a robot. Tests will require approval from a repository maintainer to run.

@hao-nan-li, 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.

@github-actions github-actions bot requested a review from hao-nan-li February 7, 2025 00:20
@@ -0,0 +1,98 @@
func resourceNetworkServicesMeshResourceV0() *schema.Resource {
Copy link
Contributor

Choose a reason for hiding this comment

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

What's the reason for adding this file here?

Copy link
Member Author

Choose a reason for hiding this comment

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

I am adding a StateUpgrader for the location field for backward compatibility with existing resources / state files that don't have the field. Without this, the provider would substitute an empty value for {{location}} in the URL during RUD operations for existing resources since there is no location attribute in the state file, and it results in an error because the resource URL is invalid.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants