BUG-5766: BGP Link Bandwidth Extended Community
[bgpcep.git] / bgp / concepts / src / main / yang / bgp-types.yang
index 0b1f2a4dcdbb87f4b9620aeb81c10abf36ae5039..97c0291d0cb102479186af81c0913c3e0b8c957d 100644 (file)
@@ -4,6 +4,7 @@ module bgp-types {
     prefix "bgp-t";
 
     import ietf-inet-types { prefix inet; revision-date 2010-09-24; }
+    import network-concepts { prefix netc; revision-date 2013-11-25; }
 
     organization "Cisco Systems, Inc.";
     contact "Dana Kutenicsova <dkutenic@cisco.com>";
@@ -150,6 +151,19 @@ module bgp-types {
         }
     }
 
+    grouping link-bandwidth-extended-community {
+        reference "https://tools.ietf.org/html/draft-ietf-idr-link-bandwidth-06#section-2";
+        description
+            "The Link Bandwidth extended community is optional non-transitive";
+
+        leaf bandwidth {
+            description "Bandwidth of the link";
+            mandatory true;
+            type netc:bandwidth;
+            units "bytes per second";
+        }
+    }
+
     grouping extended-community {
         leaf comm-type {
             status deprecated;
@@ -244,6 +258,11 @@ module bgp-types {
                     uses route-ipv4-extended-community;
                 }
             }
+            case link-bandwidth-case {
+                container link-bandwidth-extended-community {
+                    uses link-bandwidth-extended-community;
+                }
+            }
         }
     }