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

apis: ApigeeEnvgroupAttachment #3605

Merged

Conversation

acpana
Copy link
Collaborator

@acpana acpana commented Feb 5, 2025

Adds direct style APIs for the ApigeeEnvgroupAttachment. This is an alpha resource, still running over the TF controller.

Next PR:

  • add a direct controoler
  • change envgroup and environment fields to references! [ did it in this PR ]

@acpana acpana requested review from yuwenma and jasonvigil February 5, 2025 01:07
}

// ApigeeEnvgroupAttachmentStatus defines the observed state of ApigeeEnvgroupAttachment
type ApigeeEnvgroupAttachmentStatus struct {

Choose a reason for hiding this comment

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

There should be an observedState.createdAt field?

int64 created_at = 1 [json_name="createdAt"];

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Let's add this in once we have the direct controller!

Copy link

@jasonvigil jasonvigil Feb 7, 2025

Choose a reason for hiding this comment

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

Curious why would we wait to add this field? The API is already not compatible with the legacy DCL controller.

@acpana acpana force-pushed the acpana/aega-types branch 2 times, most recently from 046c738 to c51d2b3 Compare February 6, 2025 23:00
@acpana acpana force-pushed the acpana/aega-types branch from c51d2b3 to be0b17a Compare February 7, 2025 00:19
@acpana acpana force-pushed the acpana/aega-types branch from 19b311c to f28af05 Compare February 7, 2025 01:28
return "", fmt.Errorf("reading referenced %s %s: %w", EnvironmentGVK, key, err)
}
// Get external from status.externalRef. This is the most trustworthy place.
actualExternalRef, found, err := unstructured.NestedString(u.Object, "status", "externalRef")

Choose a reason for hiding this comment

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

Just realized this will not work actually, there is no status.externalRef field in the existing ApigeeEnvironment type. I created a PR to define types/refs for ApigeeEnvironment (and ApigeeOrganization), you will need to rebase to use updated code.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yup that's why I have my TODO lower. There's been chatter about how to fix this in a separate PR (for a different resource). I don't think we should block on this for now. TL;DR - for TF or DCL resources this field will not be populated. But I think we have a path forward.

Can we close on this PR so I can focus on the TODO (and the remaining work items) ?

Copy link
Collaborator

@yuwenma yuwenma left a comment

Choose a reason for hiding this comment

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

/approve
/assign @jasonvigil

Defer to Jason for the final vote.

Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: yuwenma

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

@jasonvigil
Copy link

/lgtm

@google-oss-prow google-oss-prow bot added the lgtm label Feb 7, 2025
@google-oss-prow google-oss-prow bot merged commit 94663d7 into GoogleCloudPlatform:master Feb 7, 2025
18 checks passed
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