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.";
67 grouping initial-values {
69 "Initial value of table offset is set in config subsystem";
70 leaf gbp-ofoverlay-table-offset {
72 "Used to offset pipeline to start at offset+1. Table0 is required.
73 This is to allow the enduser to configure where the GBP pipeline starts.";
78 grouping endpoint-location {
80 "The location for this endpoint in the overlay network";
83 "The OpenFlow switch for the endpoint. Must be included
84 for all internal endpoints. The format is
85 openflow:[dpid] where the dpid is the value of the
86 switch DPID cast to a long.";
89 leaf node-connector-id {
91 "The node connector for the endpoint's OpenFlow port. The
92 format is openflow:[dpid]:[port] where the dpid is
93 the value of the switch DPID cast to a long, and port
94 is the openflow port number of the interface where
95 the endpoint is connected.";
96 type inv:node-connector-id;
104 type gbp-common:unique-id;
106 "Unique identifier for interface";
110 augment "/endpoint:endpoints/endpoint:endpoint" {
111 ext:augment-identifier "of-overlay-context";
112 uses endpoint-location;
115 augment "/endpoint:endpoints/endpoint:endpoint-l3" {
116 ext:augment-identifier "of-overlay-l3-context";
117 uses endpoint-location;
120 augment "/endpoint:register-endpoint/endpoint:input" {
121 ext:augment-identifier "of-overlay-context-input";
122 uses endpoint-location;
125 augment "/policy:tenants/policy:tenant/policy:forwarding-context/policy:l2-flood-domain" {
126 ext:augment-identifier "segmentation";
127 leaf segmentation-id {
128 description "Logical segmentation of an l2-flood-domain, e.g. by using VLANs.";
136 * TODO: should add "portname" to this instead of using heuristic name.
137 * Then SwitchManager could pull from here potentially. The only things that should
138 * populate this are REST or OVSDB-Neutron ... but now we could listen on OVSDB for when
139 * an SFF creates this for us and use the same tunnel...
141 augment "/inv:nodes/inv:node" {
142 ext:augment-identifier "of-overlay-node-config";
145 uses ovsdb-overlay:tunnel-type-attributes;
146 uses ovsdb-overlay:ip-port-locator;
147 leaf node-connector-id {
149 "The node connector where is the tunnel located. The
150 format is openflow:[dpid]:[port] where the dpid is
151 the value of the switch DPID cast to a long, and port
152 is the openflow port number of the interface where
153 the endpoint is connected.";
154 type inv:node-connector-id;
157 container ovsdb-config {
160 "The IP address used to connect to OVSDB on this switch";
161 type inet:ip-address;
165 "The port number used to connect to OVSDB on this switch";
166 type inet:port-number;
170 list external-interfaces {
172 "The node connectors for the external interfaces to the underlay.
173 If interface name is required, can be looked up from inventory using
174 this field as a key to FCNC (FlowCapableNodeConnector)";
175 key "node-connector-id";
176 leaf node-connector-id {
177 type inv:node-connector-id;