Skip to content

Conversation

@Verma-Anukul
Copy link
Contributor

@Verma-Anukul Verma-Anukul commented May 9, 2025

HLD Udate
sonic-net/SONiC#1989

  1. Updated openconfig interface yang models to latest available oc community version

Taken all changes till May 7, 2025

oc-interface version "3.8.0"

Add interface-transitions and link-transitions counters
785b890a6369901d5cc227f1a86de98b694305d7

  1. Updated interface deviation file to mark all unsupported nodes as not-supported

Supported tree

module: openconfig-interfaces
  +--rw interfaces
     +--rw interface* [name]
        +--rw name                  -> ../config/name
        +--rw config
        |  +--rw name?          string
        |  +--rw type           identityref
        |  +--rw mtu?           uint16
        |  +--rw description?   string
        |  +--rw enabled?       boolean
        +--ro state
        |  +--ro name?           string
        |  +--ro type            identityref
        |  +--ro mtu?            uint16
        |  +--ro description?    string
        |  +--ro enabled?        boolean
        |  +--ro ifindex?        uint32
        |  +--ro admin-status    enumeration
        |  +--ro oper-status     enumeration
        |  +--ro last-change?    oc-types:timeticks64
        |  +--ro logical?        boolean
        |  +--ro management?     boolean
        |  +--ro cpu?            boolean
        |  +--ro counters
        |     +--ro in-octets?            oc-yang:counter64
        |     +--ro in-pkts?              oc-yang:counter64
        |     +--ro in-unicast-pkts?      oc-yang:counter64
        |     +--ro in-broadcast-pkts?    oc-yang:counter64
        |     +--ro in-multicast-pkts?    oc-yang:counter64
        |     +--ro in-errors?            oc-yang:counter64
        |     +--ro in-discards?          oc-yang:counter64
        |     +--ro out-octets?           oc-yang:counter64
        |     +--ro out-pkts?             oc-yang:counter64
        |     +--ro out-unicast-pkts?     oc-yang:counter64
        |     +--ro out-broadcast-pkts?   oc-yang:counter64
        |     +--ro out-multicast-pkts?   oc-yang:counter64
        |     +--ro out-discards?         oc-yang:counter64
        |     +--ro out-errors?           oc-yang:counter64
        +--rw subinterfaces
        |  +--rw subinterface* [index]
        |     +--rw index         -> ../config/index
        |     +--rw config
        |     |  +--rw index?   uint32
        |     +--ro state
        |     |  +--ro index?   uint32
        |     +--rw oc-ip:ipv4
        |     |  +--rw oc-ip:addresses
        |     |     +--rw oc-ip:address* [ip]
        |     |        +--rw oc-ip:ip        -> ../config/ip
        |     |        +--rw oc-ip:config
        |     |        |  +--rw oc-ip:ip?              oc-inet:ipv4-address
        |     |        |  +--rw oc-ip:prefix-length?   uint8
        |     |        +--ro oc-ip:state
        |     |           +--ro oc-ip:ip?              oc-inet:ipv4-address
        |     |           +--ro oc-ip:prefix-length?   uint8
        |     +--rw oc-ip:ipv6
        |        +--rw oc-ip:addresses
        |        |  +--rw oc-ip:address* [ip]
        |        |     +--rw oc-ip:ip        -> ../config/ip
        |        |     +--rw oc-ip:config
        |        |     |  +--rw oc-ip:ip?              oc-inet:ipv6-address
        |        |     |  +--rw oc-ip:prefix-length    uint8
        |        |     +--ro oc-ip:state
        |        |        +--ro oc-ip:ip?              oc-inet:ipv6-address
        |        |        +--ro oc-ip:prefix-length    uint8
        |        +--rw oc-ip:config
        |        |  +--rw oc-ip:enabled?   boolean
        |        +--ro oc-ip:state
        |           +--ro oc-ip:enabled?   boolean
        +--rw oc-eth:ethernet
        |  +--rw oc-eth:config
        |  |  +--rw oc-eth:auto-negotiate?   boolean
        |  |  +--rw oc-eth:port-speed?       identityref
        |  |  +--rw oc-lag:aggregate-id?     -> /oc-if:interfaces/interface/name
        |  +--ro oc-eth:state
        |     +--ro oc-eth:auto-negotiate?   boolean
        |     +--ro oc-eth:port-speed?       identityref
        |     +--ro oc-eth:counters
        |     |  +--ro oc-eth:in-oversize-frames?    oc-yang:counter64
        |     |  +--ro oc-eth:in-undersize-frames?   oc-yang:counter64
        |     |  +--ro oc-eth:in-jabber-frames?      oc-yang:counter64
        |     |  +--ro oc-eth:in-fragment-frames?    oc-yang:counter64
        |     |  +--ro oc-eth-ext:in-distribution
        |     |     +--ro oc-eth-ext:in-frames-64-octets?          oc-yang:counter64
        |     |     +--ro oc-eth-ext:in-frames-65-127-octets?      oc-yang:counter64
        |     |     +--ro oc-eth-ext:in-frames-128-255-octets?     oc-yang:counter64
        |     |     +--ro oc-eth-ext:in-frames-256-511-octets?     oc-yang:counter64
        |     |     +--ro oc-eth-ext:in-frames-512-1023-octets?    oc-yang:counter64
        |     |     +--ro oc-eth-ext:in-frames-1024-1518-octets?   oc-yang:counter64
        |     +--ro oc-lag:aggregate-id?     -> /oc-if:interfaces/interface/name
        +--rw oc-lag:aggregation
           +--rw oc-lag:config
           |  +--rw oc-lag:min-links?   uint16
           +--ro oc-lag:state
              +--ro oc-lag:min-links?   uint16
  1. Fix for portchannel creation issue Not able to create New PortChannel interface from gNMI/REST interface #153

  2. Fix for gnmi server crash on delete operation at interface/config node

  3. Adding support for new interface leaves

config/type
state/type
state/ifindex
state/oper-status
state/last-change
state/management
state/cpu
state/logical
  1. Other minor issues fix found during testing

How did I verify
Added test cases for new nodes and ran full test cases

coverage: 41.8% of statements in ../translib/transformer
+ generate_html_report coverage.transformer
+ /usr/local/go/bin/go tool cover -html=coverage.transformer -o .//coverage.transformer.html
+ popd
/nobackup/anukverm/workspace/projects/google-ostara/upstream/buildimage-compilation/sonic-buildimage/src/sonic-mgmt-common
+ exit 0

- Added missing samping-rate node in deviation file
- Give error when delete op is done at collector/config nodes
--
Taken all changes till May 7, 2025

oc-interface version "3.8.0"

Add interface-transitions and link-transitions counters
785b890a6369901d5cc227f1a86de98b694305d7
Supported interface tree
--------
```
module: openconfig-interfaces
  +--rw interfaces
     +--rw interface* [name]
        +--rw name                  -> ../config/name
        +--rw config
        |  +--rw name?          string
        |  +--rw mtu?           uint16
        |  +--rw description?   string
        |  +--rw enabled?       boolean
        +--ro state
        |  +--ro name?           string
        |  +--ro mtu?            uint16
        |  +--ro description?    string
        |  +--ro enabled?        boolean
        |  +--ro admin-status    enumeration
        |  +--ro counters
        |     +--ro in-octets?            oc-yang:counter64
        |     +--ro in-pkts?              oc-yang:counter64
        |     +--ro in-unicast-pkts?      oc-yang:counter64
        |     +--ro in-broadcast-pkts?    oc-yang:counter64
        |     +--ro in-multicast-pkts?    oc-yang:counter64
        |     +--ro in-errors?            oc-yang:counter64
        |     +--ro in-discards?          oc-yang:counter64
        |     +--ro out-octets?           oc-yang:counter64
        |     +--ro out-pkts?             oc-yang:counter64
        |     +--ro out-unicast-pkts?     oc-yang:counter64
        |     +--ro out-broadcast-pkts?   oc-yang:counter64
        |     +--ro out-multicast-pkts?   oc-yang:counter64
        |     +--ro out-discards?         oc-yang:counter64
        |     +--ro out-errors?           oc-yang:counter64
        +--rw subinterfaces
        |  +--rw subinterface* [index]
        |     +--rw index         -> ../config/index
        |     +--rw config
        |     |  +--rw index?   uint32
        |     +--ro state
        |     |  +--ro index?   uint32
        |     +--rw oc-ip:ipv4
        |     |  +--rw oc-ip:addresses
        |     |     +--rw oc-ip:address* [ip]
        |     |        +--rw oc-ip:ip        -> ../config/ip
        |     |        +--rw oc-ip:config
        |     |        |  +--rw oc-ip:ip?              oc-inet:ipv4-address
        |     |        |  +--rw oc-ip:prefix-length?   uint8
        |     |        +--ro oc-ip:state
        |     |           +--ro oc-ip:ip?              oc-inet:ipv4-address
        |     |           +--ro oc-ip:prefix-length?   uint8
        |     +--rw oc-ip:ipv6
        |        +--rw oc-ip:addresses
        |        |  +--rw oc-ip:address* [ip]
        |        |     +--rw oc-ip:ip        -> ../config/ip
        |        |     +--rw oc-ip:config
        |        |     |  +--rw oc-ip:ip?              oc-inet:ipv6-address
        |        |     |  +--rw oc-ip:prefix-length    uint8
        |        |     +--ro oc-ip:state
        |        |        +--ro oc-ip:ip?              oc-inet:ipv6-address
        |        |        +--ro oc-ip:prefix-length    uint8
        |        +--rw oc-ip:config
        |        |  +--rw oc-ip:enabled?   boolean
        |        +--ro oc-ip:state
        |           +--ro oc-ip:enabled?   boolean
        +--rw oc-eth:ethernet
        |  +--rw oc-eth:config
        |  |  +--rw oc-eth:auto-negotiate?   boolean
        |  |  +--rw oc-eth:port-speed?       identityref
        |  |  +--rw oc-lag:aggregate-id?     -> /oc-if:interfaces/interface/name
        |  +--ro oc-eth:state
        |     +--ro oc-eth:auto-negotiate?   boolean
        |     +--ro oc-eth:port-speed?       identityref
        |     +--ro oc-eth:counters
        |     |  +--ro oc-eth:in-oversize-frames?    oc-yang:counter64
        |     |  +--ro oc-eth:in-undersize-frames?   oc-yang:counter64
        |     |  +--ro oc-eth:in-jabber-frames?      oc-yang:counter64
        |     |  +--ro oc-eth:in-fragment-frames?    oc-yang:counter64
        |     |  +--ro oc-eth-ext:in-distribution
        |     |     +--ro oc-eth-ext:in-frames-64-octets?          oc-yang:counter64
        |     |     +--ro oc-eth-ext:in-frames-65-127-octets?      oc-yang:counter64
        |     |     +--ro oc-eth-ext:in-frames-128-255-octets?     oc-yang:counter64
        |     |     +--ro oc-eth-ext:in-frames-256-511-octets?     oc-yang:counter64
        |     |     +--ro oc-eth-ext:in-frames-512-1023-octets?    oc-yang:counter64
        |     |     +--ro oc-eth-ext:in-frames-1024-1518-octets?   oc-yang:counter64
        |     +--ro oc-lag:aggregate-id?     -> /oc-if:interfaces/interface/name
        +--rw oc-lag:aggregation
           +--rw oc-lag:config
           |  +--rw oc-lag:min-links?   uint16
           +--ro oc-lag:state
              +--ro oc-lag:min-links?   uint16
```
@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

