Skip to content

Conversation

@davidjumani
Copy link

What type of PR is this?
Add one of the following kinds:
/kind gep

What this PR does / why we need it:
Updates the status of the Gateway to include AttachedListeners which is the count of successful ListenerSet attachments to the gateway. Ref: slack thread

Does this PR introduce a user-facing change?:

Adds the `AttachedListeners` conditions to the Gateway status which is the count of successful ListenerSet attachments to the gateway

@k8s-ci-robot k8s-ci-robot added kind/gep PRs related to Gateway Enhancement Proposal(GEP) release-note Denotes a PR that will be considered when it comes time to generate release notes. labels Oct 30, 2025
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Oct 30, 2025
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: davidjumani
Once this PR has been reviewed and has the lgtm label, please assign danwinship for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found 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

@k8s-ci-robot k8s-ci-robot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Oct 30, 2025
@davidjumani davidjumani changed the title Update gateway status to include AttachedListeners api: Update gateway status to include AttachedListeners Oct 30, 2025
Copy link
Contributor

@howardjohn howardjohn left a comment

Choose a reason for hiding this comment

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

I am going to take a contrarian point of view here and say maybe we shouldn't add this. AttachedRoutes, IMO, is an extremely high-cost status field to update with extremely little value.

Our implementation spends like 20% of its CPU calculating AttachedRoutes...

If we do decide to add it though, the PR itself LGTM

@rikatz
Copy link
Member

rikatz commented Nov 3, 2025

@howardjohn regardless of the implementation detail (which I see your point and agree about the performance caveat), I am wondering that we need a way to let the Gateway owner know that there are some ListenerSets attached to the Gateway.

Do you suggest some different approach for it?

@howardjohn
Copy link
Contributor

A ListenersAttached: bool instead of int is one approach that maybe could be acceptable tradeoff.

FWIW the implementation detail is not specific to any implementation, it necessarily at least doubles the number of status writes to the API server on a route creation/deletion.

@rikatz
Copy link
Member

rikatz commented Nov 3, 2025

ok, seems reasonable.

@robscott @youngnick for some comments, we can change for a boolean instead. I think it is important for an admin at least to know something is attached to the gateway

@davidjumani
Copy link
Author

davidjumani commented Nov 4, 2025

A ListenersAttached: bool instead of int is one approach that maybe could be acceptable tradeoff.

Thanks @howardjohn - The AttachedListenerSets status condition should suffice if this is the case

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/gep PRs related to Gateway Enhancement Proposal(GEP) release-note Denotes a PR that will be considered when it comes time to generate release notes. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants