HONEYCOMB-58 - Routing Api
[honeycomb.git] / routing / routing-api / src / main / yang / ietf-routing.yang
1 module ietf-routing{
2
3   namespace "urn:ietf:params:xml:ns:yang:ietf-routing";
4
5   prefix "rt";
6
7   import ietf-yang-types {
8     prefix "yang";
9   }
10
11   import ietf-interfaces {
12     prefix "if";
13   }
14
15   organization
16     "IETF NETMOD (NETCONF Data Modeling Language) Working Group";
17
18   contact
19     "WG Web:   <http://tools.ietf.org/wg/netmod/>
20      WG List:  <mailto:netmod@ietf.org>
21
22      WG Chair: Thomas Nadeau
23                <mailto:tnadeau@lucidvision.com>
24
25      WG Chair: Juergen Schoenwaelder
26                <mailto:j.schoenwaelder@jacobs-university.de>
27
28      Editor:   Ladislav Lhotka
29                <mailto:lhotka@nic.cz>";
30
31   description
32     "This YANG module defines essential components for the management
33      of a routing subsystem.
34
35      Copyright (c) 2014 IETF Trust and the persons identified as
36      authors of the code. All rights reserved.
37
38      Redistribution and use in source and binary forms, with or
39      without modification, is permitted pursuant to, and subject to
40      the license terms contained in, the Simplified BSD License set
41      forth in Section 4.c of the IETF Trust's Legal Provisions
42      Relating to IETF Documents
43      (http://trustee.ietf.org/license-info).
44
45      This version of this YANG module is part of RFC XXXX; see the
46      RFC itself for full legal notices.";
47
48   revision 2014-05-24 {
49     description
50       "Initial revision.";
51     reference
52       "RFC XXXX: A YANG Data Model for Routing Management";
53   }
54
55   /* Features */
56
57   feature multiple-ribs {
58     description
59       "This feature indicates that the device supports multiple RIBS
60        per address family, and the framework for passing routes
61        between RIBs.
62
63        Devices that do not support this feature MUST provide exactly
64        one system-controlled RIB per supported address family. These
65        RIBs then appear as entries of the list
66        /routing-state/ribs/rib.";
67   }
68
69   feature multipath-routes {
70     description
71       "This feature indicates that the device supports multipath
72        routes that have a list of next-hops.";
73   }
74
75   /* Identities */
76
77   identity address-family {
78     description
79       "Base identity from which identities describing address
80        families are derived.";
81   }
82
83   identity ipv4 {
84     base address-family;
85     description
86       "This identity represents IPv4 address family.";
87   }
88
89   identity ipv6 {
90     base address-family;
91     description
92       "This identity represents IPv6 address family.";
93   }
94
95   identity routing-instance-type {
96     description
97       "Base identity from which identities describing routing
98        instance types are derived.
99
100        It is primarily intended for discriminating among different
101        types of logical routers or router virtualization.";
102   }
103
104   identity standard-routing-instance {
105     base routing-instance-type;
106     description
107       "This identity represents a default routing instance.";
108   }
109
110   identity routing-protocol {
111     description
112       "Base identity from which routing protocol identities are
113        derived.";
114   }
115
116   identity direct {
117     base routing-protocol;
118     description
119       "Routing pseudo-protocol which provides routes to directly
120        connected networks.";
121   }
122
123   identity static {
124     base routing-protocol;
125     description
126       "Static routing pseudo-protocol.";
127   }
128
129   identity route-filter {
130     description
131       "Base identity from which all route filters are derived.";
132   }
133
134   identity deny-all-route-filter {
135     base route-filter;
136     description
137       "Route filter that blocks all routes.";
138   }
139
140   identity allow-all-route-filter {
141     base route-filter;
142     description
143       "Route filter that permits all routes.";
144   }
145
146   /* Type Definitions */
147
148   typedef routing-instance-ref {
149     type leafref {
150       path "/rt:routing/rt:routing-instance/rt:name";
151     }
152     description
153       "This type is used for leafs that reference a routing instance
154        configuration.";
155   }
156
157   typedef routing-instance-state-ref {
158     type leafref {
159       path "/rt:routing-state/rt:routing-instance/rt:name";
160     }
161     description
162       "This type is used for leafs that reference state data of a
163        routing instance.";
164   }
165
166   typedef rib-ref {
167     type leafref {
168       path "/rt:routing/rt:ribs/rt:rib/rt:name";
169     }
170     description
171       "This type is used for leafs that reference a RIB
172        configuration.";
173   }
174
175   typedef rib-state-ref {
176     type leafref {
177       path "/rt:routing-state/rt:ribs/rt:rib/rt:name";
178     }
179     description
180       "This type is used for leafs that reference a RIB in state
181        data.";
182   }
183
184   typedef route-filter-ref {
185     type leafref {
186       path "/rt:routing/rt:route-filters/rt:route-filter/rt:name";
187     }
188     description
189       "This type is used for leafs that reference a route filter
190        configuration.";
191   }
192
193   typedef route-filter-state-ref {
194     type leafref {
195       path "/rt:routing-state/rt:route-filters/rt:route-filter/"
196          + "rt:name";
197     }
198     description
199       "This type is used for leafs that reference a route filter in
200        state data.";
201   }
202
203   /* Groupings */
204
205   grouping address-family-grouping {
206     description
207       "This grouping provides a leaf identifying an address
208        family.";
209     leaf address-family {
210       type identityref {
211         base address-family;
212       }
213       mandatory "true";
214       description
215         "Address family.";
216     }
217   }
218
219   grouping state-entry-id {
220     description
221       "This grouping defines a unique identifier for entries in
222        several operational state lists.";
223     leaf id {
224       type uint64;
225       description
226         "Unique numerical identifier of a list entry in operational
227          state. It may be used by protocols or tools that inspect
228          and/or manipulate operational state data and prefer
229          fixed-size integers as list entry handles.
230
231          These identifiers are always ephemeral, i.e., they may
232          change after a reboot.";
233     }
234   }
235
236   grouping router-id {
237     description
238       "This grouping provides the definition of router ID.";
239     leaf router-id {
240       type yang:dotted-quad;
241       description
242         "Router ID - 32-bit number in the form of a dotted quad. Some
243          protocols use this parameter for identifying a router to its
244          neighbors.";
245     }
246   }
247
248   grouping outgoing-interface {
249     description
250       "This grouping defines the outgoing interface for use in
251        next-hops.";
252     leaf outgoing-interface {
253       type leafref {
254         path "/rt:routing-state/rt:routing-instance/rt:interfaces/"
255            + "rt:interface/rt:name";
256       }
257       description
258         "Name of the outgoing interface.";
259     }
260   }
261
262   // WARNING - renamed due to yang sources generation problem(having same name for grouping and it's leaf ends up in error against Java Language Specification)
263   grouping special-next-hop-grouping {
264     description
265       "This grouping provides the leaf for specifying special
266        next-hop options.";
267     leaf special-next-hop {
268       type enumeration {
269         enum blackhole {
270           description
271             "Silently discard the packet.";
272         }
273         enum unreachable {
274           description
275             "Discard the packet and notify the sender with an error
276              message indicating that the destination host is
277              unreachable.";
278         }
279         enum prohibit {
280           description
281             "Discard the packet and notify the sender with an error
282              message indicating that the communication is
283              administratively prohibited.";
284         }
285         enum receive {
286           description
287             "The packet will be received by the local network
288              device.";
289         }
290       }
291       description
292         "Special next-hop options.";
293     }
294   }
295
296   grouping next-hop-classifiers {
297     description
298       "This grouping provides two next-hop classifiers.";
299     leaf priority {
300       type enumeration {
301         enum primary {
302           value "1";
303           description
304             "Primary next-hop.";
305         }
306         enum backup {
307           value "2";
308           description
309             "Backup next-hop.";
310         }
311       }
312       description
313         "Simple priority for distinguishing between primary and
314          backup next-hops.
315
316          Backup next-hops are used if and only if no primary
317          next-hops are reachable.";
318     }
319     leaf weight {
320       type uint8;
321       must ". = 0 or not(../../next-hop/weight = 0)" {
322         error-message "Illegal combination of zero and non-zero "
323                     + "next-hop weights.";
324         description
325           "Next-hop weights must be either all zero (equal
326            load-balancing) or all non-zero.";
327       }
328       description
329         "This parameter specifies the weight of the next-hop for load
330          balancing. The number specifies the relative fraction of the
331          traffic that will use the corresponding next-hop.
332
333          A value of 0 represents equal load-balancing.
334
335          If both primary and backup next-hops are present, then the
336          weights for each priority level are used separately.";
337     }
338   }
339
340   grouping next-hop-content {
341     description
342       "Generic parameters of next-hops in routes.";
343     choice next-hop-options {
344       mandatory "true";
345       description
346         "Options for expressing the next-hop in routes.";
347       case special-next-hop {
348         uses special-next-hop-grouping;
349       }
350       case simple-next-hop {
351         uses outgoing-interface;
352       }
353       case next-hop-list {
354         if-feature multipath-routes;
355         container next-hop-list {
356           description
357             "Container for multiple next-hops.";
358           list next-hop {
359             key "id";
360             description
361               "An entry of a next-hop list.";
362             uses state-entry-id;
363             uses outgoing-interface;
364             uses next-hop-classifiers;
365           }
366         }
367       }
368     }
369   }
370
371   grouping route-metadata {
372     description
373       "Route metadata.";
374     leaf source-protocol {
375       type identityref {
376         base routing-protocol;
377       }
378       mandatory "true";
379       description
380         "Type of the routing protocol from which the route
381          originated.";
382     }
383     leaf last-updated {
384       type yang:date-and-time;
385       description
386         "Time stamp of the last modification of the route. If the
387          route was never modified, it is the time when the route was
388          inserted into the RIB.";
389     }
390   }
391
392   /* Operational state data */
393
394   container routing-state {
395     config "false";
396     description
397       "Operational state of the routing subsystem.";
398     list routing-instance {
399       key "name";
400       unique "id";
401       description
402         "Each list entry is a container for operational state data of
403          a routing instance.
404
405          An implementation MAY create one or more system-controlled
406          instances, other user-controlled instances MAY be created by
407          configuration.";
408       leaf name {
409         type string;
410         description
411           "The name of the routing instance.
412
413            For system-controlled instances the name is persistent,
414            i.e., it SHOULD NOT change across reboots.";
415       }
416       uses state-entry-id {
417         refine "id" {
418           mandatory "true";
419         }
420       }
421       leaf type {
422         type identityref {
423           base routing-instance-type;
424         }
425         description
426           "The routing instance type, primarily intended for
427            discriminating among different types of logical routers,
428            route virtualization, master-slave arrangements etc.,
429            while keeping all routing instances in the same flat
430            list.";
431       }
432       uses router-id {
433         description
434           "Global router ID.
435
436            An implementation may choose a value if none is
437            configured.
438
439            Routing protocols that use router ID MAY override this
440            global parameter.";
441       }
442       container default-ribs {
443         description
444           "Default RIBs used by the routing instance.";
445         list default-rib {
446           key "address-family";
447           description
448             "Each list entry specifies the default RIB for one
449              address family.
450
451              The default RIB is operationally connected to all
452              routing protocols for which a connected RIB has not been
453              explicitly configured.
454
455              The 'direct' pseudo-protocol is always connected to the
456              default RIBs.";
457           uses address-family-grouping;
458           leaf rib-name {
459             type rib-state-ref;
460             mandatory "true";
461             description
462               "Name of an existing RIB to be used as the default RIB
463                for the given routing instance and address family.";
464           }
465         }
466       }
467       container interfaces {
468         description
469           "Network layer interfaces belonging to the routing
470            instance.";
471         list interface {
472           key "name";
473           description
474             "List of network layer interfaces assigned to the routing
475              instance.";
476           leaf name {
477             type if:interface-state-ref;
478             description
479               "A reference to the name of a configured network layer
480                interface.";
481           }
482         }
483       }
484       container routing-protocols {
485         description
486           "Container for the list of routing protocol instances.";
487         list routing-protocol {
488           key "name";
489           description
490             "Operational state of a routing protocol instance.
491
492              An implementation MUST provide exactly one
493              system-controlled instance of the type 'direct'. Other
494              instances MAY be created by configuration.";
495           leaf name {
496             type string;
497             description
498               "The name of the routing protocol instance.
499
500                For system-controlled instances this name is
501                persistent, i.e., it SHOULD NOT change across
502                reboots.";
503           }
504           leaf type {
505             type identityref {
506               base routing-protocol;
507             }
508             mandatory "true";
509             description
510               "Type of the routing protocol.";
511           }
512           container connected-ribs {
513             description
514               "Container for connected RIBs.";
515             list connected-rib {
516               key "rib-name";
517               description
518                 "List of RIBs to which the routing protocol instance
519                  is connected (at most one RIB per address
520                  family).";
521               leaf rib-name {
522                 type rib-state-ref;
523                 description
524                   "Name of an existing RIB.";
525               }
526               leaf import-filter {
527                 type route-filter-state-ref;
528                 description
529                   "Reference to a route filter that is used for
530                    filtering routes passed from this routing protocol
531                    instance to the RIB specified by the 'rib-name'
532                    sibling node.
533
534                    If this leaf is not present, the behavior is
535                    protocol-specific, but typically it means that all
536                    routes are accepted.";
537               }
538               leaf export-filter {
539                 type route-filter-state-ref;
540                 description
541                   "Reference to a route filter that is used for
542                    filtering routes passed from the RIB specified by
543                    the 'rib-name' sibling node to this routing
544                    protocol instance.
545
546                    If this leaf is not present, the behavior is
547                    protocol-specific - typically it means that all
548                    routes are accepted.
549
550                    The 'direct' and 'static' pseudo-protocols accept
551                    no routes from any RIB.";
552               }
553             }
554           }
555
556           //NOTE -added to allow operational state for static-routes
557           container static-routes {
558             when "../type='rt:static'" {
559             description
560               "This container is only valid for the 'static'
561                routing protocol.";
562             }
563             description
564             "Configuration of the 'static' pseudo-protocol.
565
566              Address family specific modules augment this node with
567              their lists of routes.";
568           }
569         }
570       }
571     }
572     container ribs {
573       description
574         "Container for RIBs.";
575       list rib {
576         key "name";
577         unique "id";
578         description
579           "Each entry represents a RIB identified by the 'name' key.
580            All routes in a RIB MUST belong to the same address
581            family.
582
583            The server MUST provide a system-controlled default RIB
584            for each address family, and MAY provide other
585            system-controlled RIBs. Additional RIBs MAY be created in
586            the configuration.";
587         leaf name {
588           type string;
589           description
590             "The name of the RIB.";
591         }
592         uses state-entry-id {
593           refine "id" {
594             mandatory "true";
595           }
596         }
597         uses address-family-grouping;
598         container routes {
599           description
600             "Current contents of the RIB.";
601           list route {
602             key "id";
603             description
604               "A RIB route entry. This data node MUST be augmented
605                with information specific for routes of each address
606                family.";
607             uses state-entry-id;
608             uses next-hop-content;
609             uses route-metadata;
610           }
611         }
612         container recipient-ribs {
613           if-feature multiple-ribs;
614           description
615             "Container for recipient RIBs.";
616           list recipient-rib {
617             key "rib-name";
618             description
619               "List of RIBs that receive routes from this RIB.";
620             leaf rib-name {
621               type rib-state-ref;
622               description
623                 "The name of the recipient RIB.";
624             }
625             leaf filter {
626               type route-filter-state-ref;
627               description
628                 "A route filter which is applied to the routes passed
629                  to the recipient RIB.";
630             }
631           }
632         }
633       }
634     }
635     container route-filters {
636       description
637         "Container for route filters.";
638       list route-filter {
639         key "name";
640         description
641           "Route filters are used for filtering and/or manipulating
642            routes that are passed between a routing protocol and a
643            RIB and vice versa, or between two RIBs.
644
645            It is expected that other modules augment this list with
646            contents specific for a particular route filter type.";
647         leaf name {
648           type string;
649           description
650             "The name of the route filter.";
651         }
652         leaf type {
653           type identityref {
654             base route-filter;
655           }
656           mandatory "true";
657           description
658             "Type of the route-filter - an identity derived from the
659              'route-filter' base identity.";
660         }
661       }
662     }
663   }
664
665   /* Configuration Data */
666
667   container routing {
668     description
669       "Configuration parameters for the routing subsystem.";
670     list routing-instance {
671       key "name";
672       description
673         "Configuration of a routing instance.";
674       leaf name {
675         type string;
676         description
677           "The name of the routing instance.
678
679            For system-controlled entries, the value of this leaf must
680            be the same as the name of the corresponding entry in
681            state data.
682
683            For user-controlled entries, an arbitrary name can be
684            used.";
685       }
686       leaf type {
687         type identityref {
688           base routing-instance-type;
689         }
690         default "rt:standard-routing-instance";
691         description
692           "The type of the routing instance.";
693       }
694       leaf enabled {
695         type boolean;
696         default "true";
697         description
698           "Enable/disable the routing instance.
699
700            If this parameter is false, the parent routing instance is
701            disabled and does not appear in operational state data,
702            despite any other configuration that might be present.";
703       }
704       uses router-id {
705         description
706           "Configuration of the global router ID.";
707       }
708       leaf description {
709         type string;
710         description
711           "Textual description of the routing instance.";
712       }
713       container default-ribs {
714         if-feature multiple-ribs;
715         description
716           "Configuration of the default RIBs used by the routing
717            instance.
718
719            The default RIB for an addressed family if by default
720            connected to all routing protocol instances supporting
721            that address family, and always receives direct routes.";
722         list default-rib {
723           must "address-family=/routing/ribs/rib[name=current()/"
724              + "rib-name]/address-family" {
725             error-message "Address family mismatch.";
726             description
727               "The entry's address family MUST match that of the
728                referenced RIB.";
729           }
730           key "address-family";
731           description
732             "Each list entry configures the default RIB for one
733              address family.";
734           uses address-family-grouping;
735           leaf rib-name {
736             type string;
737             mandatory "true";
738             description
739               "Name of an existing RIB to be used as the default RIB
740                for the given routing instance and address family.";
741           }
742         }
743       }
744       container interfaces {
745         description
746           "Configuration of the routing instance's interfaces.";
747         list interface {
748           key "name";
749           description
750             "List of network layer interfaces assigned to the routing
751              instance.";
752           leaf name {
753             type if:interface-ref;
754             description
755               "A reference to the name of a configured network layer
756                interface.";
757           }
758         }
759       }
760       container routing-protocols {
761         description
762           "Configuration of routing protocol instances.";
763         list routing-protocol {
764           key "name";
765           description
766             "Each entry contains configuration of a routing protocol
767              instance.";
768           leaf name {
769             type string;
770             description
771               "An arbitrary name of the routing protocol instance.";
772           }
773           leaf description {
774             type string;
775             description
776               "Textual description of the routing protocol
777                instance.";
778           }
779           leaf enabled {
780             type boolean;
781             default "true";
782             description
783               "Enable/disable the routing protocol instance.
784
785                If this parameter is false, the parent routing
786                protocol instance is disabled and does not appear in
787                operational state data, despite any other
788                configuration that might be present.";
789           }
790           leaf type {
791             type identityref {
792               base routing-protocol;
793             }
794             mandatory "true";
795             description
796               "Type of the routing protocol - an identity derived
797                from the 'routing-protocol' base identity.";
798           }
799           container connected-ribs {
800             description
801               "Configuration of connected RIBs.";
802             list connected-rib {
803               must "not(/routing/ribs/rib[name=current()/"
804                  + "preceding-sibling::connected-rib/"
805                  + "rib-name and address-family=/routing/ribs/"
806                  + "rib[name=current()/rib-name]/address-family])" {
807                 error-message
808                   "Duplicate address family for connected RIBs.";
809                 description
810                   "For each address family, there MUST NOT be more
811                    than one connected RIB.";
812               }
813               key "rib-name";
814               description
815                 "List of RIBs to which the routing protocol instance
816                  is connected (at most one RIB per address family).
817
818                  If no connected RIB is configured for an address
819                  family, the routing protocol is connected to the
820                  default RIB for that address family.";
821               leaf rib-name {
822                 type rib-ref;
823                 must "../../../type != 'rt:direct' or "
824                    + "../../../../../default-ribs/ "
825                    + "default-rib/rib-name=." {
826                   error-message "The 'direct' protocol can be "
827                               + "connected only to a default RIB.";
828                   description
829                     "For the 'direct' pseudo-protocol, the connected
830                      RIB must always be a default RIB.";
831                 }
832                 description
833                   "Name of an existing RIB.";
834               }
835               leaf import-filter {
836                 type route-filter-ref;
837                 description
838                   "Configuration of import filter.";
839               }
840               leaf export-filter {
841                 type route-filter-ref;
842                 description
843                   "Configuration of export filter.";
844               }
845             }
846           }
847           container static-routes {
848             when "../type='rt:static'" {
849               description
850                 "This container is only valid for the 'static'
851                  routing protocol.";
852             }
853             description
854               "Configuration of the 'static' pseudo-protocol.
855
856                Address family specific modules augment this node with
857                their lists of routes.";
858           }
859         }
860       }
861     }
862     container ribs {
863       description
864         "Configured RIBs.";
865       list rib {
866         key "name";
867         description
868           "Each entry represents a configured RIB identified by the
869            'name' key.
870
871            Entries having the same key as a system-controlled entry
872            of the list /routing-state/ribs/rib are used for
873            configuring parameters of that entry. Other entries define
874            additional user-controlled RIBs.";
875         leaf name {
876           type string;
877           description
878             "The name of the RIB.
879
880              For system-controlled entries, the value of this leaf
881              must be the same as the name of the corresponding entry
882              in state data.
883
884              For user-controlled entries, an arbitrary name can be
885              used.";
886         }
887         uses address-family-grouping;
888         leaf description {
889           type string;
890           description
891             "Textual description of the RIB.";
892         }
893         container recipient-ribs {
894           if-feature multiple-ribs;
895           description
896             "Configuration of recipient RIBs.";
897           list recipient-rib {
898             must "rib-name != ../../name" {
899               error-message
900                 "Source and recipient RIBs are identical.";
901               description
902                 "A RIB MUST NOT appear among its recipient RIBs.";
903             }
904             must "/routing/ribs/rib[name=current()/rib-name]/"
905                + "address-family=../../address-family" {
906               error-message "Address family mismatch.";
907               description
908                 "Address family of the recipient RIB MUST match that
909                  of the source RIB.";
910             }
911             key "rib-name";
912             description
913               "Each entry configures a recipient RIB.";
914             leaf rib-name {
915               type rib-ref;
916               description
917                 "The name of the recipient RIB.";
918             }
919             leaf filter {
920               type route-filter-ref;
921               description
922                 "A route filter which is applied to the routes passed
923                  to the recipient RIB.";
924             }
925           }
926         }
927       }
928     }
929     container route-filters {
930       description
931         "Configuration of route filters.";
932       list route-filter {
933         key "name";
934         description
935           "Each entry configures a named route filter.";
936         leaf name {
937           type string;
938           description
939             "The name of the route filter.";
940         }
941         leaf description {
942           type string;
943           description
944             "Textual description of the route filter.";
945         }
946         leaf type {
947           type identityref {
948             base route-filter;
949           }
950           mandatory "true";
951           description
952             "Type of the route filter..";
953         }
954       }
955     }
956   }
957
958   /* RPC methods */
959
960   rpc active-route {
961     description
962       "Return the active route that a routing-instance uses for
963        sending packets to a destination address.";
964     input {
965       leaf routing-instance-name {
966         type routing-instance-state-ref;
967         mandatory "true";
968         description
969           "Name of the routing instance whose forwarding information
970            base is being queried.
971
972            If the routing instance with name equal to the value of
973            this parameter doesn't exist, then this operation SHALL
974            fail with error-tag 'data-missing' and error-app-tag
975            'routing-instance-not-found'.";
976       }
977       container destination-address {
978         description
979           "Network layer destination address.
980
981            Address family specific modules MUST augment this
982            container with a leaf named 'address'.";
983         uses address-family-grouping;
984       }
985     }
986     output {
987       container route {
988         description
989           "The active route for the specified destination.
990
991            If the routing instance has no active route for the
992            destination address, no output is returned - the server
993            SHALL send an <rpc-reply> containing a single element
994            <ok>.
995
996            Address family specific modules MUST augment this list
997            with appropriate route contents.";
998         uses address-family-grouping;
999         uses next-hop-content;
1000         uses route-metadata;
1001       }
1002     }
1003   }
1004
1005   rpc route-count {
1006     description
1007       "Return the current number of routes in a RIB.";
1008     input {
1009       leaf rib-name {
1010         type rib-state-ref;
1011         mandatory "true";
1012         description
1013           "Name of the RIB.
1014
1015            If the RIB with name equal to the value of this parameter
1016            doesn't exist, then this operation SHALL fail with
1017            error-tag 'data-missing' and error-app-tag
1018            'rib-not-found'.";
1019       }
1020     }
1021     output {
1022       leaf number-of-routes {
1023         type uint64;
1024         mandatory "true";
1025         description
1026           "Number of routes in the RIB.";
1027       }
1028     }
1029   }
1030 }