Skip to content

feat: Add CloudIdentityGroup direct controller #3653

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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

gemmahou
Copy link
Collaborator

@gemmahou gemmahou commented Feb 11, 2025

Change description

Add CloudIdentityGroup direct controller.

Tests you have done

Duplicated code to GoB and triggered realGCP test: https://cnrm-review.git.corp.google.com/c/cnrm/+/72600
(Test failure is expected, since we start a new pipeline for each run, there's no golden log to compare with. Other than the diff I don't see other errors)

RealGCP log saved in GCS: https://pantheon.corp.google.com/storage/browser/cnrm-prow/pr-logs/pull/cnrm-review.googlesource.com_cnrm/72600/cnrm-test/1915192728967188480/artifacts;tab=objects?e=13802955&mods=pan_ng2&prefix=&forceOnObjectsSortingFiltering=false

diff between TF-mock and direct-real: aa34cc3

diff between direct-real and direct-mock(no diff): 11ba115

  • Run make ready-pr to ensure this PR is ready for review.
  • Perform necessary E2E testing for changed resources.

@gemmahou gemmahou force-pushed the cloudidentitygroup-controller branch 8 times, most recently from b9b4e50 to 9e8805c Compare February 15, 2025 18:14
@gemmahou gemmahou force-pushed the cloudidentitygroup-controller branch 5 times, most recently from 23bdb84 to 50f747a Compare February 21, 2025 23:19
@gemmahou gemmahou marked this pull request as ready for review February 21, 2025 23:30
@gemmahou gemmahou force-pushed the cloudidentitygroup-controller branch 7 times, most recently from b14dea9 to 11ba115 Compare April 24, 2025 00:11
@gemmahou
Copy link
Collaborator Author

/assign @barney-s @jingyih

@gemmahou gemmahou force-pushed the cloudidentitygroup-controller branch from bfa2e89 to a1347b7 Compare April 30, 2025 01:30
@barney-s
Copy link
Collaborator

/lgtm

Copy link
Collaborator

@jingyih jingyih left a comment

Choose a reason for hiding this comment

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

/lgtm
/approve
/hold
Feel free to unhold

@@ -154,7 +154,7 @@ func (s *groupsServer) PatchGroup(ctx context.Context, req *pb.PatchGroupRequest
for _, path := range strings.Split(req.GetUpdateMask(), ",") {
switch path {
case "displayName": // TF controller uses displayName while direct controller uses display_name
obj.DisplayName = req.GetGroup().DisplayName // TF
fallthrough
Copy link
Collaborator

Choose a reason for hiding this comment

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

nit: maybe case "displayName", "display_name": would be less error-prone for future edits?

Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jingyih

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

name: ${groupID}
observedGeneration: 3
externalRef: groups/${groupID}
name: groups/${groupID}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Oh, just realized this is a TF beta resource?
We need to ensure backward compatabiilty. So status.name should not have "groups/" prefix. And we should write back "spec.resourceID".

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.

4 participants