Switchport Modes Port & Port Channel Yang Model Configurations#13580
Switchport Modes Port & Port Channel Yang Model Configurations#13580qiluo-msft merged 250 commits intosonic-net:masterfrom
Conversation
|
Please help on the review. Thanks. |
|
Please fix unit test: libyang[0]: Invalid keyword "routed|access|trunk.". (path: /sonic-port:sonic-port/PORT/PORT_LIST/mode) |
|
This will target 202305 release. |
|
@ridahanif96 will fix the build failure. |
| } | ||
| } | ||
| } | ||
| } No newline at end of file |
There was a problem hiding this comment.
added space at end of file. Fixed.
| "sonic-portchannel:PORTCHANNEL": { | ||
| "PORTCHANNEL_LIST": [ | ||
| { | ||
| "admin_status": "up", |
There was a problem hiding this comment.
Why do you remove admin_status?
| type inet:ipv6-address; | ||
| } | ||
|
|
||
|
|
| type yang:mac-address; | ||
| } | ||
|
|
||
|
|
|
|
||
| leaf port { | ||
| leaf port | ||
| { |
| /* key elements are mandatory by default */ | ||
| type union { | ||
| type leafref { | ||
| type leafref |
| "mtu": 9000, | ||
| "name": "Ethernet0", | ||
| "speed": 25000 | ||
| "speed": 25000 |
| "mtu": 9000, | ||
| "name": "Ethernet1", | ||
| "speed": 25000 | ||
| "speed": 25000 |
|
@qiluo-msft please help merge this PR! Thanks! |
|
@qiluo-msft can you pls help merge this PR! Thanks |
We need the port mode change. |
|
@qiluo-msft pls merge this PR |
|
This is disruptive change per @qiluo-msft |
| leaf mode { | ||
| description "SwitchPort Modes possible values are routed|access|trunk. Default value for mode is routed"; | ||
| type stypes:switchport_mode; | ||
| default "routed"; |
There was a problem hiding this comment.
The default value will introduce disruptive change. The current behavior is conditional "default value".
#### Why I did it Removed Default Mode value from sonic-port.yang & sonic-portchannel.yang to avoid disruptive change #### How I did it This PR is created in reference with [PR](#13580)
Why I did it
Modified "sonic-port.yang" for adding support in Port Yang model for the "mode" attribute for adding port modes
Modified "sonic-portchannel.yang" for adding support in Port Channel Yang model for the "mode" attribute for adding port modes
Updated tests for these modifications
How to verify it