Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added mclag sonic yang #7622

Merged
merged 59 commits into from
Jan 27, 2022
Merged
Show file tree
Hide file tree
Changes from 30 commits
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
97bbc74
added mclag sonic yang
gitsabari May 17, 2021
a6ba02b
updated sonic mclag
gitsabari Jun 1, 2021
8b6f45e
updated sonic mclag yang
gitsabari Jun 1, 2021
076ceb6
fixed mclag sonic yang dependencies issues
gitsabari Jun 1, 2021
aa47903
fixed sonic mclag errors
gitsabari Jun 1, 2021
0162309
updated sonic mclag yang
gitsabari Jun 15, 2021
16a59ed
addressed review comments, added some mclag ut cases
gitsabari Jul 28, 2021
e640464
Merge branch 'master' into mclag_enhacements
gitsabari Jul 28, 2021
7f87932
corrected mclag test json format issues
gitsabari Jul 28, 2021
0527da5
updated sample mclag config file
gitsabari Jul 28, 2021
41d7622
fixed error with mclag test json files
gitsabari Jul 28, 2021
f8c4ad0
fixed mclag build issue
gitsabari Jul 28, 2021
a86adf3
removed state db related yang changes which has dependency on sonic-e…
gitsabari Jul 29, 2021
91402ad
fixed mclag samle config
gitsabari Jul 29, 2021
60503c4
fixed mclag test config file
gitsabari Jul 29, 2021
b44248d
fixed mclag test case file
gitsabari Jul 29, 2021
0cbfaac
updated mclag test case
gitsabari Jul 29, 2021
87089c0
fix mclag case
gitsabari Jul 29, 2021
c6a2cbd
updated mclag test cases
gitsabari Jul 29, 2021
f5a9ac0
fixed mclag test case issue
gitsabari Jul 29, 2021
6253252
fixed mclag test case
gitsabari Jul 29, 2021
c36e6c8
updated mclag test case
gitsabari Jul 29, 2021
e44f31e
updated mclag test case
gitsabari Jul 29, 2021
32f1871
fixed mclag test load failure
gitsabari Jul 29, 2021
58bc90d
fixed mclag test case
gitsabari Jul 29, 2021
a3c7753
updated mclag test cases
gitsabari Jul 29, 2021
1271c86
fixed mclag test case
gitsabari Jul 29, 2021
bac56a9
fixed mclag test case
gitsabari Jul 29, 2021
c1373f8
corrected mclag test case failure
gitsabari Jul 29, 2021
a990d63
updated mclag test case
gitsabari Jul 29, 2021
3df4433
addressed review comments and fixed test cases
gitsabari Oct 1, 2021
1fb1e33
Merge branch 'master' into mclag_enhacements
gitsabari Oct 1, 2021
46fb2d3
corrected test cases
gitsabari Oct 4, 2021
88b774e
addressed review comments
gitsabari Oct 12, 2021
39955fb
addressed review comments
gitsabari Oct 22, 2021
be18bed
fixed test run errors
gitsabari Oct 22, 2021
30d380b
fixed test failures
gitsabari Oct 23, 2021
4dd6a95
fixed test case failure
gitsabari Oct 25, 2021
962d51a
fixed test case
gitsabari Oct 25, 2021
8a50409
fixed test case
gitsabari Oct 25, 2021
7cb15e4
fixed test case
gitsabari Oct 25, 2021
d94b084
fixed test case
gitsabari Oct 25, 2021
766b2fd
fixed test case
gitsabari Oct 25, 2021
668b04b
fixed test case
gitsabari Oct 26, 2021
d1e47a4
fixed test case
gitsabari Oct 26, 2021
99f593b
fixed test case
gitsabari Oct 26, 2021
2c266d9
fixed test case
gitsabari Oct 26, 2021
3c09a40
fixed test case
gitsabari Oct 29, 2021
5058465
fixed test case
gitsabari Nov 10, 2021
0a7a3ca
Merge branch 'master' into mclag_enhacements
gitsabari Nov 18, 2021
c419b58
resolving issue with sample config json
gitsabari Nov 18, 2021
e58e143
Merge branch 'master' into mclag_enhacements
gitsabari Dec 8, 2021
5aecb78
addressed review comments
gitsabari Dec 16, 2021
b6df637
addressed review comment
gitsabari Dec 16, 2021
a549a9c
Merge branch 'master' into mclag_enhacements
gitsabari Jan 13, 2022
d2fe61e
commenting sonic vlan import and reference until libyang back-links i…
gitsabari Jan 25, 2022
cc6bb1e
commenting libyang back-links reference issue#9312 related test cases…
gitsabari Jan 25, 2022
f39124d
commenting libyang back-links reference issue#9312 related test cases…
gitsabari Jan 25, 2022
01e664a
removed back-links reference issue#9312 related test cases until the
gitsabari Jan 25, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/sonic-yang-models/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@
'./yang-models/sonic-versions.yang',
'./yang-models/sonic-vlan.yang',
'./yang-models/sonic-vrf.yang',
'./yang-models/sonic-mclag.yang',
'./yang-models/sonic_yang_tree']),
],
zip_safe=False,
Expand Down
49 changes: 46 additions & 3 deletions src/sonic-yang-models/tests/files/sample_config_db.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,16 @@
"tpid": "0x9200",
"mtu": "9100",
"lacp_key": "auto"
},
"PortChannel2": {
"admin_status": "up",
"min_links": "1",
"members": [
"Ethernet12"
],
"tpid": "0x9200",
"mtu": "9100",
"lacp_key": "auto"
}
},
"PORTCHANNEL_INTERFACE": {
Expand All @@ -34,7 +44,8 @@
},
"PORTCHANNEL_MEMBER": {
"PortChannel0003|Ethernet1": {},
"PortChannel0004|Ethernet2": {}
"PortChannel0004|Ethernet2": {},
"PortChannel2|Ethernet12": {}
},
"VLAN_INTERFACE": {
"Vlan111": {
Expand Down Expand Up @@ -232,7 +243,17 @@
"vlanid": "777",
"mtu": "9216",
"admin_status": "up"
}
},
"Vlan12": {
"description": "mclag session ve",
"dhcp_servers": [
"12.1.1.1"
],
"vlanid": "12",
"mtu": "9216",
"admin_status": "up"
},

},
"DEVICE_NEIGHBOR": {
"Ethernet112": {
Expand Down Expand Up @@ -805,6 +826,9 @@
},
"Vlan111|PortChannel0003": {
"tagging_mode": "untagged"
},
"Vlan12|PortChannel2": {
"tagging_mode": "tagged"
}
},
"LOOPBACK_INTERFACE": {
Expand Down Expand Up @@ -1011,9 +1035,28 @@
"trap_ids": "ip2me",
"trap_group": "queue1_group1"
}
},

