2 * Copyright (c) 2014 Cisco Systems, Inc. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
12 namespace "urn:opendaylight:groupbasedpolicy:ofoverlay";
15 import ietf-inet-types { prefix "inet"; revision-date 2010-09-24; }
17 import yang-ext {prefix ext; revision-date "2013-07-09";}
18 import opendaylight-inventory {prefix inv; revision-date "2013-08-19";}
19 import overlay {prefix ovsdb-overlay; revision-date 2015-01-05;}
21 import gbp-common {prefix gbp-common;}
22 import endpoint {prefix endpoint;}
23 import policy {prefix policy;}
26 "This module defines the group-based policy ofoverlay renderer model.";
28 revision "2014-05-28" {
36 container of-overlay-config {
38 "Configuration for the OpenFlow overlay renderer";
42 leaf encapsulation-format {
43 description "The encapsulation format to use for tunnels";
46 description "Use VXLAN encapsulation";
53 "Selects how and whether we learn endpoints";
57 "An external orchestration system will provide
58 information about all endpoints, and no
59 direct learning will occur.";
68 grouping initial-values {
70 "Initial value of table offset is set in config subsystem";
71 leaf gbp-ofoverlay-table-offset {
73 "Used to offset pipeline to start at offset+1. Table0 is required.
74 This is to allow the enduser to configure where the GBP pipeline starts.";
79 grouping sflow-values {
81 "Values for sFlow-RT collector setup";
82 container sflow-client-settings {
83 leaf gbp-ofoverlay-sflow-retrieve-interval {
85 "Interval (seconds) for periodical flowcache data retrieve.";
89 leaf gbp-ofoverlay-sflow-collector-uri {
91 "URI of sFlow-RT collector, including schema, IP/domain, port. No trailing slash.";
98 grouping endpoint-location {
100 "The location for this endpoint in the overlay network";
103 "The OpenFlow switch for the endpoint. Must be included
104 for all internal endpoints. The format is
105 openflow:[dpid] where the dpid is the value of the
106 switch DPID cast to a long.";
109 leaf node-connector-id {
111 "The node connector for the endpoint's OpenFlow port. The
112 format is openflow:[dpid]:[port] where the dpid is
113 the value of the switch DPID cast to a long, and port
114 is the openflow port number of the interface where
115 the endpoint is connected.";
116 type inv:node-connector-id;
119 type gbp-common:name;
124 type gbp-common:unique-id;
126 "Unique identifier for interface";
130 augment "/endpoint:endpoints/endpoint:endpoint" {
131 ext:augment-identifier "of-overlay-context";
132 uses endpoint-location;
135 augment "/endpoint:endpoints/endpoint:endpoint-l3" {
136 ext:augment-identifier "of-overlay-l3-context";
137 uses endpoint-location;
140 augment "/endpoint:register-endpoint/endpoint:input" {
141 ext:augment-identifier "of-overlay-context-input";
142 uses endpoint-location;
145 augment "/policy:tenants/policy:tenant/policy:forwarding-context/policy:l2-flood-domain" {
146 ext:augment-identifier "segmentation";
147 leaf segmentation-id {
148 description "Logical segmentation of an l2-flood-domain, e.g. by using VLANs.";
156 * TODO: should add "portname" to this instead of using heuristic name.
157 * Then SwitchManager could pull from here potentially. The only things that should
158 * populate this are REST or OVSDB-Neutron ... but now we could listen on OVSDB for when
159 * an SFF creates this for us and use the same tunnel...
161 augment "/inv:nodes/inv:node" {
162 ext:augment-identifier "of-overlay-node-config";
165 uses ovsdb-overlay:tunnel-type-attributes;
166 uses ovsdb-overlay:ip-port-locator;
167 leaf node-connector-id {
169 "The node connector where is the tunnel located. The
170 format is openflow:[dpid]:[port] where the dpid is
171 the value of the switch DPID cast to a long, and port
172 is the openflow port number of the interface where
173 the endpoint is connected.";
174 type inv:node-connector-id;
177 container ovsdb-config {
180 "The IP address used to connect to OVSDB on this switch";
181 type inet:ip-address;
185 "The port number used to connect to OVSDB on this switch";
186 type inet:port-number;
190 list external-interfaces {
192 "The node connectors for the external interfaces to the underlay.
193 If interface name is required, can be looked up from inventory using
194 this field as a key to FCNC (FlowCapableNodeConnector)";
195 key "node-connector-id";
196 leaf node-connector-id {
197 type inv:node-connector-id;