Skip to content

Commit b31615d

Browse files
committed
comment
1 parent 847f0e6 commit b31615d

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

doc/mgmt/SONiC_YANG_Model_Guidelines.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -500,7 +500,7 @@ container PORTCHANNEL_INTERFACE {
500500

501501
### 18. In some cases it may be required to split an ABNF table into multiple YANG lists based on the data stored in the ABNF table. In this case it is crucial to ensure that the List keys are non-overlapping, unique, and unambiguous.
502502

503-
**Strategies for Ensuring Unique and Unambiguous Keys**: Utilize composite keys that have a different number of key elements to distinguish lists.
503+
**Strategies for Ensuring Unique and Unambiguous Keys**: Utilize composite keys that have a different number of key elements to distinguish lists. Need to mention that different key names do not count as unambiguous model.
504504

505505
#### ABNF
506506
```
@@ -551,7 +551,7 @@ container INTERFACE {
551551
}
552552
......
553553
```
554-
***In the example above if the config DB contains an INTERFACE table with single key element then it will be associted with the INTERFACE_LIST and if contains 2 key elements then it will be associated with INTERFACE_IPADDR_LIST***
554+
In the example above if the config DB contains an INTERFACE table with single key element then it will be associted with the INTERFACE_LIST and if contains 2 key elements then it will be associated with INTERFACE_IPADDR_LIST
555555

556556
#### Example 2: Keys with same number of elements of same type (NOT Allowed case 1)
557557

@@ -577,7 +577,7 @@ container NOT_SUPPORTED_INTERFACE {
577577
......
578578
```
579579

580-
***In the example above if the config DB contains an NOT_SUPPORTED_INTERFACE table with key Ethernet1 then it would match with both the list, this is an overlapping scenario***
580+
In the example above if the config DB contains an NOT_SUPPORTED_INTERFACE table with key Ethernet1 then it would match with both the list, this is an overlapping scenario
581581

582582
#### Example 3: Keys with same number of elements of same type (NOT Allowed case 2)
583583

@@ -623,11 +623,11 @@ container NOT_SUPPORTED_TELEMETRY_CLIENT {
623623
}
624624
......
625625
```
626-
***In the example above if the config DB contains an NOT_SUPPORTED_TELEMETRY_CLIENT table with key "DestinationGroup|HS", then it would correspond to the NOT_SUPPORTED_TELEMETRY_CLIENT_DS_LIST and NOT_SUPPORTED_TELEMETRY_CLIENT_SUB_LIST, this is an overlapping scenario***
626+
In the example above if the config DB contains an NOT_SUPPORTED_TELEMETRY_CLIENT table with key "DestinationGroup|HS", then it would correspond to the NOT_SUPPORTED_TELEMETRY_CLIENT_DS_LIST and NOT_SUPPORTED_TELEMETRY_CLIENT_SUB_LIST, this is an overlapping scenario
627627

628-
#### Example 4: keys with same number of elements and different type(NOT Allowed case 1)
628+
#### Example 4: keys with same number of elements and different type(NOT Allowed case 3)
629629

630-
***In the given example, if the configuration database has an NOT_SUPPORTED_TELEMETRY_CLIENT table with the key "1234", it would correspond to the NOT_SUPPORTED_TELEMETRY_CLIENT_DS_LIST and NOT_SUPPORTED_TELEMETRY_CLIENT_SUB_LIST, this is an overlapping scenario***
630+
In the given example, if the configuration database has an NOT_SUPPORTED_TELEMETRY_CLIENT table with the key "1234", it would correspond to the NOT_SUPPORTED_TELEMETRY_CLIENT_DS_LIST and NOT_SUPPORTED_TELEMETRY_CLIENT_SUB_LIST, this is an overlapping scenario
631631

632632
```yang
633633
......
@@ -647,9 +647,9 @@ container NOT_SUPPORTED_TELEMETRY_CLIENT {
647647
}
648648
649649
list NOT_SUPPORTED_TELEMETRY_CLIENT_SUB_LIST { // Negative case
650-
key "prefix";
650+
key "id";
651651
652-
leaf prefix {
652+
leaf id {
653653
type int32;
654654
}
655655
@@ -662,9 +662,9 @@ container NOT_SUPPORTED_TELEMETRY_CLIENT {
662662
......
663663
```
664664

665-
#### Example 5: keys with same number of elements and different type(NOT Allowed case 2)
665+
#### Example 5: keys with same number of elements and different type(NOT Allowed case 4)
666666

667-
***In the given example, if the configuration database has an NOT_SUPPORTED_TELEMETRY_CLIENT table with the key "1234|1234", it would correspond to the NOT_SUPPORTED_TELEMETRY_CLIENT_DS_LIST and NOT_SUPPORTED_TELEMETRY_CLIENT_SUB_LIST, this is an overlapping scenario***
667+
In the given example, if the configuration database has an NOT_SUPPORTED_TELEMETRY_CLIENT table with the key "1234|1234", it would correspond to the NOT_SUPPORTED_TELEMETRY_CLIENT_DS_LIST and NOT_SUPPORTED_TELEMETRY_CLIENT_SUB_LIST, this is an overlapping scenario
668668

669669
```yang
670670
......
@@ -686,9 +686,9 @@ container NOT_SUPPORTED_TELEMETRY_CLIENT {
686686
}
687687
688688
list NOT_SUPPORTED_TELEMETRY_CLIENT_SUB_LIST { // Negative case
689-
key "prefix name";
689+
key "id name";
690690
691-
leaf prefix {
691+
leaf id {
692692
type int32;
693693
}
694694

0 commit comments

Comments
 (0)