Skip to content

gateway-api: handle TCPRoute/UDPRoute in Envoy host network mode - #47430

Merged
mhofstetter merged 1 commit into
cilium:mainfrom
arybolovlev:pr/arybolovlev/handle-tcp-udp-routes-with-host-networking
Jul 24, 2026
Merged

gateway-api: handle TCPRoute/UDPRoute in Envoy host network mode#47430
mhofstetter merged 1 commit into
cilium:mainfrom
arybolovlev:pr/arybolovlev/handle-tcp-udp-routes-with-host-networking

Conversation

@arybolovlev

@arybolovlev arybolovlev commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

This commit correctly handles TCPRoute and UDPRoute when Envoy runs in host network mode by rejecting unsupported routes, since the current NodePort-based implementation does not work correctly in this mode.

  • Reject TCP/UDP listeners in host network mode and update Gateway listener status for unsupported L4 listeners.
  • Reject TCPRoute and UDPRoute objects in host network mode and set unsupported status on route objects.
  • Rejecting TCP/UDP listeners and/or routes doesn't stop the reconciliation of mixed scenarios.

Related to #47234.

gateway-api: Correctly handle TCPRoute and UDPRoute in host network mode by rejecting unsupported L4 configurations and updating Gateway/Route statuses.

@maintainer-s-little-helper maintainer-s-little-helper Bot added the dont-merge/needs-release-note-label The author needs to describe the release impact of these changes. label Jul 22, 2026
@xtineskim

Copy link
Copy Markdown
Member

lgtm! 🚀

@arybolovlev

Copy link
Copy Markdown
Contributor Author

/test

@arybolovlev
arybolovlev force-pushed the pr/arybolovlev/handle-tcp-udp-routes-with-host-networking branch 3 times, most recently from 0f14f4f to 7d52147 Compare July 23, 2026 10:36
@arybolovlev

Copy link
Copy Markdown
Contributor Author

Rebased on top of main to address conflict.

@arybolovlev

Copy link
Copy Markdown
Contributor Author

/test

1 similar comment
@cilium-ariane

cilium-ariane Bot commented Jul 23, 2026

Copy link
Copy Markdown

/test

@mhofstetter mhofstetter added kind/enhancement This would improve or streamline existing functionality. release-note/misc This PR makes changes that have no direct user impact. area/servicemesh GH issues or PRs regarding servicemesh needs-backport/1.20 This PR / issue needs backporting to the v1.20 branch labels Jul 23, 2026
@maintainer-s-little-helper maintainer-s-little-helper Bot removed the dont-merge/needs-release-note-label The author needs to describe the release impact of these changes. label Jul 23, 2026
@arybolovlev

Copy link
Copy Markdown
Contributor Author

/ci-l3-l4

@arybolovlev

Copy link
Copy Markdown
Contributor Author

/test

@arybolovlev
arybolovlev marked this pull request as ready for review July 23, 2026 14:28
@arybolovlev
arybolovlev requested a review from a team as a code owner July 23, 2026 14:28
@arybolovlev
arybolovlev requested a review from mhofstetter July 23, 2026 14:28
@arybolovlev
arybolovlev force-pushed the pr/arybolovlev/handle-tcp-udp-routes-with-host-networking branch from 7d52147 to 5010706 Compare July 23, 2026 14:30
@arybolovlev

Copy link
Copy Markdown
Contributor Author

Rebased on main.

@arybolovlev

Copy link
Copy Markdown
Contributor Author

/test

1 similar comment
@cilium-ariane

cilium-ariane Bot commented Jul 23, 2026

Copy link
Copy Markdown

/test

@joestringer joestringer added the release-blocker/1.20 This issue will prevent the release of the next version of Cilium. label Jul 23, 2026
@joestringer joestringer moved this from Proposed to Active in Release blockers Jul 23, 2026

@mhofstetter mhofstetter left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks for this, i left some feedback inline 🚀

Maybe worth to slightly correct the commit message and PR description? IMO something along the following line would be easier to understand and focus on the user-visible parts?

  • reject TCP/UDP listeners in host network mode and update Gateway listener status for unsupported L4 listeners
  • reject TCP- & UDPRoute objects in host network mode and set unsupported status on route objects
  • rejecting TCP/UDP listeners and/or routes doesn't stop the reconciliation of mixed scenarios

Comment thread operator/pkg/gateway-api/gateway_reconcile.go Outdated
Comment thread operator/pkg/gateway-api/gateway_reconcile.go Outdated
@arybolovlev
arybolovlev force-pushed the pr/arybolovlev/handle-tcp-udp-routes-with-host-networking branch from 5010706 to c0e1d5f Compare July 24, 2026 10:25
@arybolovlev

Copy link
Copy Markdown
Contributor Author

/test

This commit correctly handles TCPRoute and UDPRoute when Envoy runs in
host network mode by rejecting unsupported routes, since the current
NodePort-based implementation does not work correctly in this mode.

- Reject TCP/UDP listeners in host network mode and update Gateway
  listener status for unsupported L4 listeners.
- Reject TCPRoute and UDPRoute objects in host network mode and set
  unsupported status on route objects.
- Rejecting TCP/UDP listeners and/or routes doesn't stop
  the reconciliation of mixed scenarios.

Related to cilium#47234

Signed-off-by: Aleksandr Rybolovlev <[email protected]>
@arybolovlev
arybolovlev force-pushed the pr/arybolovlev/handle-tcp-udp-routes-with-host-networking branch from c0e1d5f to 6a4063a Compare July 24, 2026 10:30
@arybolovlev

Copy link
Copy Markdown
Contributor Author

Rebased on top of main to address conflict.

@arybolovlev

Copy link
Copy Markdown
Contributor Author

/test

@mhofstetter mhofstetter left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, thanks!

@cilium-ariane

cilium-ariane Bot commented Jul 24, 2026

Copy link
Copy Markdown

/test

@mhofstetter
mhofstetter added this pull request to the merge queue Jul 24, 2026
Merged via the queue into cilium:main with commit 6148c60 Jul 24, 2026
79 checks passed
@github-project-automation github-project-automation Bot moved this from Active to Done in Release blockers Jul 24, 2026
@maintainer-s-little-helper maintainer-s-little-helper Bot added ready-to-merge This PR has passed all tests and received consensus from code owners to merge. labels Jul 24, 2026
@nbusseneau nbusseneau mentioned this pull request Jul 27, 2026
17 tasks
@nbusseneau nbusseneau added backport-pending/1.20 The backport for Cilium 1.20.x for this PR is in progress. and removed needs-backport/1.20 This PR / issue needs backporting to the v1.20 branch labels Jul 27, 2026
@github-actions github-actions Bot added backport-done/1.20 The backport for Cilium 1.20.x for this PR is done. and removed backport-pending/1.20 The backport for Cilium 1.20.x for this PR is in progress. labels Jul 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/servicemesh GH issues or PRs regarding servicemesh backport-done/1.20 The backport for Cilium 1.20.x for this PR is done. feature/k8s-gateway-api kind/enhancement This would improve or streamline existing functionality. ready-to-merge This PR has passed all tests and received consensus from code owners to merge. release-blocker/1.20 This issue will prevent the release of the next version of Cilium. release-note/misc This PR makes changes that have no direct user impact.

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

6 participants