config/type
state/type
state/ifindex
state/oper-status
state/last-change
state/management
state/cpu
state/logical
aggregate/lag-type
@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@Verma-Anukul
Copy link
Contributor Author

@kwangsuk @anand-kumar-subramanian @mbalachandar @amrutasali @sachinholla @sneelam20

Please help in review and merge

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@Verma-Anukul
Copy link
Contributor Author

@kwangsuk @sneelam20 @anand-kumar-subramanian

I have rebased the change after vlan interface merge.
Please help in merging this approved PR

@Verma-Anukul
Copy link
Contributor Author

@kwangsuk @sneelam20 @anand-kumar-subramanian

Please help in merging this approved PR

2 similar comments
@Verma-Anukul
Copy link
Contributor Author

@kwangsuk @sneelam20 @anand-kumar-subramanian

Please help in merging this approved PR

@Verma-Anukul
Copy link
Contributor Author

@kwangsuk @sneelam20 @anand-kumar-subramanian

Please help in merging this approved PR

@mssonicbld
Copy link

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@Verma-Anukul
Copy link
Contributor Author

@kwangsuk
Can you please help in merging this approved PR

@Verma-Anukul
Copy link
Contributor Author

@kwangsuk @sneelam20 @anand-kumar-subramanian

Please help in merging this approved PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants