Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the OpenConfig BGP models to version 9.10.0 and adds a new sent-path-count leaf to the neighbor state to track advertised paths post-policy. A review comment suggests renaming this leaf to sent-paths and updating its description to maintain consistency with existing BGP model terminology and naming patterns.
| leaf sent-path-count { | ||
| type uint32; | ||
| description | ||
| "The number of add-paths advertised to a neighbor after | ||
| the post-policy Adj-RIB-Out. This value reflects the total | ||
| number of paths present in the post-policy Adj-RIB-Out for | ||
| the neighbor once add-path configuration is applied."; | ||
| } |
There was a problem hiding this comment.
The leaf name sent-path-count is inconsistent with the existing total-paths leaf defined in openconfig-bgp-common.yang. Renaming it to sent-paths would improve consistency across the BGP model. Additionally, the description can be refined to refer to 'paths' generally, as the count applies to all advertised paths (including those from the add-paths feature), and should follow the phrasing used in the existing sent leaf for prefixes.
| leaf sent-path-count { | |
| type uint32; | |
| description | |
| "The number of add-paths advertised to a neighbor after | |
| the post-policy Adj-RIB-Out. This value reflects the total | |
| number of paths present in the post-policy Adj-RIB-Out for | |
| the neighbor once add-path configuration is applied."; | |
| } | |
| leaf sent-paths { | |
| type uint32; | |
| description | |
| "The number of paths that are advertised to the neighbor after | |
| applying any policies. This count is the number of paths | |
| present in the post-policy Adj-RIB-Out for the neighbor, | |
| including additional paths advertised when add-paths is | |
| enabled."; | |
| } |
There was a problem hiding this comment.
@romeyod, @earies, @jgcumming -please can you let me know if you implement a similar leaf and agree that we should add this into the core OC YANG model (rather than as a Cisco specific augmentation).
There was a problem hiding this comment.
@romeyod is on leave so I'm replying on behalf of him. EOS implements a similar leaf and we agree that it would be good to expose the leaf so that it can be used in the relevant use cases.
|
/gcbrun |
|
No major YANG version changes in commit 18cae6a |
Change Scope
Introduces a new sent-path-count under BGP prefix container.
The sent-path-count represents the number of add-paths advertised to a neighbor after the post-policy Adj-RIB-Out. This value reflects the total number of paths present in the post-policy Adj-RIB-Out for the neighbor once add-path configuration is applied.
This change is backwards-compatible, and the version number has been updated appropriately.
Platform Implementations
After enabling add-path:
Tree View
module: openconfig-bgp | | | | +--rw afi-safi* [afi-safi-name] | | | | +--rw afi-safi-name -> ../config/afi-safi-name | | | | +--rw config | | | | | +--rw afi-safi-name? identityref | | | | | +--rw enabled? boolean | | | | | +--rw send-community-type* oc-bgp-types:community-type | | | | +--ro state | | | | | +--ro afi-safi-name? identityref | | | | | +--ro enabled? boolean | | | | | +--ro send-community-type* oc-bgp-types:community-type | | | | | +--ro active? boolean | | | | | +--ro prefixes | | | | | +--ro received? uint32 | | | | | +--ro received-pre-policy? uint32 | | | | | +--ro sent? uint32 + | | | | | +--ro sent-path-count? uint32 | | | | | +--ro installed? uint32 | | | | +--rw graceful-restart | | | | | +--rw config | | | | | | +--rw enabled? boolean | | | | | +--ro state | | | | | +--ro enabled? boolean | | | | | +--ro received? boolean | | | | | +--ro advertised? boolean | | | | +--rw add-paths | | | | | +--rw config | | | | | | +--rw receive? boolean | | | | | | +--rw send? boolean | | | | | | +--rw send-max? uint8 | | | | | | +--rw eligible-prefix-policy? -> /oc-rpol:routing-policy/policy-definitions/policy-definition/nameJustification
This enhancement is driven by a requirement from an operator, where an additional metric is needed for better observability. In Add-Path scenarios, there is a need to track the total number of paths advertised (across all prefixes) to a specific neighbor.
Currently, there is an existing leaf “sent” under the prefixes container, which provides the number of prefixes advertised to a neighbor after policy application. Similarly, the proposed “sent-path-count” will provide visibility into the number of paths advertised after policy application.