sonugupta-huawei | 99c0a01 | 2017-12-23 00:44:15 +0530 | [diff] [blame] | 1 | module yrt-ietf-otn-tunnel { |
| 2 | |
| 3 | yang-version 1.1; |
| 4 | |
| 5 | namespace "urn:ietf:params:xml:ns:yang:yrt-ietf-otn-tunnel"; |
| 6 | prefix "otn-tunnel"; |
| 7 | |
| 8 | import actn-ietf-te { prefix "te"; } |
| 9 | import yrt-ietf-transport-types { prefix "tran-types"; } |
| 10 | //import yang-ext { prefix ext; revision-date 2013-07-09; } |
| 11 | import actn-ietf-te-types { |
| 12 | prefix te-types; |
| 13 | } |
| 14 | |
| 15 | import yrt-ietf-inet-types { |
| 16 | prefix inet; |
| 17 | } |
| 18 | |
| 19 | organization |
| 20 | "IETF CCAMP Working Group"; |
| 21 | |
| 22 | contact |
| 23 | "WG Web: <http://tools.ietf.org/wg/ccamp/> |
| 24 | WG List: <mailto:ccamp@ietf.org> |
| 25 | |
| 26 | Editor: Anurag Sharma |
| 27 | <mailto:AnSharma@infinera.com> |
| 28 | |
| 29 | Editor: Rajan Rao |
| 30 | <mailto:rrao@infinera.com> |
| 31 | |
| 32 | Editor: Xian Zhang |
| 33 | <mailto:zhang.xian@huawei.com> |
| 34 | |
| 35 | Editor: Kun Xiang |
| 36 | <mailto:xiangkun@huawei.com>"; |
| 37 | |
| 38 | description |
| 39 | "This module defines a model for OTN Tunnel Services."; |
| 40 | |
| 41 | revision "2017-03-11" { |
| 42 | description |
| 43 | "Revision 0.3"; |
| 44 | reference "TBD"; |
| 45 | } |
| 46 | |
| 47 | grouping otn-tunnel-endpoint { |
| 48 | description "Parameters for OTN tunnel."; |
| 49 | |
| 50 | leaf payload-treatment { |
| 51 | type enumeration { |
| 52 | enum switching; |
| 53 | enum transport; |
| 54 | } |
| 55 | default switching; |
| 56 | description |
| 57 | "Treatment of the incoming payload. Payload can |
| 58 | either be switched, or transported as is."; |
| 59 | } |
| 60 | |
| 61 | leaf src-client-signal { |
| 62 | type identityref { |
| 63 | base tran-types:client-signal; |
| 64 | } |
| 65 | description |
| 66 | "Client signal at the source endpoint of |
| 67 | the tunnel."; |
| 68 | } |
| 69 | |
| 70 | leaf src-tpn { |
| 71 | type uint16 { |
| 72 | range "0..4095"; |
| 73 | } |
| 74 | description |
| 75 | "Tributary Port Number. Applicable in case of mux |
| 76 | services."; |
| 77 | reference |
| 78 | "RFC7139: GMPLS Signaling Extensions for Control of |
| 79 | Evolving G.709 Optical Transport Networks."; |
| 80 | } |
| 81 | |
| 82 | leaf src-tsg { |
| 83 | type identityref { |
| 84 | base tran-types:tributary-slot-granularity; |
| 85 | } |
| 86 | description |
| 87 | "Tributary slot granularity. Applicable in case of mux |
| 88 | services."; |
| 89 | reference |
| 90 | "G.709/Y.1331, February 2016: Interfaces for the |
| 91 | Optical Transport Network (OTN)"; |
| 92 | } |
| 93 | |
| 94 | leaf src-tributary-slot-count { |
| 95 | type uint16; |
| 96 | description |
| 97 | "Number of tributary slots used at the source."; |
| 98 | } |
| 99 | |
| 100 | container src-tributary-slots { |
| 101 | description |
| 102 | "A list of tributary slots used by the client |
| 103 | service. Applicable in case of mux services."; |
| 104 | leaf-list values { |
| 105 | type uint8; |
| 106 | description |
| 107 | "Tributary tributary slot value."; |
| 108 | reference |
| 109 | "G.709/Y.1331, February 2016: Interfaces for the |
| 110 | Optical Transport Network (OTN)"; |
| 111 | } |
| 112 | } |
| 113 | |
| 114 | leaf dst-client-signal { |
| 115 | type identityref { |
| 116 | base tran-types:client-signal; |
| 117 | } |
| 118 | description |
| 119 | "Client signal at the destination endpoint of |
| 120 | the tunnel."; |
| 121 | } |
| 122 | |
| 123 | leaf dst-tpn { |
| 124 | type uint16 { |
| 125 | range "0..4095"; |
| 126 | } |
| 127 | description |
| 128 | "Tributary Port Number. Applicable in case of mux |
| 129 | services."; |
| 130 | reference |
| 131 | "RFC7139: GMPLS Signaling Extensions for Control of |
| 132 | Evolving G.709 Optical Transport Networks."; |
| 133 | } |
| 134 | |
| 135 | leaf dst-tsg { |
| 136 | type identityref { |
| 137 | base tran-types:tributary-slot-granularity; |
| 138 | } |
| 139 | description |
| 140 | "Tributary slot granularity. Applicable in case of mux |
| 141 | services."; |
| 142 | reference |
| 143 | "G.709/Y.1331, February 2016: Interfaces for the |
| 144 | Optical Transport Network (OTN)"; |
| 145 | } |
| 146 | |
| 147 | leaf dst-tributary-slot-count { |
| 148 | type uint16; |
| 149 | description |
| 150 | "Number of tributary slots used at the destination."; |
| 151 | } |
| 152 | |
| 153 | container dst-tributary-slots { |
| 154 | description |
| 155 | "A list of tributary slots used by the client |
| 156 | service. Applicable in case of mux services."; |
| 157 | leaf-list values { |
| 158 | type uint8; |
| 159 | description |
| 160 | "Tributary slot value."; |
| 161 | reference |
| 162 | "G.709/Y.1331, February 2016: Interfaces for the |
| 163 | Optical Transport Network (OTN)"; |
| 164 | } |
| 165 | } |
| 166 | } |
| 167 | |
| 168 | /* |
| 169 | Note: Comment has been given to authors of TE Tunnel model to add |
| 170 | tunnel-types to the model in order to identify the technology |
| 171 | type of the service. |
| 172 | |
| 173 | grouping otn-service-type { |
| 174 | description |
| 175 | "Identifies the OTN Service type."; |
| 176 | container otn-service { |
| 177 | presence "Indicates OTN Service."; |
| 178 | description |
| 179 | "Its presence identifies the OTN Service type."; |
| 180 | } |
| 181 | } // otn-service-type |
| 182 | |
| 183 | augment "/te:te/te:tunnels/te:tunnel/te:tunnel-types" { |
| 184 | description |
| 185 | "Introduce OTN service type for tunnel."; |
| 186 | ext:augment-identifier otn-service-type-augment; |
| 187 | uses otn-service-type; |
| 188 | } |
| 189 | */ |
| 190 | |
| 191 | /* |
| 192 | Note: Comment has been given to authors of TE Tunnel model to add |
| 193 | list of endpoints under config to support P2MP tunnel. |
| 194 | */ |
| 195 | augment "/te:te/te:tunnels/te:tunnel/te:config" { |
| 196 | description |
| 197 | "Augment with additional parameters required for OTN |
| 198 | service."; |
| 199 | //ext:augment-identifier otn-tunnel-endpoint-config-augment; |
| 200 | uses otn-tunnel-endpoint; |
| 201 | } |
| 202 | |
| 203 | augment "/te:te/te:tunnels/te:tunnel/te:state" { |
| 204 | description |
| 205 | "Augment with additional parameters required for OTN |
| 206 | service."; |
| 207 | //ext:augment-identifier otn-tunnel-endpoint-state-augment; |
| 208 | uses otn-tunnel-endpoint; |
| 209 | } |
| 210 | |
| 211 | /* |
| 212 | Note: Comment has been given to authors of TE Tunnel model to add |
| 213 | tunnel-lifecycle-event to the model. This notification is reported |
| 214 | for all lifecycle changes (create, delete, and update) to the |
| 215 | tunnel or lsp. |
| 216 | augment "/te:tunnel-lifecycle-event" { |
| 217 | description |
| 218 | "OTN service event"; |
| 219 | uses otn-service-type; |
| 220 | uses otn-tunnel-params; |
| 221 | |
| 222 | list endpoint { |
| 223 | key |
| 224 | "endpoint-address tp-id"; |
| 225 | description |
| 226 | "List of Tunnel Endpoints."; |
| 227 | uses te:tunnel-endpoint; |
| 228 | uses otn-tunnel-params; |
| 229 | } |
| 230 | } |
| 231 | */ |
| 232 | |
| 233 | |
| 234 | grouping p2p-path-ero { |
| 235 | description |
| 236 | "TE tunnel ERO configuration grouping"; |
| 237 | |
| 238 | leaf te-default-metric { |
| 239 | type uint32; |
| 240 | description |
| 241 | "Traffic engineering metric."; |
| 242 | } |
| 243 | leaf te-delay-metric { |
| 244 | type uint32; |
| 245 | description |
| 246 | "Traffic engineering delay metric."; |
| 247 | } |
| 248 | leaf te-hop-metric { |
| 249 | type uint32; |
| 250 | description |
| 251 | "Traffic engineering hop metric."; |
| 252 | } |
| 253 | container explicit-route-objects { |
| 254 | description "Explicit route objects container"; |
| 255 | leaf explicit-route-usage { |
| 256 | type identityref { |
| 257 | base te-types:route-usage-type; |
| 258 | } |
| 259 | description "An explicit-route hop action."; |
| 260 | } |
| 261 | list explicit-route-object { |
| 262 | key "index"; |
| 263 | description |
| 264 | "List of explicit route objects"; |
| 265 | leaf index { |
| 266 | type uint32; |
| 267 | description "Index of this explicit route object"; |
| 268 | } |
| 269 | uses te-types:explicit-route-hop; |
| 270 | } |
| 271 | } |
| 272 | } |
| 273 | |
| 274 | |
| 275 | rpc otn-te-tunnel-path-compute { |
| 276 | description "OTN TE tunnel path computation"; |
| 277 | input { |
| 278 | list request { |
| 279 | key "id"; |
| 280 | description "A list of path computation requests."; |
| 281 | |
| 282 | leaf id { |
| 283 | type uint8; |
| 284 | description |
| 285 | "Request ID."; |
| 286 | } |
| 287 | leaf type { |
| 288 | type identityref { |
| 289 | base te-types:tunnel-type; |
| 290 | } |
| 291 | description "TE tunnel type."; |
| 292 | } |
| 293 | leaf source { |
| 294 | type inet:ip-address; |
| 295 | description |
| 296 | "TE tunnel source address."; |
| 297 | } |
| 298 | leaf destination { |
| 299 | /* Add when check */ |
| 300 | type inet:ip-address; |
| 301 | description |
| 302 | "TE tunnel destination address"; |
| 303 | } |
| 304 | leaf src-tp-id { |
| 305 | type binary; |
| 306 | description |
| 307 | "TE tunnel source termination point identifier."; |
| 308 | } |
| 309 | leaf dst-tp-id { |
| 310 | type binary; |
| 311 | description |
| 312 | "TE tunnel destination termination point identifier."; |
| 313 | } |
| 314 | leaf switching-layer { |
| 315 | type identityref { |
| 316 | base te-types:switching-capabilities; |
| 317 | } |
| 318 | description |
| 319 | "Switching layer where the requests are computed."; |
| 320 | } |
| 321 | leaf encoding { |
| 322 | type identityref { |
| 323 | base te-types:lsp-encoding-types; |
| 324 | } |
| 325 | description "LSP encoding type"; |
| 326 | } |
| 327 | leaf protection-type { |
| 328 | type identityref { |
| 329 | base te-types:lsp-prot-type; |
| 330 | } |
| 331 | description "LSP protection type."; |
| 332 | } |
| 333 | leaf provider-id { |
| 334 | type te-types:te-global-id; |
| 335 | description |
| 336 | "An identifier to uniquely identify a provider."; |
| 337 | } |
| 338 | leaf client-id { |
| 339 | type te-types:te-global-id; |
| 340 | description |
| 341 | "An identifier to uniquely identify a client."; |
| 342 | } |
| 343 | leaf te-topology-id { |
| 344 | type te-types:te-topology-id; |
| 345 | description |
| 346 | "It is presumed that a datastore will contain many |
| 347 | topologies. To distinguish between topologies it is |
| 348 | vital to have UNIQUE topology identifiers."; |
| 349 | } |
| 350 | leaf setup-priority { |
| 351 | type uint8 { |
| 352 | range "0..7"; |
| 353 | } |
| 354 | description |
| 355 | "TE LSP setup priority"; |
| 356 | } |
| 357 | leaf hold-priority { |
| 358 | type uint8 { |
| 359 | range "0..7"; |
| 360 | } |
| 361 | description |
| 362 | "TE LSP hold priority"; |
| 363 | } |
| 364 | leaf te-path-metric-type { |
| 365 | type identityref { |
| 366 | base te-types:path-metric-type; |
| 367 | } |
| 368 | default te-types:path-metric-te; |
| 369 | description |
| 370 | "The tunnel path metric type."; |
| 371 | } |
| 372 | |
| 373 | leaf odu-type { |
| 374 | type identityref{ |
| 375 | base tran-types:tributary-protocol-type; |
| 376 | } |
| 377 | description "Type of ODU"; |
| 378 | } |
| 379 | container p2p-primary-paths { |
| 380 | description "Set of P2P primary paths container"; |
| 381 | list p2p-primary-path { |
| 382 | key "name"; |
| 383 | description |
| 384 | "List of primary paths for this tunnel."; |
| 385 | leaf name { |
| 386 | type string; |
| 387 | description "TE path name"; |
| 388 | } |
| 389 | uses p2p-path-ero; |
| 390 | } |
| 391 | } |
| 392 | container p2p-secondary-paths { |
| 393 | description "Set of P2P secondary paths container"; |
| 394 | list p2p-secondary-path { |
| 395 | key "name"; |
| 396 | description |
| 397 | "List of secondary paths for this tunnel."; |
| 398 | leaf name { |
| 399 | type string; |
| 400 | description "TE path name"; |
| 401 | } |
| 402 | uses p2p-path-ero; |
| 403 | } |
| 404 | } |
| 405 | uses otn-tunnel-endpoint; |
| 406 | } |
| 407 | } |
| 408 | output { |
| 409 | leaf return-code { |
| 410 | type enumeration { |
| 411 | enum success { |
| 412 | description "success"; |
| 413 | } |
| 414 | enum aborted { |
| 415 | description ""; |
| 416 | } |
| 417 | enum destination-not-found { |
| 418 | description ""; |
| 419 | } |
| 420 | enum invalid-argument { |
| 421 | description ""; |
| 422 | } |
| 423 | enum no-memory { |
| 424 | description ""; |
| 425 | } |
| 426 | enum no-path-found{ |
| 427 | description ""; |
| 428 | } |
| 429 | enum other-error { |
| 430 | description ""; |
| 431 | } |
| 432 | enum some-path-not-found{ |
| 433 | description ""; |
| 434 | } |
| 435 | enum source-not-found { |
| 436 | description ""; |
| 437 | } |
| 438 | enum topology-error { |
| 439 | description ""; |
| 440 | } |
| 441 | } |
| 442 | description |
| 443 | "Return code."; |
| 444 | } |
| 445 | list result { |
| 446 | key "id"; |
| 447 | description |
| 448 | "A list of results for all requests."; |
| 449 | |
| 450 | leaf id { |
| 451 | type uint8; |
| 452 | description |
| 453 | "Request ID."; |
| 454 | } |
| 455 | container p2p-primary-paths { |
| 456 | description "Set of P2P primary paths container"; |
| 457 | list p2p-primary-path { |
| 458 | key "name"; |
| 459 | description |
| 460 | "List of resultant primary paths for this tunnel."; |
| 461 | leaf name { |
| 462 | type string; |
| 463 | description "TE path name"; |
| 464 | } |
| 465 | uses p2p-path-ero; |
| 466 | } |
| 467 | } |
| 468 | container p2p-secondary-paths { |
| 469 | description "Set of P2P secondary paths container"; |
| 470 | list p2p-secondary-path { |
| 471 | key "name"; |
| 472 | description |
| 473 | "List of resultant secondary paths for this tunnel."; |
| 474 | leaf name { |
| 475 | type string; |
| 476 | description "TE path name"; |
| 477 | } |
| 478 | uses p2p-path-ero; |
| 479 | } |
| 480 | } |
| 481 | } |
| 482 | } |
| 483 | } |
| 484 | } |