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 numeric_id field into google_compute_network resource #6719

Conversation

modular-magician
Copy link
Collaborator

This PR will fix an issue that relates to tag binding. Where it is only possible to use an id of a resource for binding rather than name. Because of the use of id within the terraform providers, numeric_id is used as a field which is the unique resource identifier for the resource.

marked as id in API documentation but will be named as numeric_id in provider

Release Note Template for Downstream PRs (will be copied)

compute: added `numeric_id` field to `google_compute_network` resource

Derived from GoogleCloudPlatform/magic-modules#9473

* add numberic_id field

* add flattener, encoders, and id field for numeric_id use

* WIP: add numberId test

* add value checks for id and numeric_id

* add strconv

* use decoder to store id into numericId after API request

* remove network check and add suffix variable

* add endlines

* typo

* Updated test to explicitly check numeric_id and id with ResourceAttr

* update regex to be more strict on numeric_id check
[upstream:d6ce7020cd1e2a490a93c91ccc643531dba8bae7]

Signed-off-by: Modular Magician <[email protected]>
@modular-magician modular-magician merged commit eded65e into hashicorp:main Dec 7, 2023
1 check passed
@modular-magician modular-magician deleted the downstream-pr-d6ce7020cd1e2a490a93c91ccc643531dba8bae7 branch November 16, 2024 03:41
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.

1 participant