diff options
author | YohanPipereau <ypiperea@cisco.com> | 2019-03-06 14:01:58 +0100 |
---|---|---|
committer | YohanPipereau <ypiperea@cisco.com> | 2019-03-29 14:39:36 +0100 |
commit | a760dfb253161911fc3aa3c8b879c461d53ade6e (patch) | |
tree | 0e79953f4ed5615879a58f49a74df3f9c6739a42 /src/plugins/yang/openconfig/openconfig-local-routing.yang | |
parent | 2b9b6b9b130b75799a40989c0ebe5040fa3e45fb (diff) |
Sweetcomb global cleanup
-Merge IETF and Openconfig to use SCVPP 2
-Move L2 bridge from sc_vpp_interface to sc_vpp_v3po
-Implement tav2 dump
-Make openconfig-interfaces functions static
-Try one more dispatch after failure in VAPI_CALL
-Add error return code for scvpp
-Remove unused length maccros
-Return appropriate error code for interface dump when interface not found
-Improve scvpp test suite
-Change get_interface_id prototype
-Use interface_dump_iface in openconfig_interface.
-No more vapi types in openconfig_interfaces.c
-Move openconfig_local_routing VAPI operations to sc_vpp_ip
-Implement a multiple dump with a stack data structure
-Comment out state_cb code from openconfig_local_routing to use new
functions later.
-Rename YANG model to their fully qualified name : <module>@<revision>
-Remove headers almost empty and put registration declaration in
sc_model.h
-Shorten vapi context global variable name
-Reorganize scvpp unit test suite
-Add instructions to Makefile to install/uninstall YANG models in sysrepo.
-Add this new instructions to README.md.
-Reimplement interface_dump_all
-Use a common message at INFO Log Level to know when sysrepo callbacks
are triggered
-Remove old structure to perform dump of all interfaces
-Reimplement get_interface_name and add scvpp test for it
-Clean sys_util
-Use UNUSED maccro everywhere to have lighter prototypes
-Have ietf-interfaces:interfaces-state work with new dump function
-Add setup and teardown for NAT tests
-Remove unused tapv2 dump
-Remove useless sysrepo module callback
-Remove xpath_find_first_key usage in openconfig-interfaces
-Remove xpath_find_first_key in oc_local_routing and in the rest of
sweetcomb
-Reorganize scvpp include dir and fix scvpp_test new warnings
-Fix scvpp tests for ip routes
-Factorize scvpp nat and test return code of its function
-Correct test_dump_if_all if there is an existing hardware interface
-Implement a per-prefix dump in scvpp
-free changes iterator in ietf-interfaces
-Add new XPATH in oc local-routing
-Introduce helper methods for sysrepo config callbacks
-Factorize config callback
-Refactor the openconfig-local-routing config callback
-Use common foreach_change to iterate over changes in all models
-Create a sample directory gathering example of configurations supposed
to work with sweetcomb
-Fix state callback of oc-local-routing
-Add new sample for get operation on next-hop
-foreach_elt maccro condition forgets to read one element
Change-Id: I8e87fce577a00337977588f057a6e095a20f457c
Signed-off-by: YohanPipereau <ypiperea@cisco.com>
Diffstat (limited to 'src/plugins/yang/openconfig/openconfig-local-routing.yang')
-rw-r--r-- | src/plugins/yang/openconfig/openconfig-local-routing.yang | 408 |
1 files changed, 0 insertions, 408 deletions
diff --git a/src/plugins/yang/openconfig/openconfig-local-routing.yang b/src/plugins/yang/openconfig/openconfig-local-routing.yang deleted file mode 100644 index 5184fe7..0000000 --- a/src/plugins/yang/openconfig/openconfig-local-routing.yang +++ /dev/null @@ -1,408 +0,0 @@ -module openconfig-local-routing { - - yang-version "1"; - - // namespace - namespace "http://openconfig.net/yang/local-routing"; - - prefix "oc-loc-rt"; - - // import some basic types - import openconfig-inet-types { prefix inet; } - import openconfig-policy-types { prefix oc-pt; } - import openconfig-extensions { prefix oc-ext; } - import openconfig-interfaces { prefix oc-if; } - - // meta - organization "OpenConfig working group"; - - contact - "OpenConfig working group - www.openconfig.net"; - - description - "This module describes configuration and operational state data - for routes that are locally generated, i.e., not created by - dynamic routing protocols. These include static routes, locally - created aggregate routes for reducing the number of constituent - routes that must be advertised, summary routes for IGPs, etc. - - This model expresses locally generated routes as generically as - possible, avoiding configuration of protocol-specific attributes - at the time of route creation. This is primarily to avoid - assumptions about how underlying router implementations handle - route attributes in various routing table data structures they - maintain. Hence, the definition of locally generated routes - essentially creates 'bare' routes that do not have any protocol- - specific attributes. - - When protocol-specific attributes must be attached to a route - (e.g., communities on a locally defined route meant to be - advertised via BGP), the attributes should be attached via a - protocol-specific policy after importing the route into the - protocol for distribution (again via routing policy)."; - - oc-ext:openconfig-version "1.0.1"; - - revision "2017-05-15" { - description - "Update to resolve style guide non-compliance."; - reference "1.0.1"; - } - - revision "2016-05-11" { - description - "OpenConfig public release"; - reference "1.0.0"; - } - - - // identity statements - - identity LOCAL_DEFINED_NEXT_HOP { - description - "A base identity type of local defined next-hops"; - } - - identity DROP { - base LOCAL_DEFINED_NEXT_HOP; - description - "Discard traffic for the corresponding destination"; - } - - identity LOCAL_LINK { - base LOCAL_DEFINED_NEXT_HOP; - description - "Treat traffic towards addresses within the specified - next-hop prefix as though they are connected to a local - link. When the LOCAL_LINK next-hop type is specified, - an interface must also be specified such that - the local system can determine which link to trigger - link-layer address discovery against"; - } - - // typedef statements - - typedef local-defined-next-hop { - type identityref { - base LOCAL_DEFINED_NEXT_HOP; - } - description - "Pre-defined next-hop designation for locally generated - routes"; - } - - // grouping statements - - grouping local-generic-settings { - description - "Generic options that can be set on local routes When - they are defined"; - - leaf set-tag { - type oc-pt:tag-type; - description - "Set a generic tag value on the route. This tag can be - used for filtering routes that are distributed to other - routing protocols."; - } - } - - grouping local-static-config { - description - "Configuration data for static routes."; - - leaf prefix { - type inet:ip-prefix; - description - "Destination prefix for the static route, either IPv4 or - IPv6."; - } - - uses local-generic-settings; - } - - grouping local-static-state { - description - "Operational state data for static routes"; - } - - - grouping local-static-nexthop-config { - description - "Configuration parameters related to each next-hop entry - specified for a static route"; - - leaf index { - type string; - description - "An user-specified identifier utilised to uniquely reference - the next-hop entry in the next-hop list. The value of this - index has no semantic meaning other than for referencing - the entry."; - } - - leaf next-hop { - type union { - type inet:ip-address; - type local-defined-next-hop; - } - description - "The next-hop that is to be used for the static route - - this may be specified as an IP address, an interface - or a pre-defined next-hop type - for instance, DROP or - LOCAL_LINK. When this leaf is not set, and the interface-ref - value is specified for the next-hop, then the system should - treat the prefix as though it is directly connected to the - interface."; - } - - leaf metric { - type uint32; - description - "A metric which is utilised to specify the preference of - the next-hop entry when it is injected into the RIB. The - lower the metric, the more preferable the prefix is. When - this value is not specified the metric is inherited from - the default metric utilised for static routes within the - network instance that the static routes are being - instantiated. When multiple next-hops are specified for a - static route, the metric is utilised to determine which of - the next-hops is to be installed in the RIB. When multiple - next-hops have the same metric (be it specified, or simply - the default) then these next-hops should all be installed - in the RIB"; - } - - leaf recurse { - type boolean; - default false; - description - "Determines whether the next-hop should be allowed to - be looked up recursively - i.e., via a RIB entry which has - been installed by a routing protocol, or another static route - - rather than needing to be connected directly to an - interface of the local system within the current network - instance. When the interface reference specified within the - next-hop entry is set (i.e., is not null) then forwarding is - restricted to being via the interface specified - and - recursion is hence disabled."; - } - } - - grouping local-static-nexthop-state { - description - "Operational state parameters relating to a next-hop entry - for a static route"; - } - - - grouping local-static-top { - description - "Top-level grouping for the list of static route definitions"; - - container static-routes { - description - "Enclosing container for the list of static routes"; - - list static { - key "prefix"; - description - "List of locally configured static routes"; - - leaf prefix { - type leafref { - path "../config/prefix"; - } - description - "Reference to the destination prefix list key."; - } - - container config { - description - "Configuration data for static routes"; - - uses local-static-config; - } - - container state { - - config false; - - description - "Operational state data for static routes"; - - uses local-static-config; - uses local-static-state; - } - - container next-hops { - description - "Configuration and state parameters relating to the - next-hops that are to be utilised for the static - route being specified"; - - list next-hop { - key "index"; - - description - "A list of next-hops to be utilised for the static - route being specified."; - - leaf index { - type leafref { - path "../config/index"; - } - description - "A reference to the index of the current next-hop. - The index is intended to be a user-specified value - which can be used to reference the next-hop in - question, without any other semantics being - assigned to it."; - } - - container config { - description - "Configuration parameters relating to the next-hop - entry"; - - uses local-static-nexthop-config; - } - - container state { - config false; - description - "Operational state parameters relating to the - next-hop entry"; - - uses local-static-nexthop-config; - uses local-static-nexthop-state; - } - - uses oc-if:interface-ref; - } - } - } - } - } - - grouping local-aggregate-config { - description - "Configuration data for aggregate routes"; - - leaf prefix { - type inet:ip-prefix; - description - "Aggregate prefix to be advertised"; - } - - leaf discard { - type boolean; - default false; - description - "When true, install the aggregate route with a discard - next-hop -- traffic destined to the aggregate will be - discarded with no ICMP message generated. When false, - traffic destined to an aggregate address when no - constituent routes are present will generate an ICMP - unreachable message."; - } - - uses local-generic-settings; - - } - - grouping local-aggregate-state { - description - "Operational state data for local aggregate advertisement - definitions"; - } - - grouping local-aggregate-top { - description - "Top-level grouping for local aggregates"; - - container local-aggregates { - description - "Enclosing container for locally-defined aggregate - routes"; - - list aggregate { - key "prefix"; - description - "List of aggregates"; - - leaf prefix { - type leafref { - path "../config/prefix"; - } - description - "Reference to the configured prefix for this aggregate"; - } - - container config { - description - "Configuration data for aggregate advertisements"; - - uses local-aggregate-config; - } - - container state { - - config false; - - description - "Operational state data for aggregate - advertisements"; - - uses local-aggregate-config; - uses local-aggregate-state; - } - } - } - } - - grouping local-routes-config { - description - "Configuration data for locally defined routes"; - } - - grouping local-routes-state { - description - "Operational state data for locally defined routes"; - } - - grouping local-routes-top { - description - "Top-level grouping for local routes"; - - container local-routes { - description - "Top-level container for local routes"; - - container config { - description - "Configuration data for locally defined routes"; - - uses local-routes-config; - } - - container state { - - config false; - - description - "Operational state data for locally defined routes"; - - uses local-routes-config; - uses local-routes-state; - } - - uses local-static-top; - uses local-aggregate-top; - } - } - - uses local-routes-top; - -} |