"MCLAG_DOMAIN": {
Copy link
Collaborator

Choose a reason for hiding this comment

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

add this configuration in https://github.com/Azure/SONiC/wiki/Configuration as source of truth, if not added already.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

sure will do

"123": {
"source_ip": "12.1.1.1",
"peer_ip": "12.1.1.2",
"peer_link": "PortChannel2",
"keepalive_interval": "1",
"session_timeout": "30"
}
},
"MCLAG_INTERFACE": {
"123|PortChannel0004": {
"if_type": "PortChannel"
}
},
"MCLAG_UNIQUE_IP": {
"Vlan12": {
"unique_ip": "enable"
}
}
},

"SAMPLE_CONFIG_DB_UNKNOWN": {
"UNKNOWN_TABLE": {
"Error": "This Table is for testing, This Table does not have YANG models."
Expand Down
36 changes: 36 additions & 0 deletions src/sonic-yang-models/tests/yang_model_tests/tests/mclag.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"MCLAG_VALID_DOMAIN_CFG_TEST": {
"desc": "valid mclag configuration test"
},
"MCLAG_VALID_DOMAIN_PEERLINK_ETH_TEST": {
"desc": "valid mclag configuration test with peer link ethernet"
},
"MCLAG_INVALID_DOMAIN_IDS_TEST": {
"desc": "configure mclag domain id in range"
},
"MCLAG_INVALID_KEEPALIVE_TEST": {
gitsabari marked this conversation as resolved.
Show resolved Hide resolved
"desc": "configure mclag keepalive values in range"
},
"MCLAG_INVALID_SESSION_TIMEOUT_TEST": {
"desc": "configure mclag session timeout in range"
gitsabari marked this conversation as resolved.
Show resolved Hide resolved
},
"MCLAG_INVALID_KEEPALIVE_MUST_COND_TEST": {
"desc": "Invalid session and keepalive multiplier",
"eStrKey" : "Must",
gitsabari marked this conversation as resolved.
Show resolved Hide resolved
"eStr": ["session_timeout"]
},
"MCLAG_INTERFACE_DOMAIN_ABSENT_TEST": {
"desc": "mclag interface configured without domain",
"eStr": ["domain_id"]
},
"MCLAG_UNIQUE_IP_DOMAIN_ABSENT_TEST": {
"desc": "mclag unique ip configured without domain",
"eStrKey" : "Must",
"eStr": ["domain_id"]
},
"MCLAG_UNIQUE_IP_ADDR_PRESENT_MUST_TEST": {
"desc": "mclag unique ip configured without domain",
"eStrKey" : "Must",
"eStr": ["domain_id"]
}
}
Loading