fix: stale route status after the parent Gateway is modified - #5116
fix: stale route status after the parent Gateway is modified#5116yuehaii wants to merge 1 commit into
Conversation
Signed-off-by: hai.yue <20416005+yuehaii@users.noreply.github.com>
|
Adding the "do-not-merge/release-note-label-needed" label because no release-note block was detected, please follow our release note process to remove it. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
@yuehaii: The label(s) DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: yuehaii The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Welcome @yuehaii! |
|
Hi @yuehaii. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Regular contributors should join the org to skip this step. Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
| // each parent. When this route attaches to a parent, the controller that | ||
| // manages the parent must add an entry to this list when the controller | ||
| // first sees the route and should update the entry as appropriate when the | ||
| // first sees the route and MUST update the entry as appropriate when the |
There was a problem hiding this comment.
@yuehaii could you bring this topic to one of our community meetings? (https://gateway-api.sigs.k8s.io/contributing/get-involved/#meetings) I would consider this a breaking change for implementations, so I think it's important that the community discusses and agrees on it first before we move forward.
There was a problem hiding this comment.
sure. I have added a topic in [SIG-NETWORK] Gateway API Meeting Notes for discussion.
There was a problem hiding this comment.
@yuehaii we discussed this PR quickly in today's community meeting. We are mostly in agreement with the proposed tightening of the API spec. However, since this is a breaking change, we would like to get a better understanding of how many implementations would be impacted before moving forward.
Could you also share how you encountered this issue, and are you aware of any implementations that aren't behaving as you expected?
There was a problem hiding this comment.
I think this update, as tested by the included test, is probably okay.
But is also important to call out that there are some cases where there is more to it - particularly when a Route falls out of scope. In that case, the controller may not see updates to the Route (if it's screening out Routes that aren't relevant on each Gateway reconciliation). That's probably better handled as a separate issue though.
There was a problem hiding this comment.
thanks for your help on the community meeting, @snorwin . please check this envoy gateway issue envoyproxy/gateway#8876, I am still working on an elegant fix.
|
I've verified that this tests passes with NGINX, so no breakage for us. |
What type of PR is this?
/kind bug
What this PR does / why we need it:
The RouteStatus spec previously used 'should' update (non-normative) when describing that implementations must update status.parents[].conditions on an HTTPRoute after the parent Gateway is modified. This left room for implementations to leave stale route status behind. For example, when a Gateway listener hostname is updated to match an HTTPRoute's hostname, the route's Accepted=False / NoMatchingListenerHostname condition could remain unchanged even though the route should now be accepted.
This PR:
normative.
Accepted=False / NoMatchingListenerHostname to Accepted=True / Accepted after the Gateway listener hostname is changed to match the
route's hostname.
Which issue(s) this PR fixes:
Fixes #5115
Does this PR introduce a user-facing change?:
None