aboutsummaryrefslogtreecommitdiffstats
path: root/platform-logic/generic-resource-api/src/main/359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502
[
    {
        "id": "c51171cf.967f48",
        "type": "dgstart",
        "name": "DGSTART",
        "outputs": 1,
        "x": 215,
        "y": 61,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "dc4fe414.ffc068"
            ]
        ]
    },
    {
        "id": "dc4fe414.ffc068",
        "type": "service-logic",
        "name": "GENERIC-RESOURCE-API ${project.version}",
        "module": "GENERIC-RESOURCE-API",
        "version": "${project.version}",
        "comments": "",
        "xml": "<service-logic xmlns='http://www.onap.org/sdnc/svclogic' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='${project.version}'>",
        "outputs": 1,
        "x": 499.2856903076172,
        "y": 122.23810863494873,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "7bc6b10b.958808"
            ]
        ]
    },
    {
        "id": "7bc6b10b.958808",
        "type": "method",
        "name": "method sotn-vnf-topology-operation-underlay-create",
        "xml": "<method rpc='sotn-vnf-topology-operation-underlay-create' mode='sync'>\n",
        "comments": "",
        "outputs": 1,
        "x": 505.42860412597656,
        "y": 207.00003051757812,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "abdb94c8.92ca2"
            ]
        ]
    },
    {
        "id": "abdb94c8.92ca2",
        "type": "block",
        "name": "block : atomic",
        "xml": "<block atomic=\"true\">",
        "atomic": "true",
        "outputs": 1,
        "x": 875.238037109375,
        "y": 231.66668701171875,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "ebb673b7.95bb08",
                "b3e2958c.9ee52",
                "e1a71481.b347c",
                "824a2826.fb7a5",
                "23822c5.535c954",
                "db0823f0.79d838",
                "9d444bb6.e5cc7",
                "d8fc2b2b.da9d38",
                "7de6e31b.ca690c",
                "37ce30ff.3ae068",
                "a026f709.be666",
                "d3e90ee2.8cdb8",
                "4530b43d.793bcc"
            ]
        ]
    },
    {
        "id": "b3e2958c.9ee52",
        "type": "set",
        "name": "set vnf-level-oper-status to Created",
        "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.order-status' value='Created' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.last-rpc-action' value='`$vnf-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.last-action' value='`$vnf-topology-operation-input.request-information.request-action`' />\n",
        "comments": "",
        "x": 1297.3848495483398,
        "y": 595.6706197531894,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "ebb673b7.95bb08",
        "type": "set",
        "name": "copy input data to service data",
        "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-id' value='`$prop.vnf-id`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.sdnc-request-header.' value='$vnf-topology-operation-input.sdnc-request-header.' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.request-information.' value='$vnf-topology-operation-input.request-information.' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.service-information.' value='$vnf-topology-operation-input.service-information.' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-information.' value='$vnf-topology-operation-input.vnf-information.' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.' value='$vnf-topology-operation-input.vnf-request-input.' />\n\n",
        "comments": "",
        "x": 1289.238037109375,
        "y": 490.6668718131259,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "23822c5.535c954",
        "type": "execute",
        "name": "execute generate-vnf-index",
        "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='generateUUID' >\n<parameter name=\"ctx-destination\" value=\"prop.vnf-id\"/>\n",
        "comments": "",
        "outputs": 1,
        "x": 1277.5715408325195,
        "y": 440.3334558280185,
        "z": "2acad42e.98ae6c",
        "wires": [
            []
        ]
    },
    {
        "id": "37ce30ff.3ae068",
        "type": "set",
        "name": "set vnf-index to service data",
        "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-information.vnf-id' value='`$prop.vnf-id`' />\n",
        "comments": "",
        "x": 1288.5716171264648,
        "y": 547.3334596427158,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "e1a71481.b347c",
        "type": "switchNode",
        "name": "switch service-data.vnfs.vnf_length",
        "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n",
        "comments": "",
        "outputs": 1,
        "x": 1304.5713577270508,
        "y": 110.33337858039886,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "2aa8bb99.a4b4cc",
                "2ff8b11d.a3a30e"
            ]
        ]
    },
    {
        "id": "2aa8bb99.a4b4cc",
        "type": "other",
        "name": "NULL",
        "xml": "<outcome value=''>\n",
        "comments": "",
        "outputs": 1,
        "x": 1539.285743713379,
        "y": 105.47619893867522,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "9f14dc9.0335b2"
            ]
        ]
    },
    {
        "id": "9f14dc9.0335b2",
        "type": "set",
        "name": "set vnf-index=0",
        "xml": "<set>\n<parameter name='vnf-index' value='0' />\n",
        "comments": "",
        "x": 1699.5714492797852,
        "y": 105.4762904914096,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "2ff8b11d.a3a30e",
        "type": "other",
        "name": "other",
        "xml": "<outcome value='Other'>\n",
        "comments": "",
        "outputs": 1,
        "x": 1535.714282989502,
        "y": 138.76203039009124,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "c07d0fb1.6b3d1"
            ]
        ]
    },
    {
        "id": "1270cfd.bc37b3",
        "type": "set",
        "name": "set vnf-index = vnf_length",
        "xml": "<set>\n<parameter name='vnf-index' value='`$service-data.vnfs.vnf_length`' />\n",
        "comments": "",
        "x": 1928.5715255737305,
        "y": 117.04775598365813,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "41d9a632.4f7ff",
        "type": "for",
        "name": "for each existing VNF",
        "xml": "<for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
        "comments": "",
        "outputs": 1,
        "x": 1917.000144958496,
        "y": 152.0477278502658,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "648fa43a.d20ca4"
            ]
        ]
    },
    {
        "id": "c07d0fb1.6b3d1",
        "type": "block",
        "name": "block",
        "xml": "<block>\n",
        "atomic": "false",
        "comments": "",
        "outputs": 1,
        "x": 1670.428565979004,
        "y": 140.76199987251312,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "1270cfd.bc37b3",
                "41d9a632.4f7ff"
            ]
        ]
    },
    {
        "id": "648fa43a.d20ca4",
        "type": "switchNode",
        "name": "switch vnf-information.vnf-id == service-data.vnfs.vnf[].vnf-id",
        "xml": "<switch test='`$vnf-topology-operation-input.vnf-information.vnf-id == $service-data.vnfs.vnf[$idx].vnf-id`'>\n",
        "comments": "",
        "outputs": 1,
        "x": 2310.2858810424805,
        "y": 152.6192119391635,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "fcc42c1e.bc5548"
            ]
        ]
    },
    {
        "id": "fcc42c1e.bc5548",
        "type": "outcomeTrue",
        "name": "true",
        "xml": "<outcome value='true'>\n",
        "comments": "",
        "outputs": 1,
        "x": 2591.5715827941895,
        "y": 151.1906173499301,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "51470afc.fd843c"
            ]
        ]
    },
    {
        "id": "75fcb25e.311ddc",
        "type": "comment",
        "name": "make sure this vnf-id doesn't exist already",
        "info": "",
        "comments": "",
        "x": 2279.428497314453,
        "y": 116.19060399848968,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "824a2826.fb7a5",
        "type": "set",
        "name": "set new vnf_length",
        "xml": "<set>\n<parameter name='service-data.vnfs.vnf_length' value='`$vnf-index + 1`' />\n",
        "comments": "",
        "x": 1235.571533203125,
        "y": 388.33343505859375,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "db0823f0.79d838",
        "type": "returnSuccess",
        "name": "return success",
        "xml": "<return status='success'>\n<parameter name=\"ack-final-indicator\" value=\"Y\" />\n<parameter name=\"error-code\" value=\"200\" />\n<parameter name=\"error-message\" value=\"`$error-message`\" />\n",
        "comments": "",
        "x": 1236.5715026855469,
        "y": 858.5969713004306,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "7de6e31b.ca690c",
        "type": "save",
        "name": "save service relationship in AAI",
        "xml": "<save plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='service-instance:relationship-list' \n      key='service-instance.service-instance-id = $service-data.service-information.service-instance-id\n         AND customer.global-customer-id = $service-data.vnfs.vnf[$vnf-index].vnf-data.service-information.global-customer-id \n         AND service-subscription.service-type = $service-data.vnfs.vnf[$vnf-index].vnf-data.service-information.subscription-service-type' \n      force=\"true\" pfx=\"tmp.AnAI-data\">\n<parameter name=\"relationship-list.relationship[0].related-to\" value=\"generic-vnf\" />\n<parameter name=\"relationship-list.relationship[0].related-link\" value=\"`'/network/generic-vnfs/generic-vnf/' + $prop.vnf-id`\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-key\" value=\"generic-vnf.vnf-id\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-value\" value=\"`$prop.vnf-id`\" />\n\n\n<!--key='service-instance.service-instance-id = $service-data.service-information.service-instance-id -->\n<!--key='service-instance.service-instance-id = $service-data.service-instance-id -->\n",
        "comments": "",
        "outputs": 1,
        "x": 1269.2382736206055,
        "y": 807.5968644889072,
        "z": "2acad42e.98ae6c",
        "wires": [
            []
        ]
    },
    {
        "id": "9d444bb6.e5cc7",
        "type": "set",
        "name": "set vnf-index and vnf-object-path",
        "xml": "<set>\n<parameter name='vnfId' value='`$prop.vnf-id`' />\n<parameter name=\"vnf-object-path\" value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'  + $vnf-topology-operation-input.service-information.service-instance-id  + '/service-data/vnfs/vnf/'  + $prop.vnf-id  + '/vnf-data/'` \" />",
        "comments": "",
        "x": 1290.571533203125,
        "y": 636.5968902381137,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "51470afc.fd843c",
        "type": "returnFailure",
        "name": "return failure",
        "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"500\" />\n    <parameter name=\"error-message\" value=\"`'VNF id ' + $service-data.vnfs.vnf[$idx].vnf-id\n      + ' already exists, and has order status ' + $service-data.vnfs.vnf[$idx].vnf-data.vnf-level-oper-status.order-status`\" />\n",
        "comments": "",
        "x": 2720.142951965332,
        "y": 202.19063165504485,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "d8fc2b2b.da9d38",
        "type": "save",
        "name": "save AnAI - vnf-instance.orchestration-status",
        "xml": "<save plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\tresource=\"generic-vnf\"   \n\t\tkey='generic-vnf.vnf-id = $prop.vnf-id' >\n<parameter name=\"orchestration-status\" value=\"Created\" />\n<parameter name=\"in-maint\" value = \"true\" />\n<parameter name=\"vnf-type\" value='`$prop.vnfName`' />\n<parameter name=\"vnf-name\" value = \"`$prop.vnfName`\"/>\n<parameter name=\"model-invariant-id\" value = \"`$vnf-topology-operation-input.vnf-information.onap-model-information.model-invariant-uuid`\"/>\n<parameter name=\"model-version-id\" value = \"`$vnf-topology-operation-input.vnf-information.onap-model-information.model-uuid`\"/>\n<parameter name=\"model-customization-id\" value = \"`$vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`\"/>",
        "comments": "",
        "outputs": 1,
        "x": 1345.5458374023438,
        "y": 746.2471072943881,
        "z": "2acad42e.98ae6c",
        "wires": [
            []
        ]
    },
    {
        "id": "766790a.b9c79f",
        "type": "comment",
        "name": "TODO: change AAI models",
        "info": "",
        "comments": "",
        "x": 1279.1820983886719,
        "y": 705.9743230612949,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "a966163d.bdafe8",
        "type": "execute",
        "name": "execute split parameterName",
        "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$vnf-topology-operation-input.vnf-request-input.vnf-input-parameters.param[$idx].name`'/>\n<parameter name=\"regex\" value=\"_\"/>\n<parameter name=\"ctx_memory_result_key\" value=\"param-prefix\"/>\n",
        "comments": "",
        "outputs": 1,
        "x": 1705.7395858764648,
        "y": 199.75002291519195,
        "z": "2acad42e.98ae6c",
        "wires": [
            []
        ]
    },
    {
        "id": "1dc30465.a19184",
        "type": "block",
        "name": "block",
        "xml": "<block>\n",
        "atomic": "false",
        "comments": "",
        "outputs": 1,
        "x": 1509.483383178711,
        "y": 204.00189593154937,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "a966163d.bdafe8",
                "a75d0084.0dea2"
            ]
        ]
    },
    {
        "id": "a026f709.be666",
        "type": "for",
        "name": "for loop idx - VNF input parameters",
        "xml": "<for index=\"idx\" start=\"0\" end=\"`$vnf-topology-operation-input.vnf-request-input.vnf-input-parameters.param_length`\">\n",
        "comments": "",
        "outputs": 1,
        "x": 1294.7050399780273,
        "y": 206.44631197769195,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "1dc30465.a19184"
            ]
        ]
    },
    {
        "id": "d3e90ee2.8cdb8",
        "type": "set",
        "name": "set vnf-request-input.",
        "xml": "<set>\n<parameter name='vnf-request-input.' value='`$vnf-topology-operation-input.vnf-request-input.`' />\n",
        "comments": "",
        "x": 1251.7046737670898,
        "y": 276.77101900894195,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "a75d0084.0dea2",
        "type": "set",
        "name": "set parameterName",
        "xml": "<set>\n<parameter name=\"`vnf-topology-operation-input.vnf-request-input.vnf-input-parameters.param[$idx].name`\" value='`$param-prefix[$param-prefix_length -1]`'/>\n",
        "comments": "",
        "x": 1682.7395858764648,
        "y": 245.75002291519195,
        "z": "2acad42e.98ae6c",
        "wires": []
    },
    {
        "id": "4530b43d.793bcc",
        "type": "for",
        "name": "for each sdwan-get-request-input-param",
        "xml": "<for index=\"idx\" start=\"0\" end=\"`$vnf-topology-operation-input.vnf-request-input.vnf-input-parameters.param_length`\">\n",
        "comments": "",
        "outputs": 1,
        "x": 1307.7395858764648,
        "y": 328.75002291519195,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "dc4ef169.09fde8"
            ]
        ]
    },
    {
        "id": "dc4ef169.09fde8",
        "type": "block",
        "name": "block",
        "xml": "<block>\n",
        "atomic": "false",
        "comments": "",
        "outputs": 1,
        "x": 1533.9722518920898,
        "y": 327.09377291519195,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "b619e27a.688618"
            ]
        ]
    },
    {
        "id": "b619e27a.688618",
        "type": "switchNode",
        "name": "switch vnf name",
        "xml": "<switch test=\"`$vnf-topology-operation-input.vnf-request-input.vnf-input-parameters.param[$idx].name == 'name'`\">\n",
        "comments": "",
        "outputs": 1,
        "x": 1690.4722518920898,
        "y": 325.0938339503482,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "91d21a65.20ca"
            ]
        ]
    },
    {
        "id": "91d21a65.20ca",
        "type": "outcomeTrue",
        "name": "true",
        "xml": "<outcome value='true'>\n",
        "comments": "",
        "outputs": 1,
        "x": 1851.4726181030273,
        "y": 325.09389498550445,
        "z": "2acad42e.98ae6c",
        "wires": [
            [
                "9c25080f.021b"
            ]
        ]
    },
    {
        "id": "9c25080f.021b",
        "type": "set",
        "name": "set vnf name",
        "xml": "<set>\n<parameter name='prop.vnfName' value='`$vnf-topology-operation-input.vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n",
        "comments": "",
        "x": 2009.4727401733398,
        "y": 323.6939316065982,
        "z": "2acad42e.98ae6c",
        "wires": []
    }
]