-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Yang] [CBF Maps] SONiC CBF MAPs Yang (#9116)
* SONiC CBF MAPs Yang Created SONiC Yang model for the following CBF MAPs: DSCP_TO_FC_MAP EXP_TO_FC
- Loading branch information
1 parent
f501311
commit c5d0df1
Showing
7 changed files
with
368 additions
and
23 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
24 changes: 24 additions & 0 deletions
24
src/sonic-yang-models/tests/yang_model_tests/tests/cbfmaps.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
{ | ||
"DSCP_TO_FC_MAP_CREATE": { | ||
"desc": "Configure a DSCP to Forwarding class map." | ||
}, | ||
"DSCP_TO_FC_MAP_CREATE_INVALID_DSCP": { | ||
"desc": "Configure a DSCP to Forwarding class map with invalid key.", | ||
"eStr": "Invalid DSCP" | ||
}, | ||
"DSCP_TO_FC_MAP_CREATE_INVALID_FC": { | ||
"desc": "Configure a DSCP to Forwarding class map with invalid value.", | ||
"eStr": "Invalid Forwarding Class" | ||
}, | ||
"EXP_TO_FC_MAP_CREATE": { | ||
"desc": "Configure a EXP to Forwarding class map." | ||
}, | ||
"EXP_TO_FC_MAP_CREATE_INVALID_EXP": { | ||
"desc": "Configure a EXP to Forwarding class map with invalid key.", | ||
"eStr": "Invalid EXP" | ||
}, | ||
"EXP_TO_FC_MAP_CREATE_INVALID_FC": { | ||
"desc": "Configure a EXP to Forwarding class map with invalid value.", | ||
"eStr": "Invalid Forwarding Class" | ||
} | ||
} |
159 changes: 159 additions & 0 deletions
159
src/sonic-yang-models/tests/yang_model_tests/tests_config/cbfmaps.json
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,159 @@ | ||
{ | ||
"DSCP_TO_FC_MAP_CREATE": { | ||
"sonic-dscp-fc-map:sonic-dscp-fc-map": { | ||
"sonic-dscp-fc-map:DSCP_TO_FC_MAP": { | ||
"DSCP_TO_FC_MAP_LIST": [ | ||
{ | ||
"name": "map1", | ||
"DSCP_TO_FC_MAP": [ | ||
{ | ||
"dscp": "1", | ||
"fc": "1" | ||
}, | ||
{ | ||
"dscp":"2", | ||
"fc":"2" | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "map2", | ||
"DSCP_TO_FC_MAP": [ | ||
{ | ||
"dscp": "1", | ||
"fc": "1" | ||
}, | ||
{ | ||
"dscp":"2", | ||
"fc":"2" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
|
||
"DSCP_TO_FC_MAP_CREATE_INVALID_DSCP": { | ||
"sonic-dscp-fc-map:sonic-dscp-fc-map": { | ||
"sonic-dscp-fc-map:DSCP_TO_FC_MAP": { | ||
"DSCP_TO_FC_MAP_LIST": [ | ||
{ | ||
"name": "map3", | ||
"DSCP_TO_FC_MAP": [ | ||
{ | ||
"dscp": "64", | ||
"fc": "1" | ||
}, | ||
{ | ||
"dscp":"2", | ||
"fc":"2" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
|
||
"DSCP_TO_FC_MAP_CREATE_INVALID_FC": { | ||
"sonic-dscp-fc-map:sonic-dscp-fc-map": { | ||
"sonic-dscp-fc-map:DSCP_TO_FC_MAP": { | ||
"DSCP_TO_FC_MAP_LIST": [ | ||
{ | ||
"name": "map3", | ||
"DSCP_TO_FC_MAP": [ | ||
{ | ||
"dscp": "1", | ||
"fc": "8" | ||
}, | ||
{ | ||
"dscp":"2", | ||
"fc":"2" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
|
||
"EXP_TO_FC_MAP_CREATE": { | ||
"sonic-exp-fc-map:sonic-exp-fc-map": { | ||
"sonic-exp-fc-map:EXP_TO_FC_MAP": { | ||
"EXP_TO_FC_MAP_LIST": [ | ||
{ | ||
"name": "map1", | ||
"EXP_TO_FC_MAP": [ | ||
{ | ||
"exp": "1", | ||
"fc": "1" | ||
}, | ||
{ | ||
"exp":"2", | ||
"fc":"2" | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "map2", | ||
"EXP_TO_FC_MAP": [ | ||
{ | ||
"exp": "1", | ||
"fc": "1" | ||
}, | ||
{ | ||
"exp":"2", | ||
"fc":"2" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
|
||
"EXP_TO_FC_MAP_CREATE_INVALID_EXP": { | ||
"sonic-exp-fc-map:sonic-exp-fc-map": { | ||
"sonic-exp-fc-map:EXP_TO_FC_MAP": { | ||
"EXP_TO_FC_MAP_LIST": [ | ||
{ | ||
"name": "map3", | ||
"EXP_TO_FC_MAP": [ | ||
{ | ||
"exp": "8", | ||
"fc": "1" | ||
}, | ||
{ | ||
"exp":"2", | ||
"fc":"2" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
|
||
"EXP_TO_FC_MAP_CREATE_INVALID_FC": { | ||
"sonic-exp-fc-map:sonic-exp-fc-map": { | ||
"sonic-exp-fc-map:EXP_TO_FC_MAP": { | ||
"EXP_TO_FC_MAP_LIST": [ | ||
{ | ||
"name": "map3", | ||
"EXP_TO_FC_MAP": [ | ||
{ | ||
"exp": "1", | ||
"fc": "8" | ||
}, | ||
{ | ||
"exp":"2", | ||
"fc":"2" | ||
} | ||
] | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.