1 module neutron-gbp-mapper {
4 namespace "urn:opendaylight:groupbasedpolicy:neutron-gbp-mapper";
5 prefix "neutron-gbp-mapper";
7 import gbp-common { prefix gbp-common; }
8 import endpoint { prefix gbp-endpoint; }
9 import ietf-yang-types { prefix yang; revision-date 2013-07-15; }
10 import ietf-inet-types { prefix inet; revision-date 2010-09-24; }
11 import base-endpoint { prefix base-ep; revision-date 2016-04-27; }
12 import forwarding { prefix fwd; revision-date 2016-04-27; }
13 import l2-l3-forwarding { prefix l2-l3; revision-date 2016-04-27; }
18 "This module defines the mapping model between Neutron entities and GBP entities.";
20 revision "2015-05-13" {
25 grouping neutron-port-key {
27 description "A unique ID for the neutron port";
28 type gbp-common:unique-id;
33 description "Mapping of neutron entities by groupbasedpolicy entities and vice versa.";
35 container neutron-by-gbp-mappings {
36 description "Neutron entities by groupbasedpolicy entities";
37 container ports-by-endpoints {
38 description "Neutron ports by groupbasedpolicy endpoint";
40 list port-by-endpoint {
41 description "Neutron port key by groupbasedpolicy endpoint key";
42 key "l2-context mac-address";
43 uses gbp-endpoint:l2-key;
44 uses neutron-port-key;
47 container ports-by-base-endpoints {
48 description "Neutron ports by groupbasedpolicy base-endpoint";
49 list port-by-base-endpoint {
50 description "Neutron port key by groupbasedpolicy base-endpoint key";
51 key "context-type context-id address-type address";
52 uses base-ep:address-endpoint-key;
53 uses neutron-port-key;
57 container external-gateways-as-endpoints {
58 description "Endpoints that represent Neutron External Gateways for External Subnets.
59 Please note these ARE NOT Neutron router ports, they are outside of Neutron.";
60 list external-gateway-as-endpoint {
61 description "Endpoints that represent Neutron External Gateways for External Subnets.
62 Please note these ARE NOT Neutron router ports, they are outside of Neutron.";
64 key "context-id context-type address address-type";
66 uses base-ep:address-endpoint-key;
70 container external-gateways-as-l3-endpoints {
71 status deprecated; // use external-gateways-as-endpoints
72 description "L3Endpoints that represent Neutron External Gateways for External Subnets.
73 Please note these ARE NOT Neutron router ports, they are outside of Neutron.";
74 list external-gateway-as-l3-endpoint {
75 description "L3Endpoints that represent Neutron External Gateways for External Subnets.
76 Please note these ARE NOT Neutron router ports, they are outside of Neutron.";
77 key "l3-context ip-address";
78 uses gbp-endpoint:l3-key;
82 container provider-physical-networks-as-l2-flood-domains {
84 list provider-physical-network-as-l2-flood-domain {
85 key "tenant-id l2-flood-domain-id";
87 description "Tenant of L2 Flood Domain";
88 type gbp-common:tenant-id;
90 leaf l2-flood-domain-id {
91 description "The L2 Flood Domain ID";
92 type gbp-common:l2-flood-domain-id;
94 leaf segmentation-id {
96 description "An isolated segment on the physical network. The network-type
97 attribute defines the segmentation model. For example, if network-type
98 is vlan, this ID is a vlan identifier.";
104 container provider-networks-as-l2-flood-domains {
105 list provider-physical-network-as-l2-flood-domain {
106 key "tenant-id l2-flood-domain-id";
108 description "Tenant of L2 Flood Domain";
109 type gbp-common:tenant-id;
111 leaf l2-flood-domain-id {
112 type gbp-common:context-id;
114 leaf segmentation-id {
116 description "An isolated segment on the physical network. The network-type
117 attribute defines the segmentation model. For example, if network-type
118 is vlan, this ID is a vlan identifier.";
125 container gbp-by-neutron-mappings {
126 description "Groupbasedpolicy entities by neutron entities";
127 container endpoints-by-ports {
128 description "Groupbasedpolicy endpoints by neutron ports";
130 list endpoint-by-port {
131 description "Groupbasedpolicy endpoint key by neutron port key";
133 uses neutron-port-key;
134 uses gbp-endpoint:l2-key;
137 container base-endpoints-by-ports {
138 description "Groupbasedpolicy base-endpoints by neutron ports";
139 list base-endpoint-by-port {
140 description "Groupbasedpolicy base-endpoint key by neutron port key";
142 uses neutron-port-key;
143 uses base-ep:address-endpoint-key;
149 rpc change-action-of-security-group-rules {
151 list security-group-rule {
155 description "UUID to index this neutron security group rule.";
159 choice action-choice {
160 case sfc-action-case {
161 leaf sfc-chain-name {
165 case allow-action-case {