Skip to content

Commit 9f814e3

Browse files
[yang_models]: Updated extensions and types yang models as per review comments.
1 parent 90fe5de commit 9f814e3

File tree

2 files changed

+14
-13
lines changed

2 files changed

+14
-13
lines changed

src/sonic-yang-models/yang-models/sonic-extension.yang

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ module sonic-extension {
1515
description "First Revision";
1616
}
1717

18-
/* For complete guide of using these extensions in SONiC yangs, refer
19-
SONiC yang guidelines at
20-
https://github.com/Azure/SONiC/blob/master/doc/mgmt/SONiC_YANG_Model_Guidelines.md */
18+
/* For complete guide of using these extensions in SONiC yangs, refer
19+
SONiC yang guidelines at
20+
https://github.com/Azure/SONiC/blob/master/doc/mgmt/SONiC_YANG_Model_Guidelines.md */
2121

2222
extension key-regex-configdb-to-yang {
2323
description "Key regex used to convert config DB keys to YANG Config";
@@ -52,17 +52,18 @@ module sonic-extension {
5252
}
5353

5454
extension custom-validation {
55-
description "Extension for registering custom validation handler.";
56-
argument "handler";
55+
description "Extension for registering custom validation handler.";
56+
argument "handler";
5757
}
5858

5959
extension dependent-on {
6060
description
61-
"Extension to define dependency on other table. During create/update,
62-
operation will be performed first on parent table and then on this table.
63-
In delete operation, this table will be deleted first and then parent table.
64-
This extension can be defined only under list. Table name should always
65-
suffixed with '_LIST' as modeled in yang.
61+
"Extension to define dependency on other table. During CREATE/UPDATE,
62+
the action will be performed first on the Parent table and then on the
63+
Dependent table. In DELETE operation, the Dependent table will be
64+
deleted first and then the Parent table. This extension can be defined
65+
only under List nodes. Table name should always be suffixed with '_LIST'
66+
as modeled in yang.
6667
e.g. - dependent-on STP_LIST";
6768
argument "value";
6869
}

src/sonic-yang-models/yang-models/sonic-types.yang

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -118,10 +118,10 @@ module sonic-types {
118118
enum up;
119119
enum down;
120120
}
121-
description "Operational status of an entity such as Port, MCLAG etc";
121+
description "Operational status of an entity such as Port, MCLAG etc";
122122
}
123123

124-
typedef mode-enable {
124+
typedef mode-status {
125125
type enumeration {
126126
enum enable;
127127
enum disable;
@@ -131,7 +131,7 @@ module sonic-types {
131131
For ex. IPv6-link-local-only, Dhcp-replay-link-select, SNMP traps etc";
132132
}
133133

134-
typedef relay-policy-action {
134+
typedef dhcp-relay-policy-action {
135135
type enumeration {
136136
enum discard;
137137
enum append;

0 commit comments

Comments
 (0)