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

Support SupportedKinds in ListenerStatus #809

Merged

Conversation

ciarams87
Copy link
Member

@ciarams87 ciarams87 commented Jul 4, 2023

Proposed changes

Currently, we don't support setting SupportedKinds in ListenerStatus based on the spec.
SupportedKinds is the list indicating the Kinds supported by this listener. This MUST represent the kinds an implementation supports for that Listener configuration.

If kinds are specified in Spec that are not supported, they MUST NOT appear in this list and an implementation MUST set the “ResolvedRefs” condition to “False” with the “InvalidRouteKinds” reason. If both valid and invalid Route kinds are specified, the implementation MUST reference the valid Route kinds that have been specified.

Solution: Support setting SupportedKinds in ListenerStatus based on the spec.

Testing: Unit-tests have been updated and are passing, manual testing, and confirmed related conformance tests are now passing.

    --- PASS: TestConformance/GatewayInvalidRouteKind (4.05s)
        --- PASS: TestConformance/GatewayInvalidRouteKind/Gateway_listener_should_have_a_false_ResolvedRefs_condition_with_reason_InvalidRouteKinds_and_no_supportedKinds (4.01s)
        --- PASS: TestConformance/GatewayInvalidRouteKind/Gateway_listener_should_have_a_false_ResolvedRefs_condition_with_reason_InvalidRouteKinds_and_HTTPRoute_must_be_put_in_the_supportedKinds (0.00s)

Closes #690

Checklist

Before creating a PR, run through this checklist and mark each as complete.

  • I have read the CONTRIBUTING doc
  • I have added tests that prove my fix is effective or that my feature works
  • I have checked that all unit tests pass after adding my changes
  • I have updated necessary documentation
  • I have rebased my branch onto main
  • I will ensure my PR is targeting the main branch and pulling from my branch from my own fork

@ciarams87 ciarams87 requested a review from a team as a code owner July 4, 2023 11:05
@github-actions github-actions bot added documentation Improvements or additions to documentation enhancement New feature or request labels Jul 4, 2023
internal/state/graph/gateway_listener.go Outdated Show resolved Hide resolved
internal/state/graph/gateway_listener_test.go Outdated Show resolved Hide resolved
@ciarams87 ciarams87 force-pushed the feat/gateway-status-supported-kinds branch from 39561da to d4effcd Compare July 6, 2023 10:51
@ciarams87 ciarams87 force-pushed the feat/gateway-status-supported-kinds branch from ace7c3e to 49ad5ee Compare July 7, 2023 11:00
internal/state/graph/gateway_listener.go Outdated Show resolved Hide resolved
internal/state/graph/gateway_listener.go Outdated Show resolved Hide resolved
@ciarams87 ciarams87 force-pushed the feat/gateway-status-supported-kinds branch from 49ad5ee to 78fa031 Compare July 10, 2023 08:56
@sjberman sjberman mentioned this pull request Jul 10, 2023
6 tasks
@ciarams87 ciarams87 force-pushed the feat/gateway-status-supported-kinds branch from 78fa031 to e6d57f1 Compare July 11, 2023 08:53
@ciarams87 ciarams87 merged commit 73015f8 into nginxinc:main Jul 11, 2023
@ciarams87 ciarams87 deleted the feat/gateway-status-supported-kinds branch July 11, 2023 09:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Set supported kinds based on listener
3 participants