module ietf-flexi-grid-ted { yang-version 1.1; namespace "urn:ietf:params:xml:ns:yang:ietf-flexi-grid-ted"; prefix "fg-ted"; import ietf-network { prefix "nd"; } import ietf-network-state { prefix "nd-s"; } import ietf-network-topology { prefix "lnk"; } import ietf-network-topology-state { prefix "lnk-s"; } import ietf-te-topology { prefix "tet"; } import ietf-te-topology-state { prefix "tet-s"; } import ietf-inet-types { prefix "inet"; } organization "IETF CCAMP Working Group"; contact "Editor: Jorge Lopez de Vergara "; description "This module contains a collection of YANG definitions for a Flexi-Grid Traffic Engineering Database (TED). Copyright (c) 2017 IETF Trust and the persons identified as authors of the code. All rights reserved. Redistribution and use in source and binary forms, with or without modification, is permitted pursuant to, and subject to the license terms contained in, the Simplified BSD License set forth in Section 4.c of the IETF Trust's Legal Provisions Relating to IETF Documents (http://trustee.ietf.org/license-info)."; revision 2017-07-03 { description "version 5."; reference "RFC XXX: A Yang Data Model for Flexi-Grid Optical Networks "; } /* Typedefs */ typedef operational-mode { type string; description "Vendor-specific mode that guarantees interoperability. It must be an string with the following format: B-DScW-ytz(v) where all these attributes are conformant to the ITU-T recomendation"; reference "ITU-T G.698.2 (11/2009) Section 5.3"; } typedef interface-type { type enumeration { enum numbered-interface { description "The interface is numbered"; } enum unnumbered-interface { description "The interface is unnumbered"; } } description "Enumeration that defines if an interface is numbered or unnumbered"; } /* Typedef related to references */ typedef flexi-grid-link-ref { type leafref { path "/nd:networks/nd:network/lnk:link/lnk:link-id"; } description "This type is used by data models that need to reference a flexi-grid optical link."; } typedef flexi-grid-node-port-ref { type leafref { path "/nd:networks/nd:network/nd:node/tet:te/" +"tet:te-node-attributes/fg-ted:interfaces/" +"fg-ted:port-number"; } description "This type is used by data models that need to reference a flexi-grid port."; } typedef flexi-grid-transponder-ref { type leafref { path "/nd:networks/nd:network/nd:node/tet:te/"+ "tet:tunnel-termination-point/tet:tunnel-tp-id"; } description "This type is used by data models that need to reference a trasponder."; } /* Groupings of attributes */ grouping flexi-grid-network-type { container flexi-grid-network { presence "indicates a flexi-grid optical network"; description "flexi-grid optical network"; } description "If present, it indicates a flexi-grid optical TED network"; } grouping flexi-grid-node-attributes { description "Set of attributes of an optical node."; list interfaces { key "name"; unique "port-number"; // TODO Puerto y TP ID description "List of interfaces contained in the node"; leaf name { type string; description "Interface name"; } leaf port-number { type uint32; description "Number of the port used by the interface"; } leaf input-port { type boolean; description "Determines if the port is an input port"; } leaf output-port { type boolean; description "Determines if the port is an output port"; } leaf description { type string; description "Description of the interface"; } leaf type { type interface-type; description "Determines the type of the interface"; } container numbered-interface { when "../fg-ted:type = 'numbered-interface'" { description "If the interface is a numbered interface"; } description "Container that defines an numbered interface with an ip-address"; leaf n-i-ip-address{ type inet:ip-address; description "IP address of the numbered interface"; } } container unnumbered-interface { when "../fg-ted:type = 'unnumbered-interface'" { description "If the interface is an unnumbered interface"; } description "Container that defines an unnumbered interface with an ip-address and a label"; leaf u-i-ip-address{ type inet:ip-address; description "IP address of the interface"; } leaf label { type uint32; description "Number as label for the interface"; } } } } grouping flexi-grid-link-attributes { description "Set of attributes of an optical link"; leaf-list available-label-flexi-grid { type bits { bit is-available{ description "Set to 1 when it is available"; } } description "Array of bits that determines whether a spectral slot is available or not."; } leaf N-max { type int32; description "Maximum number of channels available."; } leaf base-frequency { type decimal64 { fraction-digits 5; } units THz; default 193.1; description "Default central frequency"; reference "rfc7698"; } leaf nominal-central-frequency-granularity { type decimal64 { fraction-digits 5; } units GHz; default 6.25; description "It is the spacing between allowed nominal central frequencies and it is set to 6.25 GHz"; reference "rfc7698"; } leaf slot-width-granularity { type decimal64 { fraction-digits 5; } units GHz; default 12.5; description "Minimum space between slot widths"; reference "rfc7698"; } } grouping flexi-grid-transponder-attributes { description "Configuration of an optical transponder"; //TODO Validate attributes leaf-list available-operational-mode { type operational-mode; description "List of all vendor-specific supported mode identifiers"; } leaf operational-mode { type operational-mode; description "Vendor-specific mode identifier"; } } grouping flexi-grid-connectivity-matrix-attributes { description "Connectivity matrix between the input and output ports"; list connections { key "input-port-id"; leaf input-port-id { type flexi-grid-node-port-ref; description "Identifier of the input port"; } leaf output-port-id { type flexi-grid-node-port-ref; description "Identifier of the output port"; } description "List of connections between input and output ports"; } } /* Augments */ augment "/nd:networks/nd:network/nd:network-types" { uses flexi-grid-network-type; description "Augment network-types including flexi-grid topology"; } augment "/nd-s:networks/nd-s:network/nd-s:network-types" { uses flexi-grid-network-type; description "Augment network-types including flexi-grid topology"; } augment "/nd:networks/nd:network/lnk:link/tet:te" + "/tet:te-link-attributes" { when "/nd:networks/nd:network/nd:network-types/ fg-ted:flexi-grid-network" { description "Augment only for Flexigrid network."; } description "Augment link configuration"; uses flexi-grid-link-attributes; } augment "/nd-s:networks/nd-s:network/lnk-s:link/tet-s:te" + "/tet-s:te-link-attributes" { when "/nd-s:networks/nd-s:network/nd-s:network-types/ fg-ted:flexi-grid-network" { description "Augment only for Flexigrid network."; } description "Augment link state"; uses flexi-grid-link-attributes; } augment "/nd:networks/nd:network/nd:node/tet:te" + "/tet:te-node-attributes" { when "/nd:networks/nd:network/nd:network-types/ fg-ted:flexi-grid-network" { description "Augment only for Flexigrid network."; } uses flexi-grid-node-attributes; description "Augment node config with flexi-grid attributes"; } augment "/nd-s:networks/nd-s:network/nd-s:node/tet-s:te" + "/tet-s:te-node-attributes" { when "/nd-s:networks/nd-s:network/nd-s:network-types/ fg-ted:flexi-grid-network" { description "Augment only for Flexigrid network."; } uses flexi-grid-node-attributes; description "Augment node state with flexi-grid attributes"; } augment "/nd:networks/nd:network/nd:node/tet:te"+ "/tet:te-node-attributes/tet:connectivity-matrices/"+ "tet:connectivity-matrix" { when "/nd:networks/nd:network/nd:network-types/ fg-ted:flexi-grid-network" { description "Augment only for Flexigrid network."; } uses flexi-grid-connectivity-matrix-attributes; description "Augment node connectivity-matrix for node config"; } augment "/nd-s:networks/nd-s:network/nd-s:node/tet-s:te"+ "/tet-s:te-node-attributes/tet-s:connectivity-matrices/"+ "tet-s:connectivity-matrix" { when "/nd-s:networks/nd-s:network/nd-s:network-types/ fg-ted:flexi-grid-network"{ description "Augment only for Flexigrid network."; } uses flexi-grid-connectivity-matrix-attributes; description "Augment node connectivity-matrix for node config"; } augment "/nd:networks/nd:network/nd:node/tet:te"+ "/tet:tunnel-termination-point" { when "/nd:networks/nd:network/nd:network-types/ fg-ted:flexi-grid-network"{ description "Augment only for Flexigrid network."; } uses flexi-grid-transponder-attributes; description "Augment node state with transponder attributes"; } augment "/nd-s:networks/nd-s:network/nd-s:node/tet-s:te"+ "/tet-s:tunnel-termination-point" { when "/nd-s:networks/nd-s:network/nd-s:network-types/ fg-ted:flexi-grid-network"{ description "Augment only for Flexigrid network."; } uses flexi-grid-transponder-attributes; description "Augment node state with transponder attributes"; } }