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;}
25 "This module defines the group-based policy ofoverlay renderer model.";
27 revision "2014-05-28" {
35 container of-overlay-config {
37 "Configuration for the OpenFlow overlay renderer";
41 leaf encapsulation-format {
42 description "The encapsulation format to use for tunnels";
45 description "Use VXLAN encapsulation";
52 "Selects how and whether we learn endpoints";
56 "An external orchestration system will provide
57 information about all endpoints, and no
58 direct learning will occur.";
66 grouping initial-values {
68 "Initial value of table offset is set in config subsystem";
69 leaf gbp-ofoverlay-table-offset {
71 "Used to offset pipeline to start at offset+1. Table0 is required.
72 This is to allow the enduser to configure where the GBP pipeline starts.";
77 grouping endpoint-location {
79 "The location for this endpoint in the overlay network";
85 "The endpoint is located on a port that is part of
86 the overlay network. You must include the node
87 ID and port number for this endpoint.";
90 description "This endpoint is not inside the overlay.";
96 "The OpenFlow switch for the endpoint. Must be included
97 for all internal endpoints. The format is
98 openflow:[dpid] where the dpid is the value of the
99 switch DPID cast to a long.";
102 leaf node-connector-id {
104 "The node connector for the endpoint's OpenFlow port. The
105 format is openflow:[dpid]:[port] where the dpid is
106 the value of the switch DPID cast to a long, and port
107 is the openflow port number of the interface where
108 the endpoint is connected.";
109 type inv:node-connector-id;
112 type gbp-common:name;
117 type gbp-common:unique-id;
119 "Unique identifier for interface";
123 grouping napt-translations-fields {
124 container napt-translations {
125 description "List of NAPT translations";
126 list napt-translation {
133 grouping napt-fields {
134 description "Support for IP NAPT";
136 description "Ip address the L3Endpoint translates to.";
137 type inet:ip-address;
140 description "Port that L3Endpoint translates to.";
141 type inet:port-number;
145 augment "/endpoint:endpoints/endpoint:endpoint" {
146 ext:augment-identifier "of-overlay-context";
147 uses endpoint-location;
150 augment "/endpoint:endpoints/endpoint:endpoint-l3" {
151 ext:augment-identifier "of-overlay-l3-context";
152 uses endpoint-location;
155 augment "/endpoint:register-endpoint/endpoint:input" {
156 ext:augment-identifier "of-overlay-context-input";
157 uses endpoint-location;
160 augment "/endpoint:endpoints/endpoint:endpoint-l3" {
161 ext:augment-identifier "of-overlay-l3-nat";
162 uses napt-translations-fields;
165 augment "/endpoint:register-endpoint/endpoint:input" {
166 ext:augment-identifier "of-overlay-l3-nat-input";
167 uses napt-translations-fields;
170 augment "/inv:nodes/inv:node" {
171 ext:augment-identifier "of-overlay-node-config";
174 uses ovsdb-overlay:tunnel-type-attributes;
175 uses ovsdb-overlay:ip-port-locator;
176 leaf node-connector-id {
178 "The node connector where is the tunnel located. The
179 format is openflow:[dpid]:[port] where the dpid is
180 the value of the switch DPID cast to a long, and port
181 is the openflow port number of the interface where
182 the endpoint is connected.";
183 type inv:node-connector-id;
186 container ovsdb-config {
189 "The IP address used to connect to OVSDB on this switch";
190 type inet:ip-address;
194 "The port number used to connect to OVSDB on this switch";
195 type inet:port-number;
199 list external-interfaces {
201 "The node connectors for the external interfaces to the underlay.
202 If interface name is required, can be looked up from inventory using
203 this field as a key to FCNC (FlowCapableNodeConnector)";
204 key "node-connector-id";
205 leaf node-connector-id {
206 type inv:node-connector-id;