Repository navigation
feat: allow forward-node-ip per gateway via annotation - #200
Merged
Merged
Conversation
njucjc
approved these changes
Oct 9, 2026
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #200 +/- ##
==========================================
+ Coverage 28.36% 29.79% +1.43%
==========================================
Files 35 35
Lines 3624 3638 +14
==========================================
+ Hits 1028 1084 +56
+ Misses 2431 2384 -47
- Partials 165 170 +5
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This covers the 2026 H2 roadmap item "Support NodePool-level configuration of Raven forward-node-ip".
forward-node-ip is currently a single agent flag for the whole cluster. The tunnel engine already decides it per gateway in syncGateway, so this adds a
raven.openyurt.io/forward-node-ipannotation on the Gateway that overrides the global flag ("true"/"false", anything else falls back to the flag). Since every agent reads the same annotation for each gateway, both sides of a tunnel agree on whether that gateway's node IPs are routed. It's the same pattern as the per-gateway enable-proxy/enable-tunnel annotations in openyurtio/openyurt#2578.Added a table test for syncGateway covering the flag and annotation combinations. go vet, golangci-lint and go test ./pkg/engine/... ./pkg/utils/... pass locally.
@njucjc @rambohe-ch @zyjhtangtang could you take a look? If you'd prefer this as a field on the Gateway spec instead of an annotation, happy to rework it.