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

Promoting namespace to the GA provider #12644

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

erikmej-code
Copy link

@erikmej-code erikmej-code commented Dec 23, 2024

In an effort to promote the namespace to the GA provider we do the following:

  1. Remove instances of min_version from Namespace.yaml and include the uid field within properties.
  2. Include a test file, service_directory_namespace_ga.tf.tmpl, with the provider omitted.
`google_service_directory_namespace` (GA)

Add example file where provider is omitted.
Update `Namespace.yaml` to include the `uid` property and remove instances of `min_version`.
@github-actions github-actions bot requested a review from shuyama1 December 23, 2024 19:59
Copy link

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

@shuyama1, 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 modular-magician added the awaiting-approval Pull requests that need reviewer's approval to run presubmit tests label Dec 23, 2024
Copy link

@shuyama1 This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

@modular-magician modular-magician removed the awaiting-approval Pull requests that need reviewer's approval to run presubmit tests label Dec 26, 2024
Copy link
Member

@shuyama1 shuyama1 left a comment

Choose a reason for hiding this comment

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

Copy link

github-actions bot commented Jan 9, 2025

@erikmej-code, this PR is waiting for action from you. If no action is taken, this PR will be closed in 28 days.

Please address any comments or change requests, or re-request review from a core reviewer if no action is required.

Image showing the re-request review button

This notification can be disabled with the disable-automatic-closure label.

@github-actions github-actions bot requested a review from shuyama1 January 22, 2025 15:44
@modular-magician modular-magician added the awaiting-approval Pull requests that need reviewer's approval to run presubmit tests label Jan 22, 2025
@erikmej-code
Copy link
Author

Updated product.yaml file.

