blob: 182c0dc32f4f0405d678ffcb4976e0ebd879608a [file] [log] [blame]
Thomas Vachuska6655bee2017-08-24 16:12:59 -07001submodule openconfig-mpls-static {
2
3 yang-version "1";
4
5 belongs-to "openconfig-mpls" {
6 prefix "mpls";
7 }
8
9 // import some basic types
10 import openconfig-mpls-types {prefix oc-mplst; }
11 import openconfig-inet-types { prefix inet; }
12 import openconfig-extensions { prefix oc-ext; }
13
14
15 // meta
16 organization "OpenConfig working group";
17
18 contact
19 "OpenConfig working group
20 netopenconfig@googlegroups.com";
21
22 description
23 "Defines static LSP configuration";
24
25 oc-ext:openconfig-version "2.4.0";
26
27 revision "2017-06-21" {
28 description
29 "Add TC bits typedef.";
30 reference "2.4.0";
31 }
32
33 revision "2017-03-22" {
34 description
35 "Add RSVP calculated-absolute-subscription-bw";
36 reference "2.3.0";
37 }
38
39 revision "2017-01-26" {
40 description
41 "Add RSVP Tspec, clarify units for RSVP, remove unused LDP";
42 reference "2.2.0";
43 }
44
45 revision "2016-12-15" {
46 description
47 "Add additional MPLS parameters";
48 reference "2.1.0";
49 }
50
51 revision "2016-09-01" {
52 description
53 "Revisions based on implementation feedback";
54 reference "2.0.0";
55 }
56
57 revision "2016-08-08" {
58 description
59 "Public release of MPLS models";
60 reference "1.0.1";
61 }
62
63 // grouping statements
64
65 grouping static-lsp-common-config {
66 description
67 "common definitions for static LSPs";
68
69 leaf next-hop {
70 type inet:ip-address;
71 description
72 "next hop IP address for the LSP";
73 }
74
75 leaf incoming-label {
76 type oc-mplst:mpls-label;
77 description
78 "label value on the incoming packet";
79 }
80
81 leaf push-label {
82 type oc-mplst:mpls-label;
83 description
84 "label value to push at the current hop for the
85 LSP";
86 }
87 }
88
89 grouping static-lsp-ingress-config {
90 description
91 "Configuration data for ingress LSPs";
92
93 uses static-lsp-common-config;
94 }
95
96 grouping static-lsp-ingress-state {
97 description
98 "Operational state data for ingress LSPs";
99 }
100
101 grouping static-lsp-ingress-top {
102 description
103 "Top-level grouping for ingress LSP data";
104
105 container ingress {
106 description
107 "Static LSPs for which the router is an
108 ingress node";
109
110 container config {
111 description
112 "Configuration data for ingress LSPs";
113
114 uses static-lsp-ingress-config;
115 }
116
117 container state {
118
119 config false;
120
121 description
122 "Operational state data for ingress LSPs";
123
124 uses static-lsp-ingress-config;
125 uses static-lsp-ingress-state;
126 }
127 }
128 }
129
130 grouping static-lsp-transit-config {
131 description
132 "Configuration data for transit LSPs";
133
134 uses static-lsp-common-config;
135 }
136
137 grouping static-lsp-transit-state {
138 description
139 "Operational state data for transit LSPs";
140 }
141
142 grouping static-lsp-transit-top {
143 description
144 "Top-level grouping for transit LSP data";
145
146 container transit {
147 description
148 "Static LSPs for which the router is an
149 transit node";
150
151 container config {
152 description
153 "Configuration data for transit LSPs";
154
155 uses static-lsp-transit-config;
156 }
157
158 container state {
159
160 config false;
161
162 description
163 "Operational state data for transit LSPs";
164
165 uses static-lsp-transit-config;
166 uses static-lsp-transit-state;
167 }
168 }
169 }
170
171 grouping static-lsp-egress-config {
172 description
173 "Configuration data for egress LSPs";
174
175 uses static-lsp-common-config;
176 }
177
178 grouping static-lsp-egress-state {
179 description
180 "Operational state data for egress LSPs";
181 }
182
183 grouping static-lsp-egress-top {
184 description
185 "Top-level grouping for egress LSP data";
186
187 container egress {
188 description
189 "Static LSPs for which the router is an
190 egress node";
191
192 container config {
193 description
194 "Configuration data for egress LSPs";
195
196 uses static-lsp-egress-config;
197 }
198
199 container state {
200
201 config false;
202
203 description
204 "Operational state data for egress LSPs";
205
206 uses static-lsp-egress-config;
207 uses static-lsp-egress-state;
208 }
209 }
210 }
211
212 grouping static-lsp-config {
213 description
214 "Configuration data for static LSPs";
215
216 leaf name {
217 type string;
218 description
219 "name to identify the LSP";
220 }
221 }
222
223 grouping static-lsp-state {
224 description
225 "Operational state data for static LSPs";
226
227 }
228
229 grouping static-lsp-top {
230 description
231 "grouping for top level list of static LSPs";
232
233
234 list static-lsp {
235 key "name";
236 description
237 "list of defined static LSPs";
238
239 leaf name {
240 type leafref {
241 path "../config/name";
242 }
243 description
244 "Reference the name list key";
245 }
246
247 container config {
248 description
249 "Configuration data for the static lsp";
250
251 uses static-lsp-config;
252 }
253
254 container state {
255 config false;
256
257 description
258 "Operational state data for the static lsp";
259
260 uses static-lsp-config;
261 uses static-lsp-state;
262
263 }
264
265 // TODO: separation into ingress, transit, egress may help
266 // to figure out what exactly is configured, but need to
267 // consider whether implementations can support the
268 // separation
269 uses static-lsp-ingress-top;
270 uses static-lsp-transit-top;
271 uses static-lsp-egress-top;
272 }
273 }
274
275 // data definition statements
276
277 // augment statements
278
279
280}