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

Promoted (most of) the supported cloud identity resources to GA #4211

Merged
merged 14 commits into from
Nov 11, 2020

Conversation

melinath
Copy link
Member

@melinath melinath commented Nov 9, 2020

Resolved hashicorp/terraform-provider-google#7757.

Notes:

  • Enabled additional_keys and member_key fields, beta-only
  • Removed references to dynamic groups; they are in the API but will require additional work because they require a premium SKU to test. Since they were already not included in the provider, we don't lose anything by fully deleting them.

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).
  • Generated Terraform, and ran make test and make lint to ensure it passes unit and linter tests.
  • 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).
  • Ran relevant acceptance tests (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)

cloud_identity: promoted `google_cloud_identity_group` to GA
cloud_identity: promoted `google_cloud_identity_group_membership` to GA
cloud_identity: promoted data source `google_cloud_identity_groups` to GA
cloud_identity: promoted data source `google_cloud_identity_group_memberships` to GA

@google-cla google-cla bot added the cla: yes label Nov 9, 2020
@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 15 files changed, 1792 insertions(+), 13 deletions(-))
Terraform Beta: Diff ( 8 files changed, 120 insertions(+), 23 deletions(-))
TF Conversion: Diff ( 3 files changed, 265 insertions(+))

@modular-magician
Copy link
Collaborator

I have triggered VCR tests based on this PR's diffs. See the results here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=156837"

@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 15 files changed, 1788 insertions(+), 13 deletions(-))
Terraform Beta: Diff ( 8 files changed, 120 insertions(+), 27 deletions(-))
TF Conversion: Diff ( 3 files changed, 265 insertions(+))

@modular-magician
Copy link
Collaborator

I have triggered VCR tests based on this PR's diffs. See the results here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=156838"

@melinath melinath marked this pull request as ready for review November 9, 2020 22:33
@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 15 files changed, 1787 insertions(+), 13 deletions(-))
Terraform Beta: Diff ( 8 files changed, 120 insertions(+), 28 deletions(-))
TF Conversion: Diff ( 3 files changed, 265 insertions(+))

@modular-magician
Copy link
Collaborator

I have triggered VCR tests based on this PR's diffs. See the results here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=156839"

@melinath
Copy link
Member Author

melinath commented Nov 9, 2020

@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 16 files changed, 1790 insertions(+), 15 deletions(-))
Terraform Beta: Diff ( 9 files changed, 300 insertions(+), 32 deletions(-))
TF Conversion: Diff ( 3 files changed, 265 insertions(+))

@modular-magician
Copy link
Collaborator

I have triggered VCR tests based on this PR's diffs. See the results here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=157025"

@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 16 files changed, 1790 insertions(+), 15 deletions(-))
Terraform Beta: Diff ( 9 files changed, 270 insertions(+), 32 deletions(-))
TF Conversion: Diff ( 3 files changed, 265 insertions(+))

@modular-magician
Copy link
Collaborator

I have triggered VCR tests based on this PR's diffs. See the results here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=157032"

@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 16 files changed, 1767 insertions(+), 15 deletions(-))
Terraform Beta: Diff ( 10 files changed, 649 insertions(+), 32 deletions(-))
TF Conversion: Diff ( 3 files changed, 265 insertions(+))

@modular-magician
Copy link
Collaborator

I have triggered VCR tests based on this PR's diffs. See the results here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=157039"

@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 16 files changed, 1721 insertions(+), 15 deletions(-))
Terraform Beta: Diff ( 10 files changed, 361 insertions(+), 32 deletions(-))
TF Conversion: Diff ( 3 files changed, 265 insertions(+))

@modular-magician
Copy link
Collaborator

I have triggered VCR tests based on this PR's diffs. See the results here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=157045"

@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 16 files changed, 1699 insertions(+), 15 deletions(-))
Terraform Beta: Diff ( 9 files changed, 179 insertions(+), 32 deletions(-))
TF Conversion: Diff ( 3 files changed, 265 insertions(+))

@modular-magician
Copy link
Collaborator

I have triggered VCR tests based on this PR's diffs. See the results here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=157180"

@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 16 files changed, 1696 insertions(+), 15 deletions(-))
Terraform Beta: Diff ( 9 files changed, 176 insertions(+), 32 deletions(-))
TF Conversion: Diff ( 3 files changed, 265 insertions(+))

@modular-magician
Copy link
Collaborator

I have triggered VCR tests based on this PR's diffs. See the results here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=157279"

group = google_cloud_identity_group.group.id

member_key {
preferred_member_key {
Copy link
Contributor

Choose a reason for hiding this comment

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

Why is the name changing 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.

member_key is only supported in the beta API. This test is being run against the GA API; member_key usage is instead handled by handwritten tests in third_party/terraform/tests/resource_cloud_identity_group_membership_test.go.erb

products/cloudidentity/api.yaml Outdated Show resolved Hide resolved
@@ -222,6 +143,7 @@ objects:
input: true
description: |
EntityKey of the member.
min_version: beta
Copy link
Contributor

Choose a reason for hiding this comment

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

How does exactly_one_of work when one field is beta and one isn't?

Copy link
Member Author

Choose a reason for hiding this comment

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

It looks like exactly_one_of is converted directly into terraform, but using get_property_schema_path and array.compact, which seems to be eliminating the beta field from the resulting golang code.

In other words, in GA, the go code ends up with a "exactly one of" constraint that doesn't include beta fields - in this case meaning it only contains one property, at least one of which much be specified, which I believe is the correct behavior.

@modular-magician
Copy link
Collaborator

Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are.

Diff report:

Terraform GA: Diff ( 16 files changed, 1696 insertions(+), 15 deletions(-))
Terraform Beta: Diff ( 9 files changed, 176 insertions(+), 32 deletions(-))
TF Conversion: Diff ( 3 files changed, 265 insertions(+))

@modular-magician
Copy link
Collaborator

I have triggered VCR tests based on this PR's diffs. See the results here: "https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=157310"

@melinath
Copy link
Member Author

Everything still passes after correcting the GA url so I'm gonna go ahead and merge.

https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=157312
https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=157314

Copy link
Member

@rileykarson rileykarson left a comment

Choose a reason for hiding this comment

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

I think we need to un-guard these lines as well, to make the datasources appear at GA: https://github.com/GoogleCloudPlatform/magic-modules/blob/master/third_party/terraform/utils/provider.go.erb#L183-L186

That should additionally resolve the unused code warnings in tpg eg https://travis-ci.org/github/hashicorp/terraform-provider-google/builds/743049795

@melinath
Copy link
Member Author

Thanks Riley - I've opened #4229 making that change!

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

Successfully merging this pull request may close these issues.

Move cloud identity apis to ga
4 participants