@modular-magician modular-magician removed the awaiting-approval Pull requests that need reviewer's approval to run presubmit tests label Jan 22, 2025
@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 ( 14 files changed, 1042 insertions(+), 14 deletions(-))
google-beta provider: Diff ( 5 files changed, 4 insertions(+), 23 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 4 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 13
Passed tests: 9
Skipped tests: 0
Affected tests: 4

Click here to see the affected service packages
  • servicedirectory
#### Non-exercised tests

🔴 Tests were added that are GA-only additions and require manual runs:

  • TestAccServiceDirectoryNamespaceIamBindingGenerated
  • TestAccServiceDirectoryNamespaceIamMemberGenerated
  • TestAccServiceDirectoryNamespaceIamPolicyGenerated
  • TestAccServiceDirectoryNamespace_serviceDirectoryNamespaceBasicExample

Action taken

Found 4 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccServiceDirectoryNamespaceIamBindingGenerated
  • TestAccServiceDirectoryNamespaceIamMemberGenerated
  • TestAccServiceDirectoryNamespaceIamPolicyGenerated
  • TestAccServiceDirectoryNamespace_serviceDirectoryNamespaceBasicExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

🔴 Tests failed during RECORDING mode:
TestAccServiceDirectoryNamespaceIamBindingGenerated [Error message] [Debug log]
TestAccServiceDirectoryNamespaceIamMemberGenerated [Error message] [Debug log]
TestAccServiceDirectoryNamespaceIamPolicyGenerated [Error message] [Debug log]
TestAccServiceDirectoryNamespace_serviceDirectoryNamespaceBasicExample [Error message] [Debug log]

🔴 Errors occurred during RECORDING mode. Please fix them to complete your PR.

View the build log or the debug log for each test

Copy link
Member

@shuyama1 shuyama1 left a comment

Choose a reason for hiding this comment

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

You'll need to remove the provider = google-beta in the example file https://github.com/GoogleCloudPlatform/magic-modules/blob/main/mmv1/templates/terraform/examples/service_directory_namespace_basic.tf.tmpl#L2, as the example will now be used for GA as well

output: true
- name: 'labels'
type: KeyValueLabels
description: |
Resource labels associated with this Namespace. No more than 64 user
labels can be associated with a given resource. Label keys and values can
be no longer than 63 characters.
min_version: 'beta'
- name: 'uid'
Copy link
Member

@shuyama1 shuyama1 Jan 22, 2025

Choose a reason for hiding this comment

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

Any particular reason this is only added to GA? Is this field not supported by the beta API? We require beta provider to be a strict superset of GA, which means whatever in GA should be in beta as well. See 3.2 in https://googlecloudplatform.github.io/magic-modules/code-review/review-pr/#review

You'll likely need to remove this field from the GA implementation as well.

Copy link
Author

Choose a reason for hiding this comment

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

Will fix.

@github-actions github-actions bot requested a review from shuyama1 January 31, 2025 11:31
@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 ( 14 files changed, 1036 insertions(+), 15 deletions(-))
google-beta provider: Diff ( 5 files changed, 4 insertions(+), 30 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 4 insertions(+))
Open in Cloud Shell: Diff ( 1 file changed, 1 deletion(-))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 13
Passed tests: 13
Skipped tests: 0
Affected tests: 0

Click here to see the affected service packages
  • servicedirectory
#### Non-exercised tests

🔴 Tests were added that are GA-only additions and require manual runs:

  • TestAccServiceDirectoryNamespaceIamBindingGenerated
  • TestAccServiceDirectoryNamespaceIamMemberGenerated
  • TestAccServiceDirectoryNamespaceIamPolicyGenerated
  • TestAccServiceDirectoryNamespace_serviceDirectoryNamespaceBasicExample
    🟢 All tests passed!

View the build log

HArdcode v1 service directory base path.
@erikmej-code
Copy link
Author

@shuyama1 these comments should now be resolved. Please review at your earliest convenience. Thanks!

@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 ( 14 files changed, 1036 insertions(+), 15 deletions(-))
google-beta provider: Diff ( 6 files changed, 5 insertions(+), 31 deletions(-))
terraform-google-conversion: Diff ( 2 files changed, 5 insertions(+), 1 deletion(-))
Open in Cloud Shell: Diff ( 1 file changed, 1 deletion(-))

@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 ( 14 files changed, 1023 insertions(+), 15 deletions(-))
google-beta provider: Diff ( 6 files changed, 5 insertions(+), 31 deletions(-))
terraform-google-conversion: Diff ( 2 files changed, 5 insertions(+), 1 deletion(-))
Open in Cloud Shell: Diff ( 1 file changed, 1 deletion(-))

@modular-magician
Copy link
Collaborator

Tests analytics

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

Click here to see the affected service packages
  • dns
  • servicedirectory
#### Non-exercised tests

🔴 Tests were added that are GA-only additions and require manual runs:

  • TestAccServiceDirectoryNamespaceIamBindingGenerated
  • TestAccServiceDirectoryNamespaceIamMemberGenerated
  • TestAccServiceDirectoryNamespaceIamPolicyGenerated
  • TestAccServiceDirectoryNamespace_serviceDirectoryNamespaceBasicExample

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
  • TestAccDNSManagedZone_dnsManagedZoneServiceDirectoryExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

🟢 Tests passed during RECORDING mode:
TestAccDNSManagedZone_dnsManagedZoneServiceDirectoryExample [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

Tests analytics

Total tests: 60
Passed tests: 59
Skipped tests: 1
Affected tests: 0

Click here to see the affected service packages
  • dns
  • servicedirectory
#### Non-exercised tests

🔴 Tests were added that are GA-only additions and require manual runs:

  • TestAccServiceDirectoryNamespaceIamBindingGenerated
  • TestAccServiceDirectoryNamespaceIamMemberGenerated
  • TestAccServiceDirectoryNamespaceIamPolicyGenerated
  • TestAccServiceDirectoryNamespace_serviceDirectoryNamespaceBasicExample
    🟢 All tests passed!

View the build log

@@ -4,7 +4,7 @@ func expand{{$.GetPrefix}}{{$.TitlelizeProperty}}(v interface{}, d tpgresource.T
} else if strings.HasPrefix(v.(string), "https://") {
return v, nil
}
url, err := tpgresource.ReplaceVars(d, config, "{{"{{"}}ServiceDirectoryBasePath{{"}}"}}" + v.(string))
Copy link
Member

Choose a reason for hiding this comment

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

We generally aim to keep each PR focused on a single change to make issue detection and revert easier. Since this change is separate from the GA promotion, I’ve moved it to a new PR (#12934) and added tests to verify the fix. We can remove this change from the current PR and proceed with the other PR for the basepath override. Please let me know if it works for you. Thanks!

Copy link

@erikmej-code, this PR is waiting for action from you. If no action is taken, this PR will be closed in 28 days.

Please address any comments or change requests, or re-request review from a core reviewer if no action is required.

Image showing the re-request review button

This notification can be disabled with the disable-automatic-closure label.

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