Repository navigation
Conversation
* (M) release/models/interfaces/openconfig-if-tunnel.yang
- Add tunnel container under subinterface for interfaces of type
tunnel
- Deprecate interface level tunnel container, including
tunnel/ipv4 and tunnel/ipv6
- Increment version to 0.2.0
* (M) release/models/vlan/openconfig-vlan.yang
- Add routed-vlan container under subinterface for interfaces of
type l3ipvlan
- Deprecate interface level routed-vlan container, including
routed-vlan/ipv4 and routed-vlan/ipv6
- Increment version to 3.3.0
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request updates the OpenConfig models to standardize the configuration of tunnel and routed-vlan interfaces. By moving these configurations under the subinterface hierarchy, the models now follow the same pattern used by other L3 interfaces in OpenConfig. The changes are additive and backward-compatible, with existing paths marked as deprecated to signal the transition to the new structure. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request updates the OpenConfig interface tunnel and VLAN models by deprecating the interface-level tunnel and routed-vlan containers and introducing them under subinterfaces instead. The review comment provides a detailed platform implementation comparison across major network operating systems, confirming that the changes comply with OpenConfig guidelines for vendor-neutral modeling.
| revision "2026-11-05" { | ||
| description | ||
| "Add tunnel configuration under subinterfaces for interfaces | ||
| of type tunnel. Deprecate the interface level tunnel | ||
| container, including tunnel/ipv4 and tunnel/ipv6, in favor of | ||
| the subinterface tunnel container and | ||
| subinterfaces/subinterface/ipv4|ipv6."; | ||
| reference "0.2.0"; | ||
| } |
There was a problem hiding this comment.
Platform Implementation Comparison
In accordance with the Repository Style Guide (Section 2, Rules 12-18), here is a comparison of the proposed YANG changes (moving "tunnel" and "routed-vlan" under subinterfaces) with the reference implementations of major network operating systems:
| Network OS | Feature / Container | Command / Configuration Example | Documentation Link | Match Strength |
|---|---|---|---|---|
| Cisco IOS-XR | Tunnel | interface Tunnel-IP1tunnel mode gre ipv4tunnel source IPtunnel destination IP |
Cisco IOS-XR Tunnel Configuration Guide | Strong (flat interface, maps to subinterface 0) |
| Cisco IOS-XR | Routed VLAN (IRB/SVI) | interface BVI100ipv4 address 192.0.2.1 255.255.255.0 |
Cisco IOS-XR Bridging Configuration Guide | Strong (flat interface, maps to subinterface 0) |
| Nokia SR Linux | Tunnel | tunnel-interface tunnel-1vxlan-interface 1 |
Nokia SR Linux Interfaces Guide | Strong (supports subinterfaces natively) |
| Nokia SR Linux | Routed VLAN (IRB) | interface irb1subinterface 1ipv4 { address 192.168.1.1/24 } |
Nokia SR Linux IRB Interfaces Guide | Strong (supports subinterfaces natively) |
| Juniper JunOS | Tunnel | set interfaces fti0 unit 1 tunnel encapsulation greset interfaces fti0 unit 1 family inet address 10.0.0.1/31 |
Juniper JunOS Tunnel Configuration Guide | Strong (supports logical units/subinterfaces natively) |
| Juniper JunOS | Routed VLAN (IRB) | set interfaces irb unit 10 family inet address 10.10.0.1/24 |
Juniper JunOS IRB Interfaces Guide | Strong (supports logical units/subinterfaces natively) |
| Arista EOS | Tunnel | interface Tunnel1tunnel mode greip address 10.0.0.1/30 |
Arista EOS Tunnel Interfaces Guide | Strong (flat interface, maps to subinterface 0) |
| Arista EOS | Routed VLAN (SVI) | interface Vlan100ip address 192.0.2.1/24 |
Arista EOS VLAN Interfaces Guide | Strong (flat interface, maps to subinterface 0) |
| NVIDIA Cumulus | Tunnel | nv set interface gre0 ip tunnel source 192.0.2.1nv set interface gre0 ip tunnel destination 192.0.2.2 |
NVIDIA Cumulus Linux Tunneling Guide | Strong (flat interface, maps to subinterface 0) |
| NVIDIA Cumulus | Routed VLAN (SVI) | nv set interface vlan100 ip address 192.0.2.1/24 |
NVIDIA Cumulus Linux SVI Guide | Strong (flat interface, maps to subinterface 0) |
| SONiC | Tunnel | CONFIG_DB VXLAN_TUNNEL table |
SONiC VXLAN HLD | Strong (flat interface, maps to subinterface 0) |
| SONiC | Routed VLAN (SVI) | CONFIG_DB VLAN_INTERFACE table |
SONiC VLAN HLD | Strong (flat interface, maps to subinterface 0) |
Conclusion
Since all six reference implementations have a strong match with the proposed YANG changes (either natively supporting subinterfaces/logical units, or mapping flat interfaces to subinterface index 0), this change meets the minimum OpenConfig guidelines for vendor-neutral modeling.
References
- Compare the YANG changes with the documentation of implementations of network operating systems from Cisco IOS-XR, Nokia SR Linux, Juniper JunOS/JunOS Evolved, Arista EOS, NVIDIA Cumulus Linux and SONiC, generating a table comparing the affected OpenConfig leaves/containers with links to relevant documentation. (link)
- Ensure that documentation references for network operating system implementations (such as Arista EOS, Juniper JunOS, and Cisco IOS-XR) are publicly accessible and point to the correct, working URLs.
tunnel
tunnel/ipv4 and tunnel/ipv6
type l3ipvlan
routed-vlan/ipv4 and routed-vlan/ipv6
Change Scope
Per discussion in #1597 (revisiting #781) and the OC community call
(2026-11-05), this PR proposes to relocate
tunnelandrouted-vlanto thesame interface/subinterface pattern used by every other L3 interface in OC,
while leaving the existing paths in place.
subinterface/tunnelcarries tunnel parameters, L3 is configured via theexisting
subinterface/ipv4|ipv6subinterface/routed-vlancarries the VLAN binding, L3 (including VRRP) isconfigured via the existing
subinterface/ipv4|ipv6whenon the parent interface type (tunnelandl3ipvlanrespectively)tunnelandrouted-vlancontainers are markedstatus deprecatedso tooling flags them (not only description text)subinterface index 0, same as any other flat L3 interface today
Backwards compatible - additive w/ deprecation only, no existing paths are
removed or changed.
Platform Implementations
HPE Networking: JUNOS
Tunnels and IRB are logical units of a parent interface
Nokia: SR Linux
IRB interfaces (
irbN) are subdivided into subinterfaces like any otherinterface
Current vendor support of the existing paths is summarized in #1597.
Tree View
module: openconfig-interfaces +--rw interfaces +--rw interface* [name] ... +--rw subinterfaces | +--rw subinterface* [index] | ... + | +--rw oc-vlan:routed-vlan + | | +--rw oc-vlan:config + | | | +--rw oc-vlan:vlan? union + | | +--ro oc-vlan:state + | | +--ro oc-vlan:vlan? union | +--rw oc-ip:ipv4 | ... | +--rw oc-ip:ipv6 | ... + | +--rw oc-tun:tunnel + | +--rw oc-tun:config + | | +--rw oc-tun:src? oc-inet:ip-address + | | +--rw oc-tun:dst? oc-inet:ip-address + | | +--rw oc-tun:ttl? uint8 + | | +--rw oc-tun:gre-key? uint32 + | +--ro oc-tun:state + | +--ro oc-tun:src? oc-inet:ip-address + | +--ro oc-tun:dst? oc-inet:ip-address + | +--ro oc-tun:ttl? uint8 + | +--ro oc-tun:gre-key? uint32 ... - +--rw oc-vlan:routed-vlan + x--rw oc-vlan:routed-vlan | ... - +--rw oc-tun:tunnel + x--rw oc-tun:tunnel ...Future scope/items
WiFi (out of scope, needs follow-up)
openconfig-ap-interfacesreusesoc-tun:tunnel-top, so the AP interfacelevel
tunnelalso shows as deprecated with this change. It continues towork as-is. The equivalent
subinterface/tunnelanchor for the AP model isleft for a follow-up w/ the wifi maintainers.
Deprecated path removal
tunnelandrouted-vlancontainers to betargeted for a future major version once implementations and featureprofiles
have migrated