diff options
author | gaurav <gaurav.agrawal@huawei.com> | 2018-10-05 11:29:55 +0530 |
---|---|---|
committer | gaurav <gaurav.agrawal@huawei.com> | 2018-10-05 11:29:55 +0530 |
commit | d9e26826bff32fdfd92296e2f4b425a81e7ecdf3 (patch) | |
tree | c0bc1573ccdc43aec9848b5754f03a50419bb13f /platform-logic/generic-resource-api/src/main/json/sdwan | |
parent | 351d5315bafe499e9f6904fa51c3b70c13f3cb70 (diff) |
Refactored SOTN and SDWAN DG
Refactored SOTN and SDWAN DG to seperate sub directories for better
maintainability.
Change-Id: I49c57d20fc8fcb7de65d3634bceb691d0b7f80fd
Issue-ID: SDNC-350
Signed-off-by: Gaurav Agrawal <gaurav.agrawal@huawei.com>
Former-commit-id: d3d3ce137625a244accf736da3a8f6736b44300e
Diffstat (limited to 'platform-logic/generic-resource-api/src/main/json/sdwan')
27 files changed, 26561 insertions, 0 deletions
diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-activate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-activate.json new file mode 100644 index 00000000..3a508656 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-activate.json @@ -0,0 +1,2267 @@ +[ + { + "id": "93b0ef5b.3e408", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 139, + "y": 54, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "a7b13cb2.c08d5" + ] + ] + }, + { + "id": "a7b13cb2.c08d5", + "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": 330.0000057220459, + "y": 124.00001811981201, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "5d2c2651.f9a3d8" + ] + ] + }, + { + "id": "5d2c2651.f9a3d8", + "type": "method", + "name": "sdwan-attachment-topology-operation-activate", + "xml": "<method rpc='sdwan-attachment-topology-operation-activate' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 318.00012397766113, + "y": 212.00000095367432, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "c8d63fe2.b2b23" + ] + ] + }, + { + "id": "c8d63fe2.b2b23", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 220.00013732910156, + "y": 898.0002890825272, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "d462bbd.082f148", + "ce900383.4855d", + "bc468479.f5a808", + "cc58fb4f.38c9d8", + "5687be1a.59a66", + "a1d43226.8d32d", + "a6ce139d.8cd82", + "fcbe570.434f0a8", + "e2fb4f17.bce7a", + "3aed3696.4cf77a", + "e78f2c1f.7461f", + "f801a0de.16907", + "d4bcebf0.e04a68", + "a351ad64.5b62", + "169bc249.b8cede", + "86489e85.9e429", + "6a1b7e4b.2ba26", + "7ad41615.6876c8", + "fb5be39e.fa586", + "2406d281.b1df1e", + "4e50db83.d2f224", + "862cb704.9f9128", + "4e5f3349.352d6c", + "28b00a13.902c76", + "9a0f8d9a.4d443", + "f9894d64.11723" + ] + ] + }, + { + "id": "d462bbd.082f148", + "type": "set", + "name": "set tmp.ar.allotted-resource-id,etc", + "xml": "<set>\n<parameter name='tmp.ar.allotted-resource-id' value='`$connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-id`' />\n<parameter name='tmp.ar.parent-service-instance-id' value='`$connection-attachment-topology-operation-input.allotted-resource-information.parent-service-instance-id`' />\n\n\n", + "comments": "", + "x": 730.9935626983643, + "y": 165.99348783493042, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "1a77342a.e82ccc", + "type": "comment", + "name": "set tmp ar-id to fetch resource from MDSAL", + "info": "", + "comments": "", + "x": 759.9538745880127, + "y": 130.02528381347656, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "ce900383.4855d", + "type": "set", + "name": "set tmp.ar.self-link", + "xml": "<set>\n<parameter name='tmp.ar.self-link' value=\"`'restconf/config/GENERIC-RESOURCE-API:connection-attachment-allotted-resources/connection-attachment-allotted-resource/'\n + $tmp.ar.allotted-resource-id\n + '/allotted-resource-data/connection-attachment-topology/'` \" />\n\n", + "comments": "", + "x": 684.993501663208, + "y": 258.99349308013916, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "cc58fb4f.38c9d8", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 691.255392074585, + "y": 346.66022205352783, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "bc468479.f5a808", + "type": "execute", + "name": "generate allotted-resource tmp.ar-url", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"`$prop.restapi.connection-attachment-allottedresource`\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url\"/>\n <parameter name=\"target\" value=\"{allotted-resource-id}\"/>\n <parameter name=\"replacement\" value=\"`$tmp.ar.allotted-resource-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 738.255449295044, + "y": 434.6602258682251, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "cd648838.9eb298", + "type": "comment", + "name": "GET connection-attachment-allotted-resource from mdsal", + "info": "", + "comments": "", + "x": 792.8084106445312, + "y": 503.53865146636963, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "9dbfb79f.f4be18", + "type": "comment", + "name": "Used for setting output to API Handler", + "info": "", + "comments": "", + "x": 738.9935321807861, + "y": 225.99350261688232, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "247d684d.e973f8", + "type": "comment", + "name": "Obtain different URL, template location etc", + "info": "For saving resource information to MDSAL & for AAI", + "comments": "", + "x": 756.9934978485107, + "y": 311.8823833465576, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "6426cfba.672b8", + "type": "comment", + "name": "Used to Get AR by id to MDSAL, same as self-link", + "info": "", + "comments": "", + "x": 782.9935169219971, + "y": 398.882342338562, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "406068c.1da4a98", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1246.6668224334717, + "y": 516.999979019165, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "519eae9c.9b2f6" + ] + ] + }, + { + "id": "519eae9c.9b2f6", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1390.6669006347656, + "y": 474.4998970031738, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "d1dd16e9.faf918" + ] + ] + }, + { + "id": "d1dd16e9.faf918", + "type": "switchNode", + "name": "switch cr length", + "xml": "<switch test='`$mdsal-ar.connection-attachment-allotted-resource_length`'>\n", + "comments": "", + "outputs": 1, + "x": 1559.5243244171143, + "y": 472.11906814575195, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "6a124f25.b362a", + "caf37a34.d778a8" + ] + ] + }, + { + "id": "6a124f25.b362a", + "type": "other", + "name": "outcome 1", + "xml": "<outcome value='1'>\n", + "comments": "", + "outputs": 1, + "x": 1714.8574600219727, + "y": 444.1189832687378, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "d1a8c266.f1b55" + ] + ] + }, + { + "id": "d1a8c266.f1b55", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic='true'>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1873.3812637329102, + "y": 442.02383041381836, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "bb518772.b81358", + "645ade11.426a1", + "44255d43.96da34" + ] + ] + }, + { + "id": "2aedf56b.f1b1ba", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"Error: Connection attachment resource not exist\" />\n \n", + "comments": "", + "x": 1813.5191955566406, + "y": 549.0660648345947, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "e00fd6fc.ea7778", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1238.5186252593994, + "y": 552.0660638809204, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "d0418e39.56684" + ] + ] + }, + { + "id": "d0418e39.56684", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1418.518575668335, + "y": 552.7326145172119, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "2aedf56b.f1b1ba" + ] + ] + }, + { + "id": "caf37a34.d778a8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1706.1854629516602, + "y": 503.39935779571533, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "2aedf56b.f1b1ba" + ] + ] + }, + { + "id": "bb518772.b81358", + "type": "set", + "name": "set connection-attachment-ar from get", + "xml": "<set>\n<parameter name='connection-attachment-ar.' value='$mdsal-ar.connection-attachment-allotted-resource[0].' />\n", + "comments": "", + "x": 2120.4447174072266, + "y": 415.00008249282837, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "645ade11.426a1", + "type": "set", + "name": "set oper-status", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-action' value='`$connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.request-information.request-action`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-rpc-action' value='`$connection-attachment-ar.allotted-resource-status.rpc-action`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-svc-request-id' value='`$connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.sdnc-request-header.svc-request-id`' />\n\n", + "comments": "", + "x": 2069.444986343384, + "y": 517.4286185503006, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "44255d43.96da34", + "type": "switchNode", + "name": "switch order-status", + "xml": "<switch test='`$connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.order-status`'>\n", + "comments": "", + "outputs": 1, + "x": 2071.444803237915, + "y": 457.0000435113907, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "48830e3c.30889", + "2b84fa59.5b57c6" + ] + ] + }, + { + "id": "2b84fa59.5b57c6", + "type": "outcome", + "name": "outcome Created", + "xml": "<outcome value='Created'>\n", + "comments": "", + "outputs": 1, + "x": 2299.0451526641846, + "y": 448.00010073184967, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "45156448.968e9c" + ] + ] + }, + { + "id": "48830e3c.30889", + "type": "outcome", + "name": "outcome Other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2293.759048461914, + "y": 487.42865800857544, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "a911339e.75cc3" + ] + ] + }, + { + "id": "45156448.968e9c", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2458.515281677246, + "y": 448.37570571899414, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "a911339e.75cc3", + "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\" \n value=\"`'Existing connection-attachment-allotted-resource with order status of ' + $connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.order-status + '.'`\" />\n", + "comments": "", + "x": 2469.666862487793, + "y": 486.000057220459, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "233d3f47.5a62d", + "type": "call", + "name": "call GENERIC-RESOURCE-API:sdwan-get-saved-ar-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-saved-ar-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 963.3030433654785, + "y": 623.4936294555664, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "5687be1a.59a66", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 657.3091430664062, + "y": 624.5, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "233d3f47.5a62d" + ] + ] + }, + { + "id": "9b9946c9.3f3d68", + "type": "comment", + "name": "GET parent-service-data from mdsal to check existence of other End point", + "info": "", + "comments": "", + "x": 835.00048828125, + "y": 695.53173828125, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "2f29782e.56da68", + "type": "comment", + "name": "GET connection-attachment-ar to store AR data from mdsal", + "info": "", + "comments": "", + "x": 2182.4727783203125, + "y": 375.5039367675781, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "a1d43226.8d32d", + "type": "set", + "name": "set tmp.ar.parent-service-instance-id", + "xml": "<set>\n<parameter name='tmp.ar.parent-service-instance-id' value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.parent-service-instance-id` \" />\n\n", + "comments": "", + "x": 720.9688110351562, + "y": 725.0001220703125, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "9e759fa5.c7253", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1080.968978881836, + "y": 782.0000915527344, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "b7458f6f.6b103" + ] + ] + }, + { + "id": "5edd87c2.935d58", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1072.8207817077637, + "y": 817.0661764144897, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "45257af8.9c6094" + ] + ] + }, + { + "id": "45257af8.9c6094", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"Error: Parent service data not available\" />\n \n", + "comments": "", + "x": 1218.9695625305176, + "y": 816.3335876464844, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "b7458f6f.6b103", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1211.9690742492676, + "y": 782.0001525878906, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "41e65fa0.2c10b", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 894.7313137054443, + "y": 2142.9540371894836, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "b6c4d495.4bdad8" + ] + ] + }, + { + "id": "b6c4d495.4bdad8", + "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=\"AAI failed\" />\n", + "comments": "", + "x": 1061.2551345825195, + "y": 2169.5730443000793, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "691b6216.46804c", + "type": "failure", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 896.8265419006348, + "y": 2190.715879917145, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "b6c4d495.4bdad8" + ] + ] + }, + { + "id": "39d44506.fc1dea", + "type": "comment", + "name": "Save Resource to AAI", + "info": "", + "comments": "", + "x": 668.7789573669434, + "y": 2131.3032002449036, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "169bc249.b8cede", + "type": "set", + "name": "set output to api handler", + "xml": "<set>\n<parameter name='allotted-resource-id' value='`$tmp.ar.allotted-resource-id`' />\n<parameter name='connection-attachment-object-path' value=\"`$tmp.ar.self-link`\"/>\n<parameter name='service-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $connection-attachment-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'`\"/>\n \n", + "comments": "", + "x": 683.5466537475586, + "y": 2052.8286814689636, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "86489e85.9e429", + "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": 643.9598255157471, + "y": 2238.4444699287415, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "a351ad64.5b62", + "type": "execute", + "name": "execute RestApiCallNode - PUT AR by id", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='templateFileName' value=\"`$prop.restapi.templateDir + '/' + $prop.restapi.sdwan-attachment.templatefile`\" />\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='PUT' />\n <parameter name=\"responsePrefix\" value=\"mdsal-ar\" />\n\n", + "comments": "", + "outputs": 1, + "x": 736.278736114502, + "y": 1977.4695343971252, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "7f052e3d.cfc45", + "9a139c80.89827", + "c0ebd24f.2c1be" + ] + ] + }, + { + "id": "7f052e3d.cfc45", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 990.9201583862305, + "y": 2021.8009285926819, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "d5b448a4.f99588" + ] + ] + }, + { + "id": "9a139c80.89827", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 992.9201812744141, + "y": 1980.3008927330375, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "d5b448a4.f99588" + ] + ] + }, + { + "id": "c0ebd24f.2c1be", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 996.6702651977539, + "y": 1931.6580452919006, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "da728790.b76f18" + ] + ] + }, + { + "id": "d5b448a4.f99588", + "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=\"Error updating md-sal for connection-attachment-allotted-resource\" />\n", + "comments": "", + "x": 1151.6702842712402, + "y": 2000.05095911026, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "da728790.b76f18", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1124.3262100219727, + "y": 1933.8502135276794, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "3aed3696.4cf77a", + "type": "set", + "name": "set ar-data", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-status.action' value=\"`$connection-attachment-topology-operation-input.request-information.request-action` \" />\n<parameter name='connection-attachment-ar.allotted-resource-status.rpc-name' value=\"connection-attachment-topology-operation\" />\n<parameter name='connection-attachment-ar.allotted-resource-status.rpc-action' value=\"`$connection-attachment-topology-operation-input.sdnc-request-header.svc-action` \" />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.request-information.' value=\"`$connection-attachment-topology-operation-input.request-information.` \" />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.sdnc-request-header.' value=\"`$connection-attachment-topology-operation-input.sdnc-request-header.` \" />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.service-information.' value=\"`$connection-attachment-topology-operation-input.service-information.` \" />\n", + "comments": "", + "x": 638.4923515319824, + "y": 1811.8504354953766, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "f801a0de.16907", + "type": "execute", + "name": "execute getTime", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='setTime' >\n <parameter name=\"outputPath\" value=\"tmp.current-time\" />\n\n", + "comments": "", + "outputs": 1, + "x": 655.7781944274902, + "y": 1884.4700331687927, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "d4bcebf0.e04a68", + "type": "set", + "name": "set allotted-resource-oper-status", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.order-status' value='Active' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-action' value='`$connection-attachment-topology-operation-input.request-information.request-action`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-rpc-action' value='`$connection-attachment-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-svc-request-id' value='`$connection-attachment-topology-operation-input.sdnc-request-header.svc-request-id`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.create-timestamp' value='`$tmp.current-time`' />\n", + "comments": "", + "x": 705.7652740478516, + "y": 1921.4211134910583, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "e78f2c1f.7461f", + "type": "set", + "name": "set model-data", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-data.connection-attachment-topology.onap-model-information.' value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.onap-model-information.` \" />", + "comments": "", + "x": 652.3338928222656, + "y": 1851.025085926056, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "82a1071f.9cdd18", + "type": "comment", + "name": "Prepare data for allotted-resource addition to MDSAL", + "info": "This will add to allotted-resource which is present inside service.", + "comments": "", + "x": 763.6673889160156, + "y": 1773.0250434875488, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "74588870.73e178", + "type": "comment", + "name": "Add to allotted-resources in mdsal", + "info": "", + "comments": "", + "x": 707.2471809387207, + "y": 1739.4383397102356, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "4e5f3349.352d6c", + "type": "update", + "name": "update AAI allotted-resource", + "xml": "<update plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"allotted-resource\" \n\t\tkey=\"customer.global-customer-id = $connection-attachment-topology-operation-input.service-information.global-customer-id AND\n\t\t\tservice-subscription.service-type = $connection-attachment-topology-operation-input.service-information.subscription-service-type AND\n\t\t\tservice-instance.service-instance-id = $connection-attachment-topology-operation-input.service-information.service-instance-id AND\n\t\t\tallotted-resource.id = $tmp.ar.allotted-resource-id\"\n pfx='pfx' local-only='false' force='false'>\n\t<parameter name=\"description\" value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-type`\" />\n\t<parameter name=\"selflink\" value=\"`$tmp.ar.self-link`\" />\n\t<parameter name=\"model-invariant-id\" value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.onap-model-information.model-invariant-uuid`\" />\n\t<parameter name=\"model-version-id\" value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.onap-model-information.model-uuid`\" />\n\t<parameter name=\"operational-status\" value=\"Active\" />\n", + "comments": "", + "outputs": 1, + "x": 695.2232360839844, + "y": 2168.7553429603577, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "41e65fa0.2c10b", + "691b6216.46804c" + ] + ] + }, + { + "id": "a6ce139d.8cd82", + "type": "execute", + "name": "execute RestApiCallNode - get-resource connection-attachment-allotted-resource", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-ar\" />\n\n", + "comments": "", + "outputs": 1, + "x": 867.0039672851562, + "y": 535.00390625, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "406068c.1da4a98", + "e00fd6fc.ea7778" + ] + ] + }, + { + "id": "fcbe570.434f0a8", + "type": "execute", + "name": "execute RestApiCallNode - get-resource parent service data", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-psd`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-psd\" />\n\n", + "comments": "", + "outputs": 1, + "x": 790.0040893554688, + "y": 798.0040893554688, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "9e759fa5.c7253", + "5edd87c2.935d58" + ] + ] + }, + { + "id": "e2fb4f17.bce7a", + "type": "execute", + "name": "get parent-service-data url", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"/restconf/config/GENERIC-RESOURCE-API:services/service/{service-instance-id}/service-data\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url-psd\"/>\n <parameter name=\"target\" value=\"{service-instance-id}\"/>\n <parameter name=\"replacement\" value=\"`$tmp.ar.parent-service-instance-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 690.0039978027344, + "y": 761.0039224624634, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "1f1e2af2.8cbfa5", + "type": "set", + "name": "set prop.ar.provided-allotted-resource-id", + "xml": "<set>\n<parameter name='prop.ar.provided-allotted-resource-id' value='`$mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource[$pidx].allotted-resource-id`' />\n\n", + "comments": "", + "x": 1547.9964752197266, + "y": 850.1218557357788, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "fc107783.f66638", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 2053.9970703125, + "y": 944.4551391601562, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "23bfc366.b2fa3c" + ] + ] + }, + { + "id": "d6f3b7ed.897558", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2057.848445892334, + "y": 906.52121925354, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "62911322.6e35fc" + ] + ] + }, + { + "id": "69edf94d.eac048", + "type": "for", + "name": "for arvidx.. mdsal-sd.service-data.vnfs.vnf_length[]", + "xml": "<for index='arvidx' start='0' end='`$mdsal-sd.service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1949.9976425170898, + "y": 1672.1222692728043, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "764ffe4a.681ad" + ] + ] + }, + { + "id": "764ffe4a.681ad", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1709.6641387939453, + "y": 1744.1224619150162, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "b8e7c061.bd378" + ] + ] + }, + { + "id": "b8e7c061.bd378", + "type": "switchNode", + "name": "switch ActivateSiteInstance", + "xml": "<switch test=\"`$mdsal-sd.service-data.vnfs.vnf[$arvidx].vnf-data.request-information.request-action == 'ActivateSiteInstance'`\">\n\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 1922.5293731689453, + "y": 1745.3203302621841, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "af3c96cc.a1d208" + ] + ] + }, + { + "id": "af3c96cc.a1d208", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2127.52872467041, + "y": 1748.3203264474869, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "a89b6820.3b89d8" + ] + ] + }, + { + "id": "8d253099.60ab9", + "type": "set", + "name": "set tmp.sitevidx ", + "xml": "<set>\n<parameter name='tmp.sitevidx' value='`$arvidx`' />\n\n", + "comments": "", + "x": 2471.528896331787, + "y": 1728.3206740617752, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "6d8cc41a.be1cfc", + "type": "set", + "name": "set prop.ar-parent-service-instance-id", + "xml": "<set>\n<parameter name='prop.ar-parent-service-instance-id' value='`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.allotted-resource-information.parent-service-instance-id`' /> \n", + "comments": "", + "x": 1698.9970703125, + "y": 1091.1221185922623, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "f4b5259e.86dd38", + "type": "for", + "name": "for loop aridx - Get role from allotted resource", + "xml": "<for index=\"aridx\" start=\"0\" end=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 1725.9965839385986, + "y": 1048.6217069625854, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "4483e9ee.7ffd68" + ] + ] + }, + { + "id": "c5da2f8.eb203d", + "type": "switchNode", + "name": "switch Role", + "xml": "<switch test=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$aridx].name == 'role'`\">\n", + "comments": "", + "outputs": 1, + "x": 2156.9968280792236, + "y": 1014.621829032898, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "4dcb3b71.c91564" + ] + ] + }, + { + "id": "4dcb3b71.c91564", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2296.9970722198486, + "y": 1012.6219511032104, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "abbbe638.28eb78" + ] + ] + }, + { + "id": "abbbe638.28eb78", + "type": "set", + "name": "set prop.role", + "xml": "<set>\n<parameter name='prop.role' value='`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$aridx].value`' />\n", + "comments": "", + "x": 2440.9978046417236, + "y": 1012.2218046188354, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "96905d4d.266e3", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 2004.9968872070312, + "y": 1191.1219259500504, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "20f71ccb.8bb9b4" + ] + ] + }, + { + "id": "6d849909.165408", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2002.8492164611816, + "y": 1152.18805372715, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "f2dcd85c.bce9e8" + ] + ] + }, + { + "id": "62911322.6e35fc", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2183.996570587158, + "y": 903.6216526031494, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "23bfc366.b2fa3c", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1349.496524810791, + "y": 1083.6217823028564, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "f4b5259e.86dd38", + "6d8cc41a.be1cfc", + "eed01b55.d04f18", + "48c9897c.fcd5b8" + ] + ] + }, + { + "id": "f2dcd85c.bce9e8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2132.4974098205566, + "y": 1145.6220136880875, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "20f71ccb.8bb9b4", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1731.4971466064453, + "y": 1270.6221548318863, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "873845fc.6f6098" + ] + ] + }, + { + "id": "615b5e26.43cbe", + "type": "for", + "name": "for loop siteidx - Get site ID from servicedata", + "xml": "<for index=\"siteidx\" start=\"0\" end=\"`$mdsal-sd.service-data.vnfs.vnf[$tmp.sitevidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2550.4985961914062, + "y": 1778.6224666833878, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "b6197b80.43b5b8" + ] + ] + }, + { + "id": "dbd732d1.3a3c8", + "type": "switchNode", + "name": "switch siteId", + "xml": "<switch test=\"`$mdsal-sd.service-data.vnfs.vnf[$tmp.sitevidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$siteidx].name == 'siteId'`\">\n\n", + "comments": "", + "outputs": 1, + "x": 2021.501958847046, + "y": 1892.6239286661148, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "a928d05f.807d7" + ] + ] + }, + { + "id": "a928d05f.807d7", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2176.5023288726807, + "y": 1894.6242953538895, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "7763b485.9a224c" + ] + ] + }, + { + "id": "ae878fc7.06ea3", + "type": "set", + "name": "Add sites to list and update length", + "xml": "<set>\n<parameter name='prop.siteIds[$prop.siteIds_length]' value='`$prop.attach.siteId`' />\n<parameter name='prop.siteIds_length' value='`$prop.siteIds_length + 1`' />\n\n\n\n\n\n\n\n\n\n\n\n\n\n", + "comments": "", + "x": 2154.0009231567383, + "y": 2027.1228910684586, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "862cb704.9f9128", + "type": "execute", + "name": "execute RestApiCallNode create vpn topology", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-vpn-topology.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/' + $prop.vpn1Id + '/topology'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 746.9997272491455, + "y": 1560.6235390901566, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "9ca71cfd.a9b42", + "e39ed217.1ee0b" + ] + ] + }, + { + "id": "e39ed217.1ee0b", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 990.9996814727783, + "y": 1581.6233559846878, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "bda5dec3.598f2" + ] + ] + }, + { + "id": "bda5dec3.598f2", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1160.999620437622, + "y": 1584.6233559846878, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "d878c3fa.89f44", + "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=\"Error executing Create vpn topology failed\" />\n", + "comments": "", + "x": 1160.9997425079346, + "y": 1540.6233559846878, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "9ca71cfd.a9b42", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 993.9996204376221, + "y": 1540.6233559846878, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "d878c3fa.89f44" + ] + ] + }, + { + "id": "1627716.a22478f", + "type": "set", + "name": "set controller data", + "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n", + "comments": "", + "x": 1109.5652923583984, + "y": 935.2990293502808, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "2406d281.b1df1e", + "type": "get-resource", + "name": "get-resource esr-thirdparty-sdnc", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n", + "comments": "", + "outputs": 1, + "x": 706.0650634765625, + "y": 961.2993497848511, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "cc3f42f.1aaf5c", + "2581bcc6.214074", + "bc3b824e.981ad" + ] + ] + }, + { + "id": "cc3f42f.1aaf5c", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 944.0651664733887, + "y": 935.2989978790283, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "1627716.a22478f" + ] + ] + }, + { + "id": "2581bcc6.214074", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 940.5559043884277, + "y": 971.8731408119202, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "5dde6a53.1070f4" + ] + ] + }, + { + "id": "bc3b824e.981ad", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 934.8889579772949, + "y": 1008.2064542770386, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "e1a59b7f.54e028" + ] + ] + }, + { + "id": "5dde6a53.1070f4", + "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1097.1273345947266, + "y": 971.1588926315308, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "e1a59b7f.54e028", + "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1096.6615295410156, + "y": 1003.6456785202026, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "873845fc.6f6098", + "type": "for", + "name": "for pnidx.. mdsal-psd.service-data.networks.network_length[]", + "xml": "<for index='pnidx' start='0' end='`$mdsal-parentsd.service-data.networks.network_length`' >\n", + "comments": "", + "outputs": 1, + "x": 2039.4972763061523, + "y": 1270.122277855873, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "d2c7de71.be999" + ] + ] + }, + { + "id": "442e3eb2.30a6", + "type": "switchNode", + "name": "switch ActivateSDWANConnectivityInstance", + "xml": "<switch test=\"`$mdsal-parentsd.service-data.networks.network[$pnidx].network-data.request-information.request-action == ActivateSDWANConnectivityInstance`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 1886.165672302246, + "y": 1359.1222940683365, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "202c0d34.0eeba2" + ] + ] + }, + { + "id": "202c0d34.0eeba2", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2142.1651248931885, + "y": 1357.1222330331802, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "d6c2bdb0.f6742" + ] + ] + }, + { + "id": "ecaeb85c.a23ad8", + "type": "for", + "name": "for loop paramidx - Get topology from servicedata", + "xml": "<for index=\"paramidx\" start=\"0\" end=\"`$mdsal-parentsd.service-data.networks.network[$pnidx].network-data.network-request-input.network-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 1929.1637878417969, + "y": 1450.1214720010757, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "55fb20e6.ae2b8" + ] + ] + }, + { + "id": "275c933d.3e84dc", + "type": "switchNode", + "name": "switch topology", + "xml": "<switch test=\"`$mdsal-psd.service-data.networks.network[$pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].name == 'topology'`\">\n", + "comments": "", + "outputs": 1, + "x": 2383.1641483306885, + "y": 1437.121761918068, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "3594c1ef.8c09de" + ] + ] + }, + { + "id": "3594c1ef.8c09de", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2532.1639041900635, + "y": 1432.1218839883804, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "d0fec186.f6378" + ] + ] + }, + { + "id": "d0fec186.f6378", + "type": "set", + "name": "set topology", + "xml": "<set>\n<parameter name='prop.topology' value='`$mdsal-psd.service-data.networks.network[$pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].value`' />\n", + "comments": "", + "x": 2672.1640911102295, + "y": 1429.721799492836, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "d8436e7b.788fa", + "type": "switchNode", + "name": "switch vpnId", + "xml": "<switch test=\"`$mdsal-psd.service-data.networks.network[$pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].name == 'vpn-id'`\">\n", + "comments": "", + "outputs": 1, + "x": 2370.8300952911377, + "y": 1475.454986691475, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "ef5a8550.4c3fc8" + ] + ] + }, + { + "id": "ef5a8550.4c3fc8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2510.8300380706787, + "y": 1475.454803109169, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "ff006bb3.c58668" + ] + ] + }, + { + "id": "ff006bb3.c58668", + "type": "set", + "name": "set prop.vpn1Id", + "xml": "<set>\n<parameter name='prop.vpn1Id' value='`$mdsal-parentsd.service-data.networks.network[$pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].value`' />\n", + "comments": "", + "x": 2658.830041885376, + "y": 1475.054870724678, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "4e50db83.d2f224", + "type": "execute", + "name": "execute RestApiCallNode create vpn ", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-vpn.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/vpn'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 715.9981231689453, + "y": 1469.1229600906372, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "22758979.541926", + "97cd05b9.e37ec8" + ] + ] + }, + { + "id": "97cd05b9.e37ec8", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 935.998025894165, + "y": 1465.1229249238968, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "a647eec3.a66d4" + ] + ] + }, + { + "id": "a647eec3.a66d4", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1105.9979648590088, + "y": 1468.1229249238968, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "8979ecea.209cb", + "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=\"Error executing Create vpn failed\" />\n", + "comments": "", + "x": 1105.9980869293213, + "y": 1424.1229249238968, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "22758979.541926", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 938.9979648590088, + "y": 1424.1229249238968, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "8979ecea.209cb" + ] + ] + }, + { + "id": "165fa503.fcc5db", + "type": "set", + "name": "set prop.name", + "xml": "<set>\n<parameter name='prop.name' value='`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$aridx].value`' />\n", + "comments": "", + "x": 2515.9968280792236, + "y": 1064.1214628219604, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "5a9c41c6.077e", + "type": "switchNode", + "name": "switch sdwanVpnName", + "xml": "<switch test=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$aridx].name == 'sdwanVpnName'`\">\n", + "comments": "", + "outputs": 1, + "x": 2195.4965839385986, + "y": 1069.1214628219604, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "a0b6a8bd.407c18" + ] + ] + }, + { + "id": "a0b6a8bd.407c18", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2372.4968280792236, + "y": 1066.1214628219604, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "165fa503.fcc5db" + ] + ] + }, + { + "id": "e752b141.db3aa", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1285.0269775390625, + "y": 887.3190307617188, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "1f1e2af2.8cbfa5", + "7752d7f6.af8778", + "ccfd4281.11f42" + ] + ] + }, + { + "id": "6a1b7e4b.2ba26", + "type": "for", + "name": "for pidx..mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource[]", + "xml": "<for index='pidx' start='0' end='`$mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource_length`' >\n", + "comments": "", + "outputs": 1, + "x": 878.18115234375, + "y": 896.0944213867188, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "e752b141.db3aa" + ] + ] + }, + { + "id": "7752d7f6.af8778", + "type": "execute", + "name": "generate tmp.ar-url-connection url", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"`$prop.restapi.connection-attachment-allottedresource`\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url-connection\"/>\n <parameter name=\"target\" value=\"{allotted-resource-id}\"/>\n <parameter name=\"replacement\" value=\"`$prop.ar.provided-allotted-resource-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 1533.9962997436523, + "y": 885.6668090820312, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "ccfd4281.11f42", + "type": "execute", + "name": "execute RestApiCallNode - get-resource connection-attachment-allotted-resource", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-connection`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-providedAr\" />\n\n", + "comments": "", + "outputs": 1, + "x": 1682.99609375, + "y": 924.3333740234375, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "d6f3b7ed.897558", + "fc107783.f66638" + ] + ] + }, + { + "id": "eed01b55.d04f18", + "type": "execute", + "name": "generate prop.ar-parent-service-instance-id", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"/restconf/config/GENERIC-RESOURCE-API:services/service/{service-instance-id}/service-data\"/> \n <parameter name=\"outputPath\" value=\"tmp.ar-url-connection\"/>\n <parameter name=\"target\" value=\"{service-instance-id}\"/>\n <parameter name=\"replacement\" value=\"`$prop.ar-parent-service-instance-id`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 1713.3295593261719, + "y": 1133.0003362894058, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "48c9897c.fcd5b8", + "type": "execute", + "name": "execute RestApiCallNode - get parent service data", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-connection`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-parentsd\" />\n\n", + "comments": "", + "outputs": 1, + "x": 1732.3295288085938, + "y": 1167.0004221200943, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "6d849909.165408", + "96905d4d.266e3" + ] + ] + }, + { + "id": "4483e9ee.7ffd68", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1992.0272235870361, + "y": 1043.5311307907104, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "c5da2f8.eb203d", + "5a9c41c6.077e" + ] + ] + }, + { + "id": "d6c2bdb0.f6742", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1518.0277786254883, + "y": 1490.5313215255737, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "ecaeb85c.a23ad8", + "c5c238a2.297c08", + "ce3038ec.f99258", + "7a9df6e2.06b738" + ] + ] + }, + { + "id": "d2c7de71.be999", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1628.6634063720703, + "y": 1357.667093873024, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "442e3eb2.30a6" + ] + ] + }, + { + "id": "b6197b80.43b5b8", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1853.9984703063965, + "y": 1894.667660355568, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "dbd732d1.3a3c8" + ] + ] + }, + { + "id": "55fb20e6.ae2b8", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2215.027723312378, + "y": 1450.5314317941666, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "275c933d.3e84dc", + "d8436e7b.788fa" + ] + ] + }, + { + "id": "f593f6af.001438", + "type": "set", + "name": "set prop.attach.siteId", + "xml": "<set>\n<parameter name='prop.attach.siteId' value='`$mdsal-sd.service-data.vnfs.vnf[$tmp.sitevidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$siteidx].value`' />\n\n", + "comments": "", + "x": 2106.665012359619, + "y": 1968.3338705301285, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "a89b6820.3b89d8", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2286.255527496338, + "y": 1749.00441801548, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "8d253099.60ab9", + "615b5e26.43cbe" + ] + ] + }, + { + "id": "7763b485.9a224c", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1909.755947113037, + "y": 1994.754342675209, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "f593f6af.001438", + "ae878fc7.06ea3", + "b4fdd461.f71598" + ] + ] + }, + { + "id": "fb5be39e.fa586", + "type": "call", + "name": "call sdwan-wanport-vnf-topology-operation-underlay", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-wanport-vnf-topology-operation-underlay' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 765.7540149688721, + "y": 1677.254198551178, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "676ca60b.f8dc58", + "type": "comment", + "name": "underlay", + "info": "1. Get consumed AR from service data\n2. for all the AR id's get the respective AR from MDSAL\n3. From MDSAL AR get parent service instance ID\n4. Get service data based in parent service instance ID to get parent service. i.e, SDWAN Infra service\n5. Get SDWAN connectivity from looping network and check for topology\n6. from parent service data get siteAttachInstance vnf and check the role\n7. from parent service data get wanportINstance vnf and check the transportNetworkName\n8. Get provided AR from the parent service data\n9. for each of the provided ARid get the AR from MDSAL\n10.in the AR check for hub\n\n", + "comments": "", + "x": 673.722993850708, + "y": 1642.2231373786926, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "7ad41615.6876c8", + "type": "set", + "name": "set prop.siteAttachement_length=0", + "xml": "<set>\n<parameter name='prop.siteAttachements_length' value='0' />\n<parameter name='prop.siteIds_length' value='0' />\n\n\n\n", + "comments": "", + "x": 714.9999694824219, + "y": 861.5311733484268, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "c5c238a2.297c08", + "type": "set", + "name": "set prop.ar-service-instance-id", + "xml": "<set>\n<parameter name='prop.ar-service-instance-id' value='`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.connection-attachment-topology.allotted-resource-identifiers.consuming-service-instance-id`' />\n", + "comments": "", + "x": 1878.0003967285156, + "y": 1488.531231880188, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "ce3038ec.f99258", + "type": "execute", + "name": "generate prop.ar-service-instance-id", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"/restconf/config/GENERIC-RESOURCE-API:services/service/{service-instance-id}/service-data\"/> \n <parameter name=\"outputPath\" value=\"tmp.ar-url-connection\"/>\n <parameter name=\"target\" value=\"{service-instance-id}\"/>\n <parameter name=\"replacement\" value=\"`$prop.ar-service-instance-id`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 1888.3326683044434, + "y": 1529.4093770980835, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "7a9df6e2.06b738", + "type": "execute", + "name": "execute RestApiCallNode - get service data", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-connection`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-sd\" />\n\n", + "comments": "", + "outputs": 1, + "x": 1917.3327331542969, + "y": 1570.4093770980835, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "c31f95da.b397b8", + "e9b63d90.66cfc" + ] + ] + }, + { + "id": "c31f95da.b397b8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2173.8524169921875, + "y": 1579.5972105264664, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "7eac2788.499098" + ] + ] + }, + { + "id": "e9b63d90.66cfc", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 2176.000087738037, + "y": 1618.5310827493668, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "a04199d9.f1d158" + ] + ] + }, + { + "id": "7eac2788.499098", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2303.5006103515625, + "y": 1573.0311704874039, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "a04199d9.f1d158", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1651.9998779296875, + "y": 1669.5311304330826, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "69edf94d.eac048" + ] + ] + }, + { + "id": "816baab6.7483d8", + "type": "comment", + "name": "TODO send Email", + "info": "", + "comments": "", + "x": 1015.0000171661377, + "y": 1722.031527042389, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "b4fdd461.f71598", + "type": "set", + "name": "Add site attachement to list and update length", + "xml": "<set>\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].siteId' value='`$prop.attach.siteId`' />\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles[0]' value='`$prop.role`' />\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles_length' value='1' />\n<parameter name='prop.siteAttachements_length' value='`$prop.siteAttachements_length + 1`' />\n\n\n\n\n\n\n\n\n\n\n\n\n", + "comments": "", + "x": 2189.250045776367, + "y": 2081.753987789154, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "28b00a13.902c76", + "type": "execute", + "name": "execute RestApiCallNode Get token", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>", + "comments": "", + "outputs": 1, + "x": 703.0038986206055, + "y": 1079.0041399002075, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "100f91ad.a8ab3e", + "b78fb1a0.9e74" + ] + ] + }, + { + "id": "100f91ad.a8ab3e", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 955.0040245056152, + "y": 1060.003957748413, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "6b800958.b222d8" + ] + ] + }, + { + "id": "b78fb1a0.9e74", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 947.2540588378906, + "y": 1095.6470804214478, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "eaf6ab13.cd7508" + ] + ] + }, + { + "id": "eaf6ab13.cd7508", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1095.004051208496, + "y": 1093.3972024917603, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "6b800958.b222d8", + "type": "set", + "name": "set token-id", + "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n", + "comments": "", + "x": 1104.0040245056152, + "y": 1059.003927230835, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "9a0f8d9a.4d443", + "type": "get-resource", + "name": "get-resource service-subscription", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"service-subscription\" \n key= 'service-subscription.service-type = $connection-attachment-topology-operation-input.service-information.subscription-service-type \n AND customer.global-customer-id = $connection-attachment-topology-operation-input.service-information.global-customer-id'\n force=\"true\" pfx=\"tmp.AnAI-data-tenant\"> ", + "comments": "", + "outputs": 1, + "x": 693.8993682861328, + "y": 1191.5660381317139, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "47c8d5a9.ba16bc", + "14ed09d9.573ea6" + ] + ] + }, + { + "id": "20fab7f5.802688", + "type": "switchNode", + "name": "switch temp-ub-sub-account-id", + "xml": "<switch test='`$tmp.AnAI-data-tenant.temp-ub-sub-account-id`'>\n", + "comments": "", + "outputs": 1, + "x": 1105.8994598388672, + "y": 1156.3161191940308, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "f88ee31d.81b4", + "2987815d.d473be" + ] + ] + }, + { + "id": "f88ee31d.81b4", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 1298.6139106750488, + "y": 1130.3161602020264, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "679b7c09.467594" + ] + ] + }, + { + "id": "2987815d.d473be", + "type": "other", + "name": "Other", + "xml": "<outcome value='Other'>", + "comments": "", + "outputs": 1, + "x": 1251.8994903564453, + "y": 1224.3162384033203, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "fba55779.a815d8" + ] + ] + }, + { + "id": "47c8d5a9.ba16bc", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 904.3992309570312, + "y": 1164.3120965957642, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "20fab7f5.802688" + ] + ] + }, + { + "id": "14ed09d9.573ea6", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 898.0778198242188, + "y": 1216.5264081954956, + "z": "92c42fbf.4d20f", + "wires": [ + [ + "51559d2e.77fa84" + ] + ] + }, + { + "id": "51559d2e.77fa84", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1050.8278198242188, + "y": 1216.2764692306519, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "fba55779.a815d8", + "type": "set", + "name": "set prop.tenant-id", + "xml": "<set>\n<parameter name='prop.tenant-id' value='`$tmp.AnAI-data-tenant.temp-ub-sub-account-id`' />\n", + "comments": "", + "x": 1420.7566719055176, + "y": 1222.423252105713, + "z": "92c42fbf.4d20f", + "wires": [] + }, + { + "id": "f9894d64.11723", + "type": "execute", + "name": "execute RestApiCallNode Create tenant auth", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/baseservice/tenants/authorization/' + $prop.tenant-id`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"tenant-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.openecomp.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 731.3994293212891, + "y": 1258.4588842391968, + "z": "92c42fbf.4d20f", + "wires": [ + [] + ] + }, + { + "id": "679b7c09.467594", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1411.042236328125, + "y": 1175.1375246047974, + "z": "92c42fbf.4d20f", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-create.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-create.json new file mode 100644 index 00000000..bd279399 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-create.json @@ -0,0 +1,1305 @@ +[ + { + "id": "ad2ef973.e6a378", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 131, + "y": 55, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "151183ce.27c78c" + ] + ] + }, + { + "id": "151183ce.27c78c", + "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": 314.00000381469727, + "y": 129.000018119812, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "89afc74f.956348" + ] + ] + }, + { + "id": "89afc74f.956348", + "type": "method", + "name": "sdwan-attachment-topology-operation-create", + "xml": "<method rpc='sdwan-attachment-topology-operation-create' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 302.0001220703125, + "y": 217.00000095367432, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "580de8c5.e06e78" + ] + ] + }, + { + "id": "580de8c5.e06e78", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 222.00005340576172, + "y": 966.0002489089966, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "1fbb291d.155017", + "f8c6b86f.980db8", + "655b6d38.675514", + "87b8ca30.cf86e8", + "3718c342.00f4ac", + "3fc33b48.8d6bf4", + "15c0d821.288668", + "99b25b64.985da8", + "cc1d8a7e.c8e908", + "aec371b2.f4eb6", + "7c0d6a4c.141ba4", + "605ed84a.e90ef8", + "cf809c65.e205f", + "5ffc39de.e33178", + "b70e6d89.61807", + "2fe0bf35.0314b", + "4b90a515.ea737c", + "30825693.105b0a", + "a79587b.c624178", + "9d0211a4.58ce8", + "5c590a79.9e0264", + "adeabb6e.cf7758", + "7ee858c0.930c58" + ] + ] + }, + { + "id": "74beb7.011b0148", + "type": "comment", + "name": "Set allotted resource id if not sent by SO", + "info": "", + "comments": "", + "x": 706.0767517089844, + "y": 126.43391990661621, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "1fbb291d.155017", + "type": "switchNode", + "name": "switch allotted-resource-id", + "xml": "<switch test='`$connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-id`'>\n", + "comments": "", + "outputs": 1, + "x": 652.0000305175781, + "y": 181.99999332427979, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "4a85a033.b553c", + "de2e876a.0ba078" + ] + ] + }, + { + "id": "4a85a033.b553c", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 850.0001182556152, + "y": 151.999981880188, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "63eb9d84.765954" + ] + ] + }, + { + "id": "de2e876a.0ba078", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 849.0000267028809, + "y": 188.99999237060547, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "eef884cd.26a128" + ] + ] + }, + { + "id": "eef884cd.26a128", + "type": "set", + "name": "set tmp.ar.allotted-resource-id", + "xml": "<set>\n<parameter name='tmp.ar.allotted-resource-id' value='`$connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-id`' />\n", + "comments": "", + "x": 1047.000015258789, + "y": 186.0000114440918, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "f8c6b86f.980db8", + "type": "set", + "name": "set tmp.ar.self-link", + "xml": "<set>\n<parameter name='tmp.ar.self-link' value=\"`'restconf/config/GENERIC-RESOURCE-API:connection-attachment-allotted-resources/connection-attachment-allotted-resource/'\n + $tmp.ar.allotted-resource-id\n + '/allotted-resource-data/connection-attachment-topology/'` \" />\n\n", + "comments": "", + "x": 619.9999542236328, + "y": 403.0001001358032, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "655b6d38.675514", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 620.2618713378906, + "y": 484.6667814254761, + "z": "77e7049e.a5a37c", + "wires": [ + [] + ] + }, + { + "id": "87b8ca30.cf86e8", + "type": "execute", + "name": "generate allotted-resource tmp.ar-url", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"`$prop.restapi.connection-attachment-allottedresource`\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url\"/>\n <parameter name=\"target\" value=\"{allotted-resource-id}\"/>\n <parameter name=\"replacement\" value=\"`$tmp.ar.allotted-resource-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 673.2619323730469, + "y": 571.6666994094849, + "z": "77e7049e.a5a37c", + "wires": [ + [] + ] + }, + { + "id": "63eb9d84.765954", + "type": "execute", + "name": "execute tmp.ar.allotted-resource-id", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='generateUUID' >\n<parameter name=\"ctx-destination\" value=\"tmp.ar.allotted-resource-id\"/>\n", + "comments": "", + "outputs": 1, + "x": 1065.0000953674316, + "y": 152.9999876022339, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "7fcc0333.e4b76c" + ] + ] + }, + { + "id": "7fcc0333.e4b76c", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1283.0001373291016, + "y": 152.99995136260986, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "dc8faa82.0a80d8" + ] + ] + }, + { + "id": "dc8faa82.0a80d8", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n<parameter name='error-code' value='' />\n<parameter name='error-message' value=\"An error occured while generation allotted resource ID\" />\n", + "comments": "", + "x": 1449.0000915527344, + "y": 152.9999656677246, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "83948a24.3af768", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1179.0002307891846, + "y": 643.7778720855713, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "64a66d0e.2cab24" + ] + ] + }, + { + "id": "fd6c452f.f52a18", + "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=\"Error: Existing connection attachment allotted resource\" />\n \n", + "comments": "", + "x": 1912.5186100006104, + "y": 644.8439435958862, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "df1c313d.a9cf4", + "type": "comment", + "name": "Check for non existence of allotted resource", + "info": "", + "comments": "", + "x": 1035.0001525878906, + "y": 577.7779388427734, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "3c6b3ac8.5f54b6", + "type": "for", + "name": "for cidx..service-data.consumed-allotted-resources.consumed-allotted-resource[]", + "xml": "<for index='cidx' start='0' end='`$service-data.consumed-allotted-resources.consumed-allotted-resource_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1555.6666984558105, + "y": 788.0000512599945, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "e0e0a661.74b9e8" + ] + ] + }, + { + "id": "3fc33b48.8d6bf4", + "type": "switchNode", + "name": "switch service-data.consumed-allotted-resources_length", + "xml": "<switch test='`$service-data.consumed-allotted-resources.consumed-allotted-resource_length`'>\n", + "comments": "", + "outputs": 1, + "x": 737.6660232543945, + "y": 764.7140836715698, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "98246edb.9d503", + "303d6837.0384d8" + ] + ] + }, + { + "id": "98246edb.9d503", + "type": "other", + "name": "outcome Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1041.8089218139648, + "y": 733.5715208053589, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "1bc15eed.fd45b1" + ] + ] + }, + { + "id": "303d6837.0384d8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1018.8089714050293, + "y": 794.571475982666, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "b930de42.50a21" + ] + ] + }, + { + "id": "b930de42.50a21", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1178.9360618591309, + "y": 792.697452545166, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "3c6b3ac8.5f54b6", + "7d532296.0d9bfc", + "6dd5cf93.f0258" + ] + ] + }, + { + "id": "1bc15eed.fd45b1", + "type": "set", + "name": "set cidx", + "xml": "<set>\n<parameter name='tmp.cidx' value=\"`0`\" />\n<parameter name='service-data.consumed-allotted-resources.consumed-allotted-resource_length' value=\"1\" />\n\n\n", + "comments": "", + "x": 1191.6659049987793, + "y": 731.2855710983276, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "15c0d821.288668", + "type": "set", + "name": "set consumed allotted resources", + "xml": "<set>\n<parameter name='service-data.consumed-allotted-resources.consumed-allotted-resource[$tmp.cidx].allotted-resource-id' value=\"`$tmp.ar.allotted-resource-id` \" />\n<parameter name='service-data.consumed-allotted-resources.consumed-allotted-resource[$tmp.cidx].allotted-resource-type' value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-type` \" />\n<parameter name='service-data.consumed-allotted-resources.consumed-allotted-resource[$tmp.cidx].allotted-resource-pointer' value=\"`$tmp.ar.self-link` \" />\n<parameter name='service-data.consumed-allotted-resources.consumed-allotted-resource_length' value='`$tmp.cidx + 1`' />\n\n", + "comments": "", + "x": 666.5233154296875, + "y": 868.2856483459473, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "7d532296.0d9bfc", + "type": "switchNode", + "name": "switch tmp.found-cidx", + "xml": "<switch test='`$tmp.found-cidx`'>\n", + "comments": "", + "outputs": 1, + "x": 1368.0511093139648, + "y": 824.708975315094, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "106270aa.e9c6ff" + ] + ] + }, + { + "id": "106270aa.e9c6ff", + "type": "outcomeTrue", + "name": "false", + "xml": "<outcome value='false'>\n", + "comments": "", + "outputs": 1, + "x": 1558.0510635375977, + "y": 824.7089123725891, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "e1144596.6d5ba8" + ] + ] + }, + { + "id": "e1144596.6d5ba8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1724.0510635375977, + "y": 824.7089123725891, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "b93f3869.6459e8" + ] + ] + }, + { + "id": "e0e0a661.74b9e8", + "type": "switchNode", + "name": "switch allotted-resource-id", + "xml": "<switch test=\"`$service-data.consumed-allotted-resources.consumed-allotted-resource[$cidx].allotted-resource-id == $tmp.ar.allotted-resource-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1972.7783279418945, + "y": 785.000078201294, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "326d00a0.76b6c" + ] + ] + }, + { + "id": "326d00a0.76b6c", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2154.587902069092, + "y": 785.4645252227783, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "cec76fbc.ec734" + ] + ] + }, + { + "id": "b93f3869.6459e8", + "type": "set", + "name": "set tmp.cidx", + "xml": "<set>\n<parameter name='tmp.cidx' value='`$service-data.consumed-allotted-resources.consumed-allotted-resource_length`' />\n", + "comments": "", + "x": 1885.924446105957, + "y": 824.2206134796143, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "9dc9afd9.071d8", + "type": "comment", + "name": "Add to consumed service consumed-allotted-resources in mdsal", + "info": "Prepare data and add to service-data", + "comments": "", + "x": 758.667236328125, + "y": 695.0000476837158, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "79d72e28.e5bf", + "type": "comment", + "name": "This set resource will be added to MDSAL by provider code", + "info": "Below we add to service-data.consumed-allotted-resource at last index", + "comments": "", + "x": 746.0001525878906, + "y": 833.7781400680542, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "7ee858c0.930c58", + "type": "update", + "name": "save AAI allotted-resource", + "xml": "<save plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"allotted-resource\" \n\t\tkey=\"customer.global-customer-id = $connection-attachment-topology-operation-input.service-information.global-customer-id AND\n\t\t\tservice-subscription.service-type = $connection-attachment-topology-operation-input.service-information.subscription-service-type AND\n\t\t\tservice-instance.service-instance-id = $connection-attachment-topology-operation-input.service-information.service-instance-id AND\n\t\t\tallotted-resource.id = $tmp.ar.allotted-resource-id\"\n pfx='pfx' local-only='false' force='false'>\n <parameter name=\"id\" value=\"`$tmp.ar.allotted-resource-id`\" />\n\t<parameter name=\"role\" value=\"`$prop.connection-attachment.role`\" />\t\n <parameter name=\"vpn-name\" value=\"`$prop.connection-attachment.sdwanVpnName`\" />\n\t<parameter name=\"selflink\" value=\"`$tmp.ar.self-link`\" />\n\t<parameter name=\"model-invariant-id\" value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.onap-model-information.model-invariant-uuid`\" />\n\t<parameter name=\"model-version-id\" value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.onap-model-information.model-uuid`\" />\n\t<parameter name=\"operational-status\" value=\"Created\" />\n", + "comments": "", + "outputs": 1, + "x": 656.6908569335938, + "y": 1793.531904220581, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "54e2f563.b3af5c", + "291816ed.18393a" + ] + ] + }, + { + "id": "54e2f563.b3af5c", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 851.4527931213379, + "y": 1784.4845056533813, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "a3778d99.3c015" + ] + ] + }, + { + "id": "a3778d99.3c015", + "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=\"AAI failed\" />\n", + "comments": "", + "x": 1017.9766731262207, + "y": 1796.1035766601562, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "291816ed.18393a", + "type": "failure", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 858.5480804443359, + "y": 1817.246473312378, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "a3778d99.3c015" + ] + ] + }, + { + "id": "ac365c56.4b2", + "type": "comment", + "name": "Save Resource to AAI", + "info": "", + "comments": "", + "x": 690.5005340576172, + "y": 1761.833875656128, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "81ef7e04.cd917", + "type": "comment", + "name": "Set allotted resource type if not sent by SO", + "info": "", + "comments": "", + "x": 692, + "y": 235.00000095367432, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "3718c342.00f4ac", + "type": "switchNode", + "name": "switch allotted-resource-type", + "xml": "<switch test='`$connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-type`'>\n", + "comments": "", + "outputs": 1, + "x": 653.9233093261719, + "y": 275.5660572052002, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "64aa0e9c.b1d09", + "7800ea8d.a7f124" + ] + ] + }, + { + "id": "64aa0e9c.b1d09", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 856.9234619140625, + "y": 260.56606006622314, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "f530af4a.706e5" + ] + ] + }, + { + "id": "7800ea8d.a7f124", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 849.9232902526855, + "y": 300.5660800933838, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "7a986711.0ca2d8" + ] + ] + }, + { + "id": "7a986711.0ca2d8", + "type": "set", + "name": "set tmp.ar.allotted-resource-type", + "xml": "<set>\n<parameter name='tmp.ar.allotted-resource-type' value='`$connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-type`' />\n", + "comments": "", + "x": 1081.9232749938965, + "y": 300.56608486175537, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "369cb772.706cb8", + "type": "comment", + "name": "For storage in AAI connection-attachment-topology", + "info": "", + "comments": "", + "x": 716.9999618530273, + "y": 370.0000009536743, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "492255d4.2adf4c", + "type": "comment", + "name": "Obtain different URL, template location etc", + "info": "For saving resource information to MDSAL & for AAI", + "comments": "", + "x": 691.9999465942383, + "y": 451.8889102935791, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "ddea3893.c96cd8", + "type": "comment", + "name": "Used for Put AR by id to MDSAL", + "info": "", + "comments": "", + "x": 658.0000305175781, + "y": 540.8889274597168, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "a440e95e.3176f8", + "type": "comment", + "name": "Obtain the last index in services", + "info": "ServiceData is added by Provider code", + "comments": "", + "x": 659.4444732666016, + "y": 726.8888721466064, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "a79587b.c624178", + "type": "set", + "name": "set output to api handler", + "xml": "<set>\n<parameter name='allotted-resource-id' value='`$tmp.ar.allotted-resource-id`' />\n<parameter name='connection-attachment-object-path' value=\"`$tmp.ar.self-link`\"/>\n<parameter name='service-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $connection-attachment-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'`\"/>\n \n", + "comments": "", + "x": 642.2681427001953, + "y": 1700.359203338623, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "9d0211a4.58ce8", + "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": 610.6812286376953, + "y": 1862.9749298095703, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "f530af4a.706e5", + "type": "set", + "name": "set tmp.ar.allotted-resource-type", + "xml": "<set>\n<parameter name='tmp.ar.allotted-resource-type' value=\"SDWANAttachmentInstance\" />\n", + "comments": "", + "x": 1096.0001487731934, + "y": 260.99998664855957, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "30825693.105b0a", + "type": "execute", + "name": "execute RestApiCallNode - PUT AR by id", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='templateFileName' value=\"`$prop.restapi.templateDir + '/' + $prop.restapi.sdwan-attachment.templatefile`\" />\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='PUT' />\n <parameter name=\"responsePrefix\" value=\"mdsal-ar\" />\n\n", + "comments": "", + "outputs": 1, + "x": 693.0002746582031, + "y": 1634.00013256073, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "7725804e.b7ea", + "ff126c78.d9f65", + "34ce7aa1.c96186" + ] + ] + }, + { + "id": "7725804e.b7ea", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 942.6416282653809, + "y": 1672.3314628601074, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "d7cd6db2.d2286" + ] + ] + }, + { + "id": "ff126c78.d9f65", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 933.6416778564453, + "y": 1640.831488609314, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "d7cd6db2.d2286" + ] + ] + }, + { + "id": "34ce7aa1.c96186", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 937.391716003418, + "y": 1611.1885934844613, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "6ccc24c6.03b4dc" + ] + ] + }, + { + "id": "d7cd6db2.d2286", + "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=\"Error updating md-sal for connection-attachment-allotted-resource\" />\n", + "comments": "", + "x": 1103.391716003418, + "y": 1641.5815124511719, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "6ccc24c6.03b4dc", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1079.0476837158203, + "y": 1607.3807626739144, + "z": "77e7049e.a5a37c", + "wires": [ + [] + ] + }, + { + "id": "7c0d6a4c.141ba4", + "type": "execute", + "name": "execute RestApiCallNode - Update parent provided service AR", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='templateFileName' value=\"`$prop.restapi.templateDir + '/' + $prop.restapi.parentsvc.templatefile`\" />\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.parent-ar-url`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='PUT' />\n <parameter name=\"responsePrefix\" value=\"parent\" />\n\n", + "comments": "", + "outputs": 1, + "x": 757.9999542236328, + "y": 1150.000165939331, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "494a716e.866ba", + "227c3021.44dc4", + "ff8b452c.8d9bc8" + ] + ] + }, + { + "id": "494a716e.866ba", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 1066.3080139160156, + "y": 1181.998441696167, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "aaeb645f.80fed8" + ] + ] + }, + { + "id": "227c3021.44dc4", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1057.30806350708, + "y": 1150.4984674453735, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "aaeb645f.80fed8" + ] + ] + }, + { + "id": "ff8b452c.8d9bc8", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1061.0581016540527, + "y": 1120.8555723205209, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "74f3a310.0128fc" + ] + ] + }, + { + "id": "aaeb645f.80fed8", + "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=\"Error updating md-sal for connection-attachment-allotted-resource\" />\n", + "comments": "", + "x": 1227.0581016540527, + "y": 1151.2484912872314, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "74f3a310.0128fc", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1202.714069366455, + "y": 1117.047741509974, + "z": "77e7049e.a5a37c", + "wires": [ + [] + ] + }, + { + "id": "9405156b.c649a8", + "type": "comment", + "name": "Put the parent allotted resource in mdsal", + "info": "", + "comments": "", + "x": 686.9999008178711, + "y": 1112.000072479248, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "cf809c65.e205f", + "type": "set", + "name": "set connection-attachment-ar-identifiers", + "xml": "<set>\n<parameter name='connection-attachment-ar-identifiers.consuming-service-instance-id' value=\"`$connection-attachment-topology-operation-input.service-information.service-instance-id` \" />\n<parameter name='connection-attachment-ar-identifiers.parent-service-instance-id' value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.parent-service-instance-id` \" />\n<parameter name='connection-attachment-ar-identifiers.allotted-resource-type' value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-type` \" />\n<parameter name='connection-attachment-ar-identifiers.allotted-resource-id' value=\"`$tmp.ar.allotted-resource-id` \" />\n\n", + "comments": "", + "x": 683.3570861816406, + "y": 1314.5716915130615, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "605ed84a.e90ef8", + "type": "set", + "name": "set ar-data", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-id' value=\"`$tmp.ar.allotted-resource-id` \" />\n<parameter name='connection-attachment-ar.allotted-resource-status.action' value=\"`$connection-attachment-topology-operation-input.request-information.request-action` \" />\n<parameter name='connection-attachment-ar.allotted-resource-status.rpc-name' value=\"connection-attachment-topology-operation\" />\n<parameter name='connection-attachment-ar.allotted-resource-status.rpc-action' value=\"`$connection-attachment-topology-operation-input.sdnc-request-header.svc-action` \" />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.request-information.' value=\"`$connection-attachment-topology-operation-input.request-information.` \" />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.sdnc-request-header.' value=\"`$connection-attachment-topology-operation-input.sdnc-request-header.` \" />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.service-information.' value=\"`$connection-attachment-topology-operation-input.service-information.` \" />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.allotted-resource-information.' value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.` \" />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.' value=\"`$connection-attachment-topology-operation-input.connection-attachment-request-input.` \" />", + "comments": "", + "x": 603.2139129638672, + "y": 1282.381194114685, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "5ffc39de.e33178", + "type": "set", + "name": "set identifiers in overall structure", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-data.connection-attachment-topology.allotted-resource-identifiers.' \nvalue=\"`$connection-attachment-ar-identifiers.`\" />\n\n\n", + "comments": "", + "x": 662.1668853759766, + "y": 1348.6668767929077, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "b70e6d89.61807", + "type": "execute", + "name": "execute getTime", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='setTime' >\n <parameter name=\"outputPath\" value=\"tmp.current-time\" />\n\n", + "comments": "", + "outputs": 1, + "x": 614.4997253417969, + "y": 1422.0004043579102, + "z": "77e7049e.a5a37c", + "wires": [ + [] + ] + }, + { + "id": "2fe0bf35.0314b", + "type": "set", + "name": "set allotted-resource-oper-status", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.order-status' value='Created' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-action' value='`$connection-attachment-topology-operation-input.request-information.request-action`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-rpc-action' value='`$connection-attachment-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-svc-request-id' value='`$connection-attachment-topology-operation-input.sdnc-request-header.svc-request-id`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.create-timestamp' value='`$tmp.current-time`' />\n", + "comments": "", + "x": 665.4867630004883, + "y": 1477.9516372680664, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "4b90a515.ea737c", + "type": "set", + "name": "set model-data", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-data.connection-attachment-topology.onap-model-information.' value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.onap-model-information.` \" />", + "comments": "", + "x": 610.0553817749023, + "y": 1383.5557622909546, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "a3fd3ef0.9cf2", + "type": "comment", + "name": "Prepare data for allotted-resource addition to MDSAL", + "info": "This will add to allotted-resource which is present inside service.", + "comments": "", + "x": 727.3888702392578, + "y": 1248.5556087493896, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "aec371b2.f4eb6", + "type": "execute", + "name": "generate parent-ar url - replace allotted-resource-id", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"`$tmp.parent-ar-url`\"/>\n <parameter name=\"outputPath\" value=\"tmp.parent-ar-url\"/>\n <parameter name=\"target\" value=\"{allotted-resource-id}\"/>\n <parameter name=\"replacement\" value=\"`$tmp.ar.allotted-resource-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 722.5000152587891, + "y": 1076.0000114440918, + "z": "77e7049e.a5a37c", + "wires": [ + [] + ] + }, + { + "id": "cc1d8a7e.c8e908", + "type": "execute", + "name": "generate parent-ar url - replace service-instance-id", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"`$prop.restapi.parent-provided-resource`\"/>\n <parameter name=\"outputPath\" value=\"tmp.parent-ar-url\"/>\n <parameter name=\"target\" value=\"{service-instance-id}\"/>\n <parameter name=\"replacement\" value=\"`$tmp.ar.parent-service-instance-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 718.4999389648438, + "y": 1033.000147819519, + "z": "77e7049e.a5a37c", + "wires": [ + [] + ] + }, + { + "id": "af622d17.e96e6", + "type": "comment", + "name": "Prepare Parent AR URL", + "info": "Preparation to set provided-allotted-resource in parent service instance", + "comments": "", + "x": 636.5003967285156, + "y": 962.0001010894775, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "99b25b64.985da8", + "type": "set", + "name": "set tmp.ar.parent-service-instance-id", + "xml": "<set>\n<parameter name='tmp.ar.parent-service-instance-id' value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.parent-service-instance-id` \" />\n\n", + "comments": "", + "x": 675.5001907348633, + "y": 995.5000405311584, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "cec76fbc.ec734", + "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=\"Error updating md-sal for connection-attachment-allotted-resource as cosumed allotted resource already exists.\" />\n", + "comments": "", + "x": 2232.7569732666016, + "y": 833.645830154419, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "6dd5cf93.f0258", + "type": "set", + "name": "set tmp.found-cidx", + "xml": "<set>\n<parameter name='tmp.found-cidx' value=\"`false`\" />\n\n\n", + "comments": "", + "x": 1358.6461448669434, + "y": 745.3125731945038, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "fcf58d3f.726c9", + "type": "comment", + "name": "Add to parent services provided-allotted-resources in mdsal", + "info": "", + "comments": "", + "x": 747.2015075683594, + "y": 929.9792575836182, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "edb39741.2151b8", + "type": "comment", + "name": "Add to allotted-resources in mdsal", + "info": "", + "comments": "", + "x": 667.9686965942383, + "y": 1215.9689378738403, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "64a66d0e.2cab24", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1341.000051498413, + "y": 643.2777614593506, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "c5b1dd9f.c626c" + ] + ] + }, + { + "id": "c5b1dd9f.c626c", + "type": "switchNode", + "name": "switch cr length", + "xml": "<switch test='`$mdsal-ar.connection-attachment-allotted-resource_length`'>\n", + "comments": "", + "outputs": 1, + "x": 1528.8574314117432, + "y": 643.8968968391418, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "dea64b0a.33d1a8" + ] + ] + }, + { + "id": "dea64b0a.33d1a8", + "type": "other", + "name": "outcome 1", + "xml": "<outcome value='1'>\n", + "comments": "", + "outputs": 1, + "x": 1728.1905536651611, + "y": 643.896975517273, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "fd6c452f.f52a18" + ] + ] + }, + { + "id": "5c590a79.9e0264", + "type": "execute", + "name": "execute RestApiCallNode - get-resource connection-attachment-allotted-resource", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-ar\" />\n\n", + "comments": "", + "outputs": 1, + "x": 813.0000534057617, + "y": 638.0000371932983, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "83948a24.3af768", + "a688402e.6a3a9" + ] + ] + }, + { + "id": "a688402e.6a3a9", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1181.0000839233398, + "y": 608.0000352859497, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "a6697dc2.ce9f3" + ] + ] + }, + { + "id": "a6697dc2.ce9f3", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1333.0000839233398, + "y": 607.0000352859497, + "z": "77e7049e.a5a37c", + "wires": [ + [] + ] + }, + { + "id": "adeabb6e.cf7758", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 619.0039215087891, + "y": 1553.2500038146973, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "96f36120.1f9af", + "6b505cd5.c78924" + ] + ] + }, + { + "id": "96f36120.1f9af", + "type": "for", + "name": "for each sdwan-get-request-input-param", + "xml": "<for index='i' start='0' end='`$connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param_length`' >\n", + "comments": "", + "outputs": 1, + "x": 954.0041198730469, + "y": 1499.2501260638237, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "7401fe63.179e9" + ] + ] + }, + { + "id": "4e61fb49.c94114", + "type": "comment", + "name": "Required for filling template values", + "info": "This is done because connection-attachment is generic resource and doesn't have specific parameters", + "comments": "", + "x": 976.4486236572266, + "y": 1533.0832867622375, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "d4660c0f.147f3", + "type": "comment", + "name": "Remove VNFC prefix", + "info": "", + "comments": "", + "x": 1037.003963470459, + "y": 1455.6944618225098, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "7401fe63.179e9", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1201.0039672851562, + "y": 1500.6943712234497, + "z": "77e7049e.a5a37c", + "wires": [ + [ + "6a638cf5.ebb554", + "3e399a15.de4336" + ] + ] + }, + { + "id": "50ce4566.040d7c", + "type": "comment", + "name": "Take the parameter names by removing prefix", + "info": "", + "comments": "", + "x": 1469.0038146972656, + "y": 1416.250369310379, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "6a638cf5.ebb554", + "type": "execute", + "name": "execute split parameterName", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$i].name`'/>\n<parameter name=\"regex\" value=\"_\"/>\n<parameter name=\"ctx_memory_result_key\" value=\"param-prefix\"/>\n", + "comments": "", + "outputs": 1, + "x": 1420.0384826660156, + "y": 1451.2294654846191, + "z": "77e7049e.a5a37c", + "wires": [ + [] + ] + }, + { + "id": "3e399a15.de4336", + "type": "set", + "name": "set parameterName", + "xml": "<set>\n<parameter name=\"`connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$i].name`\" value='`$param-prefix[$param-prefix_length -1]`'/>\n", + "comments": "", + "x": 1408.4829559326172, + "y": 1555.2294359207153, + "z": "77e7049e.a5a37c", + "wires": [] + }, + { + "id": "6b505cd5.c78924", + "type": "call", + "name": "call GENERIC-RESOURCE-API:sdwan-get-saved-ar-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-saved-ar-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 995.0039672851562, + "y": 1573.2500658035278, + "z": "77e7049e.a5a37c", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-deactivate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-deactivate.json new file mode 100644 index 00000000..c8e24f55 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-deactivate.json @@ -0,0 +1,2607 @@ +[ + { + "id": "f8331c4a.37167", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 115, + "y": 35, + "z": "7c522092.2b01d", + "wires": [ + [ + "2f57f4b9.7848fc" + ] + ] + }, + { + "id": "2f57f4b9.7848fc", + "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": 299.00000190734863, + "y": 106.00001668930054, + "z": "7c522092.2b01d", + "wires": [ + [ + "606390f2.8a1db" + ] + ] + }, + { + "id": "606390f2.8a1db", + "type": "method", + "name": "sdwan-attachment-topology-operation-deactivate", + "xml": "<method rpc='sdwan-attachment-topology-operation-deactivate' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 287.00012016296387, + "y": 193.99999952316284, + "z": "7c522092.2b01d", + "wires": [ + [ + "4ba95650.840ef8" + ] + ] + }, + { + "id": "4ba95650.840ef8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 303.00012016296387, + "y": 749.000244140625, + "z": "7c522092.2b01d", + "wires": [ + [ + "7bfab5a3.06caac", + "45a84e1e.bdf7b", + "169fcb74.40e255", + "b2e9aacc.581ff8", + "e34f2e02.a4351", + "96bf45ea.f31428", + "ade80637.81d448", + "9fb629bb.9a3648", + "4bdb1ae.9bc94e4", + "85c9e5e0.4b2808", + "321fef32.53b0b", + "57a853e.4687fac", + "c17cdc10.1ceea", + "94474a0.f7cc5b8", + "500ce0c3.5b4ed", + "8054d01.53e0b3", + "9c9d490e.b9a1b8", + "75448c50.567d34", + "965fc969.fd32d8", + "d94628e2.163098", + "b8f3c1af.8a68d", + "5450bfab.9413e", + "d6353ac9.cd8368", + "de426682.23e5b8", + "9c358a1f.148518", + "7e6a4a74.fb8064", + "e6e54d59.f029" + ] + ] + }, + { + "id": "7bfab5a3.06caac", + "type": "set", + "name": "set tmp.ar.allotted-resource-id,etc", + "xml": "<set>\n<parameter name='tmp.ar.allotted-resource-id' value='`$connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-id`' />\n<parameter name='tmp.ar.parent-service-instance-id' value='`$connection-attachment-topology-operation-input.allotted-resource-information.parent-service-instance-id`' />\n\n\n", + "comments": "", + "x": 699.993558883667, + "y": 147.99348640441895, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "af7814ef.59e2e8", + "type": "comment", + "name": "set tmp ar-id to fetch resource from MDSAL", + "info": "", + "comments": "", + "x": 728.9538707733154, + "y": 112.02528238296509, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "45a84e1e.bdf7b", + "type": "set", + "name": "set tmp.ar.self-link", + "xml": "<set>\n<parameter name='tmp.ar.self-link' value=\"`'restconf/config/GENERIC-RESOURCE-API:connection-attachment-allotted-resources/connection-attachment-allotted-resource/'\n + $tmp.ar.allotted-resource-id\n + '/allotted-resource-data/connection-attachment-topology/'` \" />\n\n", + "comments": "", + "x": 653.9934978485107, + "y": 240.99349164962769, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "b2e9aacc.581ff8", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 660.2553882598877, + "y": 328.66022062301636, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "169fcb74.40e255", + "type": "execute", + "name": "generate allotted-resource tmp.ar-url", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"`$prop.restapi.connection-attachment-allottedresource`\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url\"/>\n <parameter name=\"target\" value=\"{allotted-resource-id}\"/>\n <parameter name=\"replacement\" value=\"`$tmp.ar.allotted-resource-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 710.2554912567139, + "y": 415.6602215766907, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "a1f59482.c2e3a8", + "type": "comment", + "name": "GET connection-attachment-allotted-resource from mdsal", + "info": "", + "comments": "", + "x": 753.808515548706, + "y": 507.5387673377991, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "48f7ab81.dd3f54", + "type": "comment", + "name": "Used for setting output to API Handler", + "info": "", + "comments": "", + "x": 707.9935283660889, + "y": 207.99350118637085, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "c7689a40.af6f68", + "type": "comment", + "name": "Obtain different URL, template location etc", + "info": "For saving resource information to MDSAL & for AAI", + "comments": "", + "x": 725.9934940338135, + "y": 293.88238191604614, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "5bb7cd3a.b035e4", + "type": "comment", + "name": "Used to Get AR by id to MDSAL, same as self-link", + "info": "", + "comments": "", + "x": 751.9935131072998, + "y": 380.88234090805054, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "255752ab.e0974e", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1194.666826248169, + "y": 534.0000281333923, + "z": "7c522092.2b01d", + "wires": [ + [ + "7b548c16.84a074" + ] + ] + }, + { + "id": "7b548c16.84a074", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1363.6668300628662, + "y": 532.4999289512634, + "z": "7c522092.2b01d", + "wires": [ + [ + "30903850.9efd78" + ] + ] + }, + { + "id": "30903850.9efd78", + "type": "switchNode", + "name": "switch cr length", + "xml": "<switch test='`$mdsal-ar.connection-attachment-allotted-resource_length`'>\n", + "comments": "", + "outputs": 1, + "x": 1536.5240993499756, + "y": 470.1190915107727, + "z": "7c522092.2b01d", + "wires": [ + [ + "f5872089.49e85", + "fd0f2962.8ae6b8" + ] + ] + }, + { + "id": "f5872089.49e85", + "type": "other", + "name": "outcome 1", + "xml": "<outcome value='1'>\n", + "comments": "", + "outputs": 1, + "x": 1773.857343673706, + "y": 448.11904191970825, + "z": "7c522092.2b01d", + "wires": [ + [ + "ddd5f356.20fb3" + ] + ] + }, + { + "id": "ddd5f356.20fb3", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic='true'>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1958.381233215332, + "y": 445.0238757133484, + "z": "7c522092.2b01d", + "wires": [ + [ + "26efebde.981c54", + "f909f530.6858a8", + "aab72afb.6cac28" + ] + ] + }, + { + "id": "49c172c3.b6fc6c", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"Error: SOTN resource not found\" />\n \n", + "comments": "", + "x": 1882.5190753936768, + "y": 570.066116809845, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "1a7aa44a.cd34ac", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1186.5186290740967, + "y": 569.0661129951477, + "z": "7c522092.2b01d", + "wires": [ + [ + "ea618a2d.cb5e38" + ] + ] + }, + { + "id": "ea618a2d.cb5e38", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1366.5185794830322, + "y": 569.7326636314392, + "z": "7c522092.2b01d", + "wires": [ + [ + "49c172c3.b6fc6c" + ] + ] + }, + { + "id": "fd0f2962.8ae6b8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1762.185297012329, + "y": 485.39940214157104, + "z": "7c522092.2b01d", + "wires": [ + [ + "49c172c3.b6fc6c" + ] + ] + }, + { + "id": "26efebde.981c54", + "type": "set", + "name": "set connection-attachment-ar from get", + "xml": "<set>\n<parameter name='connection-attachment-ar.' value='$mdsal-ar.connection-attachment-allotted-resource[0].' />\n", + "comments": "", + "x": 2204.4447917938232, + "y": 405.00010538101196, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "aab72afb.6cac28", + "type": "set", + "name": "set oper-status", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-action' value='`$connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.request-information.request-action`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-rpc-action' value='`$connection-attachment-ar.allotted-resource-status.rpc-action`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-svc-request-id' value='`$connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.sdnc-request-header.svc-request-id`' />\n\n", + "comments": "", + "x": 2137.444787979126, + "y": 495.4286599159241, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "f909f530.6858a8", + "type": "switchNode", + "name": "switch order-status", + "xml": "<switch test='`$connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.order-status`'>\n", + "comments": "", + "outputs": 1, + "x": 2148.4446239471436, + "y": 449.00010919570923, + "z": "7c522092.2b01d", + "wires": [ + [ + "dcae652b.a678c8", + "61137107.6ab3" + ] + ] + }, + { + "id": "dcae652b.a678c8", + "type": "outcome", + "name": "outcome Active", + "xml": "<outcome value='Active'>\n", + "comments": "", + "outputs": 1, + "x": 2355.0445728302, + "y": 439.00010919570923, + "z": "7c522092.2b01d", + "wires": [ + [ + "f4b4f2e4.a75bd" + ] + ] + }, + { + "id": "61137107.6ab3", + "type": "outcome", + "name": "outcome Other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2354.7590923309326, + "y": 481.42869997024536, + "z": "7c522092.2b01d", + "wires": [ + [ + "a2c4e7e4.8b9478" + ] + ] + }, + { + "id": "f4b4f2e4.a75bd", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2507.515127182007, + "y": 437.375759601593, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "a2c4e7e4.8b9478", + "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\" \n value=\"`'Existing connection-attachment-allotted-resource with order status of ' + $connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.order-status + '.'`\" />\n", + "comments": "", + "x": 2527.666982650757, + "y": 478.00011110305786, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "8746fbbb.5c4dd8", + "type": "call", + "name": "call GENERIC-RESOURCE-API:sdwan-get-saved-ar-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-saved-ar-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 915.3031139373779, + "y": 630.4935903549194, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "e34f2e02.a4351", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 612.3092784881592, + "y": 631.4999384880066, + "z": "7c522092.2b01d", + "wires": [ + [ + "8746fbbb.5c4dd8" + ] + ] + }, + { + "id": "96352635.65ff08", + "type": "comment", + "name": "GET parent-service-data from mdsal to check existence of other End point", + "info": "", + "comments": "", + "x": 794.0004405975342, + "y": 692.5316977500916, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "eb439772.0db3a8", + "type": "comment", + "name": "GET connection-attachment-ar to store AR data from mdsal", + "info": "", + "comments": "", + "x": 2187.4729442596436, + "y": 369.5039687156677, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "678453f3.6e4c2c", + "type": "comment", + "name": "Set source end point", + "info": "", + "comments": "", + "x": 625.9728374481201, + "y": 599.2540640830994, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "96bf45ea.f31428", + "type": "set", + "name": "set tmp.ar.parent-service-instance-id", + "xml": "<set>\n<parameter name='tmp.ar.parent-service-instance-id' value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.parent-service-instance-id` \" />\n\n", + "comments": "", + "x": 678.968915939331, + "y": 724.0002083778381, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "14706c37.53ff04", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1056.9689121246338, + "y": 773.0002074241638, + "z": "7c522092.2b01d", + "wires": [ + [ + "f7881611.1e7fc8" + ] + ] + }, + { + "id": "415e2268.5d0d3c", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1048.8207149505615, + "y": 808.0662922859192, + "z": "7c522092.2b01d", + "wires": [ + [ + "400a8be0.06c244" + ] + ] + }, + { + "id": "400a8be0.06c244", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"Error: SOTN resource not found\" />\n \n", + "comments": "", + "x": 1223.9694004058838, + "y": 804.3336424827576, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "f7881611.1e7fc8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1207.9689121246338, + "y": 771.0002074241638, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "6055aad6.cfe2c4", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1037.7308254241943, + "y": 2275.9528431892395, + "z": "7c522092.2b01d", + "wires": [ + [ + "3f6ad50.2555b2c" + ] + ] + }, + { + "id": "3f6ad50.2555b2c", + "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=\"AAI failed\" />\n", + "comments": "", + "x": 1199.25465965271, + "y": 2320.571889281273, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "235942f0.e7b26e", + "type": "failure", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 1039.8260669708252, + "y": 2341.7147859334946, + "z": "7c522092.2b01d", + "wires": [ + [ + "3f6ad50.2555b2c" + ] + ] + }, + { + "id": "48fc4721.99e218", + "type": "comment", + "name": "Save Resource to AAI", + "info": "", + "comments": "", + "x": 751.7784938812256, + "y": 2291.302206516266, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "57a853e.4687fac", + "type": "set", + "name": "set output to api handler", + "xml": "<set>\n<parameter name='allotted-resource-id' value='`$tmp.ar.allotted-resource-id`' />\n<parameter name='connection-attachment-object-path' value=\"`$tmp.ar.self-link`\"/>\n<parameter name='service-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $connection-attachment-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'`\"/>\n \n", + "comments": "", + "x": 766.5461902618408, + "y": 2212.827687740326, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "c17cdc10.1ceea", + "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": 713.9593296051025, + "y": 2407.443506717682, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "321fef32.53b0b", + "type": "execute", + "name": "execute RestApiCallNode - PUT AR by id", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='templateFileName' value=\"`$prop.restapi.templateDir + '/' + $prop.restapi.sdwan-attachment.templatefile`\" />\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='PUT' />\n <parameter name=\"responsePrefix\" value=\"mdsal-ar\" />\n\n", + "comments": "", + "outputs": 1, + "x": 816.2782917022705, + "y": 2120.4684615135193, + "z": "7c522092.2b01d", + "wires": [ + [ + "51856f43.e53b6", + "1d0bebfe.eab134", + "559d3f61.79c98" + ] + ] + }, + { + "id": "51856f43.e53b6", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 1084.9196681976318, + "y": 2171.7998732551932, + "z": "7c522092.2b01d", + "wires": [ + [ + "60114e3f.8f3c6" + ] + ] + }, + { + "id": "1d0bebfe.eab134", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1075.9197177886963, + "y": 2140.2998990044, + "z": "7c522092.2b01d", + "wires": [ + [ + "60114e3f.8f3c6" + ] + ] + }, + { + "id": "559d3f61.79c98", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1079.669755935669, + "y": 2110.657003879547, + "z": "7c522092.2b01d", + "wires": [ + [ + "f983099f.d54368" + ] + ] + }, + { + "id": "60114e3f.8f3c6", + "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=\"Error updating md-sal for connection-attachment-allotted-resource\" />\n", + "comments": "", + "x": 1245.669755935669, + "y": 2141.0499228462577, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "f983099f.d54368", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1221.3257236480713, + "y": 2106.8491730690002, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "ade80637.81d448", + "type": "set", + "name": "set ar-data", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-status.action' value=\"`$connection-attachment-topology-operation-input.request-information.request-action` \" />\n<parameter name='connection-attachment-ar.allotted-resource-status.rpc-name' value=\"connection-attachment-topology-operation\" />\n<parameter name='connection-attachment-ar.allotted-resource-status.rpc-action' value=\"`$connection-attachment-topology-operation-input.sdnc-request-header.svc-action` \" />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.request-information.' value=\"`$connection-attachment-topology-operation-input.request-information.` \" />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.sdnc-request-header.' value=\"`$connection-attachment-topology-operation-input.sdnc-request-header.` \" />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.service-information.' value=\"`$connection-attachment-topology-operation-input.service-information.` \" />\n", + "comments": "", + "x": 716.4919109344482, + "y": 1970.84938454628, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "4bdb1ae.9bc94e4", + "type": "execute", + "name": "execute getTime", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='setTime' >\n <parameter name=\"outputPath\" value=\"tmp.current-time\" />\n\n", + "comments": "", + "outputs": 1, + "x": 733.777753829956, + "y": 2043.468982219696, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "85c9e5e0.4b2808", + "type": "set", + "name": "set allotted-resource-oper-status", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.order-status' value='PendingDelete' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-action' value='`$connection-attachment-topology-operation-input.request-information.request-action`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-rpc-action' value='`$connection-attachment-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.last-svc-request-id' value='`$connection-attachment-topology-operation-input.sdnc-request-header.svc-request-id`' />\n<parameter name='connection-attachment-ar.allotted-resource-data.allotted-resource-oper-status.create-timestamp' value='`$tmp.current-time`' />\n", + "comments": "", + "x": 788.7648105621338, + "y": 2081.4201197624207, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "9fb629bb.9a3648", + "type": "set", + "name": "set model-data", + "xml": "<set>\n<parameter name='connection-attachment-ar.allotted-resource-data.connection-attachment-topology.onap-model-information.' value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.onap-model-information.` \" />", + "comments": "", + "x": 730.3334522247314, + "y": 2010.0240349769592, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "71e134cd.34ff8c", + "type": "comment", + "name": "Prepare data for allotted-resource addition to MDSAL", + "info": "This will add to allotted-resource which is present inside service.", + "comments": "", + "x": 839.6668834686279, + "y": 1926.0239098072052, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "616f171a.47daa8", + "type": "comment", + "name": "Add to allotted-resources in mdsal", + "info": "", + "comments": "", + "x": 781.2467098236084, + "y": 1893.4372115135193, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "5450bfab.9413e", + "type": "update", + "name": "update AAI allotted-resource", + "xml": "<update plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"allotted-resource\" \n\t\tkey=\"customer.global-customer-id = $connection-attachment-topology-operation-input.service-information.global-customer-id AND\n\t\t\tservice-subscription.service-type = $connection-attachment-topology-operation-input.service-information.subscription-service-type AND\n\t\t\tservice-instance.service-instance-id = $connection-attachment-topology-operation-input.service-information.service-instance-id AND\n\t\t\tallotted-resource.id = $tmp.ar.allotted-resource-id\"\n pfx='pfx' local-only='false' force='false'>\n\t<parameter name=\"selflink\" value=\"`$tmp.ar.self-link`\" />\n\t<parameter name=\"model-invariant-id\" value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.onap-model-information.model-invariant-uuid`\" />\n\t<parameter name=\"model-version-id\" value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.onap-model-information.model-uuid`\" />\n\t<parameter name=\"operational-status\" value=\"PendingDelete\" />\n", + "comments": "", + "outputs": 1, + "x": 778.2227725982666, + "y": 2328.75434923172, + "z": "7c522092.2b01d", + "wires": [ + [ + "6055aad6.cfe2c4", + "235942f0.e7b26e" + ] + ] + }, + { + "id": "94474a0.f7cc5b8", + "type": "execute", + "name": "execute RestApiCallNode - get-resource connection-attachment-allotted-resource", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-ar\" />\n\n", + "comments": "", + "outputs": 1, + "x": 827.3339519500732, + "y": 550.4999489784241, + "z": "7c522092.2b01d", + "wires": [ + [ + "255752ab.e0974e", + "1a7aa44a.cd34ac" + ] + ] + }, + { + "id": "500ce0c3.5b4ed", + "type": "execute", + "name": "get parent-service-data tmp.ar-url-psd", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"/restconf/config/GENERIC-RESOURCE-API:services/service/{service-instance-id}/service-data\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url-psd\"/>\n <parameter name=\"target\" value=\"{service-instance-id}\"/>\n <parameter name=\"replacement\" value=\"`$tmp.ar.parent-service-instance-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 681.0001964569092, + "y": 759.0002102851868, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "8054d01.53e0b3", + "type": "execute", + "name": "execute RestApiCallNode - get-resource parent service data", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-psd`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-psd\" />\n\n", + "comments": "", + "outputs": 1, + "x": 748.0001583099365, + "y": 794.0002942085266, + "z": "7c522092.2b01d", + "wires": [ + [ + "14706c37.53ff04", + "415e2268.5d0d3c" + ] + ] + }, + { + "id": "c6e4843.cf19e78", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 2568.8126583099365, + "y": 811.3294506072998, + "z": "7c522092.2b01d", + "wires": [ + [ + "5596c62d.3bd3a8" + ] + ] + }, + { + "id": "e43e013.c1cc8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2602.664144515991, + "y": 757.3954172134399, + "z": "7c522092.2b01d", + "wires": [ + [ + "6247e999.5c9548" + ] + ] + }, + { + "id": "d9e74637.02a718", + "type": "for", + "name": "for arvidx.. mdsal-sd.service-data.vnfs.vnf_length[]", + "xml": "<for index='arvidx' start='0' end='`$mdsal-sd.service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 2087.813558578491, + "y": 1638.9966711997986, + "z": "7c522092.2b01d", + "wires": [ + [ + "9c851968.c2df88" + ] + ] + }, + { + "id": "9c851968.c2df88", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2363.480131149292, + "y": 1639.9967041015625, + "z": "7c522092.2b01d", + "wires": [ + [ + "54b544e3.42d4bc" + ] + ] + }, + { + "id": "54b544e3.42d4bc", + "type": "switchNode", + "name": "switch ActivateSiteInstance", + "xml": "<switch test=\"`$mdsal-sd.service-data.vnfs.vnf[$arvidx].vnf-data.request-information.request-action == ActivateSiteInstance`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 2600.343832015991, + "y": 1644.194667816162, + "z": "7c522092.2b01d", + "wires": [ + [ + "aa6e75db.b48038" + ] + ] + }, + { + "id": "aa6e75db.b48038", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2809.3433475494385, + "y": 1644.19482088089, + "z": "7c522092.2b01d", + "wires": [ + [ + "3132632f.4cad6c" + ] + ] + }, + { + "id": "2aa66f72.5e93f", + "type": "set", + "name": "set tmp.sitevidx ", + "xml": "<set>\n<parameter name='tmp.sitevidx' value='`$arvidx`' />\n\n", + "comments": "", + "x": 2206.3442974090576, + "y": 1748.1952495574951, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "4f450f5a.52d67", + "type": "set", + "name": "set prop.ar-parent-service-instance-id", + "xml": "<set>\n<parameter name='prop.ar-parent-service-instance-id' value='`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.allotted-resource-information.parent-service-instance-id`' />\n", + "comments": "", + "x": 2122.8124599456787, + "y": 1061.996099948883, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "2d8849eb.21e096", + "type": "for", + "name": "for loop aridx - Get role from allotted resource", + "xml": "<for index=\"aridx\" start=\"0\" end=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2148.8122539520264, + "y": 1010.4959712028503, + "z": "7c522092.2b01d", + "wires": [ + [ + "d84d5dca.fda43" + ] + ] + }, + { + "id": "d84d5dca.fda43", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2403.812582015991, + "y": 1007.4964308738708, + "z": "7c522092.2b01d", + "wires": [ + [ + "f1205a89.ab0798", + "52dd7727.f5fe18" + ] + ] + }, + { + "id": "f1205a89.ab0798", + "type": "switchNode", + "name": "switch Role", + "xml": "<switch test=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$aridx].name == 'Role'`\">\n", + "comments": "", + "outputs": 1, + "x": 2533.8124027252197, + "y": 979.496367931366, + "z": "7c522092.2b01d", + "wires": [ + [ + "c09b2335.3fa2e" + ] + ] + }, + { + "id": "c09b2335.3fa2e", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2674.812734603882, + "y": 978.4963669776917, + "z": "7c522092.2b01d", + "wires": [ + [ + "a9576f56.b9348" + ] + ] + }, + { + "id": "a9576f56.b9348", + "type": "set", + "name": "set prop.role", + "xml": "<set>\n<parameter name='prop.role' value='`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$aridx].value`' />\n", + "comments": "", + "x": 2840.813398361206, + "y": 973.0962700843811, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "fa09f12.7306b1", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 2420.813081741333, + "y": 1156.9963774681091, + "z": "7c522092.2b01d", + "wires": [ + [ + "949549ca.fec9a8" + ] + ] + }, + { + "id": "a6b8177b.a72a88", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2414.6648235321045, + "y": 1113.0624146461487, + "z": "7c522092.2b01d", + "wires": [ + [ + "ffd5545.891d1a8" + ] + ] + }, + { + "id": "6247e999.5c9548", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2728.8122692108154, + "y": 754.4958505630493, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "5596c62d.3bd3a8", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1858.3121318817139, + "y": 1028.4959712028503, + "z": "7c522092.2b01d", + "wires": [ + [ + "2d8849eb.21e096", + "4f450f5a.52d67", + "fc8ba65.b9ce358", + "4d147f57.4dac2" + ] + ] + }, + { + "id": "ffd5545.891d1a8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2544.312942504883, + "y": 1106.496334552765, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "949549ca.fec9a8", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1934.312421798706, + "y": 1233.4959845542908, + "z": "7c522092.2b01d", + "wires": [ + [ + "3f440bd9.75daa4" + ] + ] + }, + { + "id": "9c405c37.6c68b", + "type": "for", + "name": "for loop siteidx - Get site ID from servicedata", + "xml": "<for index=\"siteidx\" start=\"0\" end=\"`$mdsal-sd.service-data.vnfs.vnf[$tmp.sitevidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2298.3151454925537, + "y": 1789.4970073699951, + "z": "7c522092.2b01d", + "wires": [ + [ + "b4cc5d95.f9e96" + ] + ] + }, + { + "id": "58af8ae9.984c54", + "type": "switchNode", + "name": "switch siteId", + "xml": "<switch test=\"`$mdsal-sd.service-data.vnfs.vnf[$tmp.sitevidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$siteidx].name == 'siteId'`\">\n", + "comments": "", + "outputs": 1, + "x": 2370.317129135132, + "y": 1857.497986793518, + "z": "7c522092.2b01d", + "wires": [ + [ + "545beb56.93d714" + ] + ] + }, + { + "id": "a5f8b7de.41e8d8", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2224.815404891968, + "y": 1930.9970245361328, + "z": "7c522092.2b01d", + "wires": [ + [ + "40a92cd6.b03f74", + "92d18c15.f7ea6", + "6fed1bc4.775804" + ] + ] + }, + { + "id": "e6e54d59.f029", + "type": "execute", + "name": "execute RestApiCallNode delete vpn topology", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-vpn-topology.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/' + $prop.vpn1Id + '/topology'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 814.8129138946533, + "y": 1718.4967412948608, + "z": "7c522092.2b01d", + "wires": [ + [ + "41dfdc02.d499c4", + "13592df6.00f3c2" + ] + ] + }, + { + "id": "41dfdc02.d499c4", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1069.8126811981201, + "y": 1734.4967412948608, + "z": "7c522092.2b01d", + "wires": [ + [ + "899d6eb4.6e43e" + ] + ] + }, + { + "id": "899d6eb4.6e43e", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1239.8126201629639, + "y": 1737.4967412948608, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "9460e156.0dbc9", + "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=\"Error executing Create vpn rest api\" />\n", + "comments": "", + "x": 1239.8127422332764, + "y": 1693.4967412948608, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "13592df6.00f3c2", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1072.8126201629639, + "y": 1693.4967412948608, + "z": "7c522092.2b01d", + "wires": [ + [ + "9460e156.0dbc9" + ] + ] + }, + { + "id": "23c44741.0683a8", + "type": "set", + "name": "set controller data", + "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n", + "comments": "", + "x": 1240.3796348571777, + "y": 1256.1728954315186, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "b8f3c1af.8a68d", + "type": "get-resource", + "name": "get-resource esr-thirdparty-sdnc", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n", + "comments": "", + "outputs": 1, + "x": 809.8793773651123, + "y": 1307.1732459068298, + "z": "7c522092.2b01d", + "wires": [ + [ + "6754723.b98c58c", + "6d29272.a552fd8", + "9b336b2d.6145a8" + ] + ] + }, + { + "id": "6754723.b98c58c", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1068.8796691894531, + "y": 1262.1728792190552, + "z": "7c522092.2b01d", + "wires": [ + [ + "23c44741.0683a8" + ] + ] + }, + { + "id": "6d29272.a552fd8", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 1065.3703861236572, + "y": 1300.7469758987427, + "z": "7c522092.2b01d", + "wires": [ + [ + "34fe0d3d.2375f2" + ] + ] + }, + { + "id": "9b336b2d.6145a8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1060.7033939361572, + "y": 1342.080288887024, + "z": "7c522092.2b01d", + "wires": [ + [ + "6298bcb0.bae674" + ] + ] + }, + { + "id": "34fe0d3d.2375f2", + "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1215.941701889038, + "y": 1295.0327281951904, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "6298bcb0.bae674", + "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1222.4758548736572, + "y": 1343.519497871399, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "3f440bd9.75daa4", + "type": "for", + "name": "for pnidx.. mdsal-parentsd.service-data.networks.network_length[]", + "xml": "<for index='pnidx' start='0' end='`$mdsal-parentsd.service-data.networks.network_length`' >\n", + "comments": "", + "outputs": 1, + "x": 2259.3119945526123, + "y": 1232.9957122802734, + "z": "7c522092.2b01d", + "wires": [ + [ + "ad8228ad.984598" + ] + ] + }, + { + "id": "adf75159.a4939", + "type": "switchNode", + "name": "switch ActivateSDWANConnectivityInstance", + "xml": "<switch test=\"`$mdsal-parentsd.service-data.networks.network[$pnidx].network-data.request-information.request-action == 'ActivateSDWANConnectivityInstance'`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 2182.979818344116, + "y": 1325.9959139823914, + "z": "7c522092.2b01d", + "wires": [ + [ + "152fe76d.8c87b9" + ] + ] + }, + { + "id": "152fe76d.8c87b9", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2439.97931098938, + "y": 1324.9960441589355, + "z": "7c522092.2b01d", + "wires": [ + [ + "bff21d24.0b57f" + ] + ] + }, + { + "id": "94eca419.a27f98", + "type": "for", + "name": "for loop paramidx - Get topology from servicedata", + "xml": "<for index=\"paramidx\" start=\"0\" end=\"`$mdsal-parentsd.service-data.networks.network[$pnidx].network-data.network-request-input.network-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2241.9799976348877, + "y": 1414.9956321716309, + "z": "7c522092.2b01d", + "wires": [ + [ + "de02d4be.b70b88" + ] + ] + }, + { + "id": "de02d4be.b70b88", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2507.9796867370605, + "y": 1411.9959554672241, + "z": "7c522092.2b01d", + "wires": [ + [ + "a00734cd.6de4c8", + "641cbedf.bffd9" + ] + ] + }, + { + "id": "a00734cd.6de4c8", + "type": "switchNode", + "name": "switch topology", + "xml": "<switch test=\"`$mdsal-parentsd.service-data.networks.network[$pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].name == 'topology'`\">\n", + "comments": "", + "outputs": 1, + "x": 2678.9800205230713, + "y": 1380.9954652786255, + "z": "7c522092.2b01d", + "wires": [ + [ + "26c02eae.b386b2" + ] + ] + }, + { + "id": "26c02eae.b386b2", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2830.980010986328, + "y": 1382.9954957962036, + "z": "7c522092.2b01d", + "wires": [ + [ + "fa1994f9.3ab1f8" + ] + ] + }, + { + "id": "fa1994f9.3ab1f8", + "type": "set", + "name": "set topology", + "xml": "<set>\n<parameter name='prop.topology' value='`$mdsal-parentsd.service-data.networks.network[$pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].value`' />\n", + "comments": "", + "x": 2974.98002243042, + "y": 1382.5954303741455, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "641cbedf.bffd9", + "type": "switchNode", + "name": "switch vpnId", + "xml": "<switch test=\"`$mdsal-parentsd.service-data.networks.network[$pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].name == 'vpn-id'`\">\n", + "comments": "", + "outputs": 1, + "x": 2670.6457443237305, + "y": 1423.328447341919, + "z": "7c522092.2b01d", + "wires": [ + [ + "8be0360b.142cf8" + ] + ] + }, + { + "id": "8be0360b.142cf8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2822.6457347869873, + "y": 1425.328477859497, + "z": "7c522092.2b01d", + "wires": [ + [ + "d6238463.67fb38" + ] + ] + }, + { + "id": "d6238463.67fb38", + "type": "set", + "name": "set prop.vpn1Id", + "xml": "<set>\n<parameter name='prop.vpn1Id' value='`$mdsal-parentsd.service-data.networks.network[$pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].value`' />\n", + "comments": "", + "x": 2966.645746231079, + "y": 1424.928412437439, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "d94628e2.163098", + "type": "execute", + "name": "execute RestApiCallNode delete vpn ", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-vpn.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/vpn'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 787.8125858306885, + "y": 1829.9967064857483, + "z": "7c522092.2b01d", + "wires": [ + [ + "ad8a5a19.5d2dc8", + "a192274c.875558" + ] + ] + }, + { + "id": "ad8a5a19.5d2dc8", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1020.8126640319824, + "y": 1854.996705532074, + "z": "7c522092.2b01d", + "wires": [ + [ + "f3ab5240.5c692" + ] + ] + }, + { + "id": "f3ab5240.5c692", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1190.8126029968262, + "y": 1857.996705532074, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "bd5bcef5.5eb46", + "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=\"Error executing Create vpn rest api\" />\n", + "comments": "", + "x": 1190.8127250671387, + "y": 1813.996705532074, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "a192274c.875558", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1023.8126029968262, + "y": 1813.996705532074, + "z": "7c522092.2b01d", + "wires": [ + [ + "bd5bcef5.5eb46" + ] + ] + }, + { + "id": "82cffc44.23091", + "type": "set", + "name": "set prop.name", + "xml": "<set>\n<parameter name='prop.name' value='`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$aridx].value`' />\n", + "comments": "", + "x": 2888.8124027252197, + "y": 1025.9959406852722, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "52dd7727.f5fe18", + "type": "switchNode", + "name": "switch sdwanVpnName", + "xml": "<switch test=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$aridx].name == 'sdwanVpnName'`\">\n", + "comments": "", + "outputs": 1, + "x": 2569.3122425079346, + "y": 1028.9959330558777, + "z": "7c522092.2b01d", + "wires": [ + [ + "68d65f0e.41b06" + ] + ] + }, + { + "id": "68d65f0e.41b06", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2740.3124027252197, + "y": 1027.9960017204285, + "z": "7c522092.2b01d", + "wires": [ + [ + "82cffc44.23091" + ] + ] + }, + { + "id": "56e2d584.03ab4c", + "type": "set", + "name": "set prop.ar.provided-allotted-resource-id", + "xml": "<set>\n<parameter name='prop.ar.provided-allotted-resource-id' value='`$mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource[$pidx].allotted-resource-id`' />\n\n\n", + "comments": "", + "x": 2054.8120098114014, + "y": 769.9960651397705, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "bb8d7398.e602a", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1367.8424663543701, + "y": 1171.1932725906372, + "z": "7c522092.2b01d", + "wires": [ + [ + "f1cd9602.486d48" + ] + ] + }, + { + "id": "667f1405.f078ac", + "type": "execute", + "name": "generate tmp.ar-url-connection url", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"`$prop.restapi.connection-attachment-allottedresource`\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url-connection\"/>\n <parameter name=\"target\" value=\"{allotted-resource-id}\"/>\n <parameter name=\"replacement\" value=\"`$prop.ar.provided-allotted-resource-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 2039.3296718597412, + "y": 803.3295412063599, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "a0d61f91.413f4", + "type": "execute", + "name": "execute RestApiCallNode - get-resource connection-attachment-allotted-resource", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-connection`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-providedAr\" />\n\n", + "comments": "", + "outputs": 1, + "x": 2179.3293018341064, + "y": 838.9958324432373, + "z": "7c522092.2b01d", + "wires": [ + [ + "e43e013.c1cc8", + "c6e4843.cf19e78" + ] + ] + }, + { + "id": "fc8ba65.b9ce358", + "type": "execute", + "name": "execute RestApiCallNode - get parent service data", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-connection`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-parentsd\" />\n\n", + "comments": "", + "outputs": 1, + "x": 2154.9965419769287, + "y": 1131.9958891868591, + "z": "7c522092.2b01d", + "wires": [ + [ + "fa09f12.7306b1", + "a6b8177b.a72a88" + ] + ] + }, + { + "id": "bff21d24.0b57f", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1899.3299617767334, + "y": 1421.663094997406, + "z": "7c522092.2b01d", + "wires": [ + [ + "94eca419.a27f98", + "ad1d91e2.9fb76", + "b140ba23.8a1858", + "c40e517f.50767" + ] + ] + }, + { + "id": "40a92cd6.b03f74", + "type": "set", + "name": "set prop.attach.siteId", + "xml": "<set>\n<parameter name='prop.attach.siteId' value='`$mdsal-sd.service-data.vnfs.vnf[$tmp.sitevidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$siteidx].value`' />\n\n", + "comments": "", + "x": 2490.9982776641846, + "y": 1912.6638507843018, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "545beb56.93d714", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2510.9985332489014, + "y": 1857.6636772155762, + "z": "7c522092.2b01d", + "wires": [ + [ + "a5f8b7de.41e8d8" + ] + ] + }, + { + "id": "3132632f.4cad6c", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2003.6644191741943, + "y": 1743.3301877975464, + "z": "7c522092.2b01d", + "wires": [ + [ + "9c405c37.6c68b", + "2aa66f72.5e93f" + ] + ] + }, + { + "id": "9c9d490e.b9a1b8", + "type": "for", + "name": "for pidx..mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource[]", + "xml": "<for index='pidx' start='0' end='`$mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource_length`' >\n", + "comments": "", + "outputs": 1, + "x": 975.1812229156494, + "y": 1206.6358728408813, + "z": "7c522092.2b01d", + "wires": [ + [ + "bb8d7398.e602a" + ] + ] + }, + { + "id": "b4cc5d95.f9e96", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2215.6647777557373, + "y": 1854.0008354187012, + "z": "7c522092.2b01d", + "wires": [ + [ + "58af8ae9.984c54" + ] + ] + }, + { + "id": "75448c50.567d34", + "type": "set", + "name": "set prop.siteAttachement_length=0", + "xml": "<set>\n<parameter name='prop.siteAttachements_length' value='0' />\n<parameter name='prop.siteIds_length' value='0' />\n\n\n\n", + "comments": "", + "x": 820.9999980926514, + "y": 1149.5312285423279, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "92d18c15.f7ea6", + "type": "set", + "name": "Add sites to list and update length", + "xml": "<set>\n<parameter name='prop.siteIds[$prop.siteIds_length]' value='`$prop.attach.siteId`' />\n<parameter name='prop.siteIds_length' value='`$prop.siteIds_length + 1`' />\n\n\n\n\n\n\n\n\n\n\n", + "comments": "", + "x": 2518.5021114349365, + "y": 1957.5316557884216, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "4d147f57.4dac2", + "type": "execute", + "name": "generate prop.ar-parent-service-instance-id", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"/restconf/config/GENERIC-RESOURCE-API:services/service/{service-instance-id}/service-data\"/> \n <parameter name=\"outputPath\" value=\"tmp.ar-url-connection\"/>\n <parameter name=\"target\" value=\"{service-instance-id}\"/>\n <parameter name=\"replacement\" value=\"`$prop.ar-parent-service-instance-id`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 2139.5001430511475, + "y": 1094.531409740448, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "ad1d91e2.9fb76", + "type": "set", + "name": "set prop.ar-service-instance-id", + "xml": "<set>\n<parameter name='prop.ar-service-instance-id' value='`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.connection-attachment-topology.allotted-resource-identifiers.consuming-service-instance-id`' />\n", + "comments": "", + "x": 2172.5005626678467, + "y": 1483.5313277244568, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "b140ba23.8a1858", + "type": "execute", + "name": "generate prop.ar-service-instance-id", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"/restconf/config/GENERIC-RESOURCE-API:services/service/{service-instance-id}/service-data\"/> \n <parameter name=\"outputPath\" value=\"tmp.ar-url-connection\"/>\n <parameter name=\"target\" value=\"{service-instance-id}\"/>\n <parameter name=\"replacement\" value=\"`$prop.ar-service-instance-id`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 2197.8330211639404, + "y": 1516.4096236228943, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "c40e517f.50767", + "type": "execute", + "name": "execute RestApiCallNode - get-resource service data", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-connection`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-sd\" />\n\n", + "comments": "", + "outputs": 1, + "x": 2248.833143234253, + "y": 1553.4094424247742, + "z": "7c522092.2b01d", + "wires": [ + [ + "6f8bfcf3.2cbda4", + "671b3b67.714c24" + ] + ] + }, + { + "id": "671b3b67.714c24", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 2527.500207901001, + "y": 1549.5311541557312, + "z": "7c522092.2b01d", + "wires": [ + [ + "1fc5d55c.4c864b" + ] + ] + }, + { + "id": "6f8bfcf3.2cbda4", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2525.3525371551514, + "y": 1510.5972819328308, + "z": "7c522092.2b01d", + "wires": [ + [ + "2fe21dd5.a9ca62" + ] + ] + }, + { + "id": "2fe21dd5.a9ca62", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2655.0007305145264, + "y": 1504.0312418937683, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "1fc5d55c.4c864b", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2676.5011043548584, + "y": 1550.5313391685486, + "z": "7c522092.2b01d", + "wires": [ + [ + "d9e74637.02a718" + ] + ] + }, + { + "id": "f1cd9602.486d48", + "type": "switchNode", + "name": "switch allotted resource ID match", + "xml": "<switch test=\"`$mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource[$pidx].allotted-resource-id == $tmp.ar.allotted-resource-id`\">", + "comments": "", + "outputs": 1, + "x": 1591.5001125335693, + "y": 1168.031301021576, + "z": "7c522092.2b01d", + "wires": [ + [ + "a2faeb8f.9adb58" + ] + ] + }, + { + "id": "a2faeb8f.9adb58", + "type": "outcomeFalse", + "name": "false", + "xml": "<outcome value='false'>\n", + "comments": "", + "outputs": 1, + "x": 1670.5001773834229, + "y": 805.0312938690186, + "z": "7c522092.2b01d", + "wires": [ + [ + "7036cf78.a5aa3" + ] + ] + }, + { + "id": "7036cf78.a5aa3", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1812.5004253387451, + "y": 804.0312347412109, + "z": "7c522092.2b01d", + "wires": [ + [ + "56e2d584.03ab4c", + "667f1405.f078ac", + "a0d61f91.413f4" + ] + ] + }, + { + "id": "15b04770.9781e9", + "type": "comment", + "name": "if allotted resource Id match with the incomming allotted resource ID, sites in this service vnf should not be included", + "info": "parent instId 200 | parent instId 200\nservice instId 100| service InstId 200\n site1 | site2\n allotted resId 1 | allotted resId 2 \n --------------------------------------\n Deactivate:\n loop for provided allotted res ID\n If allotted resId 1 matches with incomming allotted resource Id then we should delete the sites available in the service data 100\n for this we have to send request for deleting with site IDs site2 without including site1.\n \n \n ", + "comments": "", + "x": 1765.5000286102295, + "y": 737.0312957763672, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "7505e39f.a765fc", + "type": "comment", + "name": "loop for provided allotted rsource Id", + "info": "", + "comments": "", + "x": 1087.4999980926514, + "y": 1170.5312895774841, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "2f9e3c20.0207a4", + "type": "comment", + "name": "get allotted resource for the allotted resource ID", + "info": "", + "comments": "", + "x": 2326.500326156616, + "y": 738.5311737060547, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "7fd25f7d.205ea", + "type": "comment", + "name": "get parent service data to get connectivity which has connectivity and vpn ID", + "info": "", + "comments": "", + "x": 2109.4998531341553, + "y": 965.5312514305115, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "53cc3005.40ef", + "type": "comment", + "name": "get service data from service instance id from allotted reosurce Id to get sites vnf", + "info": "", + "comments": "", + "x": 2298.4998531341553, + "y": 1447.531051158905, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "965fc969.fd32d8", + "type": "call", + "name": "call sdwan-vnf-topology-operation-underlay for delete", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-wanport-vnf-topology-operation-underlay' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 848.5001163482666, + "y": 1634.531358242035, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "6fed1bc4.775804", + "type": "set", + "name": "Add site attachement to list and update length", + "xml": "<set>\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].siteId' value='`$prop.attach.siteId`' />\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles[0]' value='`$prop.role`' />\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles_length' value='1' />\n<parameter name='prop.siteAttachements_length' value='`$prop.siteAttachements_length + 1`' />\n\n\n\n\n\n\n\n\n\n\n\n\n", + "comments": "", + "x": 2548.2500896453857, + "y": 1998.2539830207825, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "d6353ac9.cd8368", + "type": "execute", + "name": "execute RestApiCallNode Get token", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>", + "comments": "", + "outputs": 1, + "x": 822.000036239624, + "y": 1397.000150680542, + "z": "7c522092.2b01d", + "wires": [ + [ + "58744a52.9052b4", + "2cb21a31.a626b6" + ] + ] + }, + { + "id": "58744a52.9052b4", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1074.0001621246338, + "y": 1377.9999685287476, + "z": "7c522092.2b01d", + "wires": [ + [ + "1cd6b02.062c05" + ] + ] + }, + { + "id": "1cd6b02.062c05", + "type": "set", + "name": "set token-id", + "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n", + "comments": "", + "x": 1223.0001621246338, + "y": 1376.9999380111694, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "8b511642.cc8a88", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1214.0001888275146, + "y": 1411.3932132720947, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "2cb21a31.a626b6", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1066.2501964569092, + "y": 1413.6430912017822, + "z": "7c522092.2b01d", + "wires": [ + [ + "8b511642.cc8a88" + ] + ] + }, + { + "id": "de426682.23e5b8", + "type": "get-resource", + "name": "get-resource service-subscription", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"service-subscription\" \n key= 'service-subscription.service-type = $connection-attachment-topology-operation-input.service-information.subscription-service-type \n AND customer.global-customer-id = $connection-attachment-topology-operation-input.service-information.global-customer-id'\n force=\"true\" pfx=\"tmp.AnAI-data-tenant\"> ", + "comments": "", + "outputs": 1, + "x": 812.8955059051514, + "y": 1509.5620489120483, + "z": "7c522092.2b01d", + "wires": [ + [ + "4a6eca43.810a44", + "6a29a6d.e51e358" + ] + ] + }, + { + "id": "9c358a1f.148518", + "type": "execute", + "name": "execute RestApiCallNode Create tenant auth", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/baseservice/tenants/authorization/' + $prop.tenant-id`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"tenant-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 850.3955669403076, + "y": 1576.4548950195312, + "z": "7c522092.2b01d", + "wires": [ + [] + ] + }, + { + "id": "6a29a6d.e51e358", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1017.0739574432373, + "y": 1534.52241897583, + "z": "7c522092.2b01d", + "wires": [ + [ + "bcbf10f7.b7993" + ] + ] + }, + { + "id": "4a6eca43.810a44", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1023.3953685760498, + "y": 1482.3081073760986, + "z": "7c522092.2b01d", + "wires": [ + [ + "67730720.8e4a18" + ] + ] + }, + { + "id": "bcbf10f7.b7993", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1169.8239574432373, + "y": 1534.2724800109863, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "67730720.8e4a18", + "type": "switchNode", + "name": "switch temp-ub-sub-account-id", + "xml": "<switch test='`$tmp.AnAI-data-tenant.temp-ub-sub-account-id`'>\n", + "comments": "", + "outputs": 1, + "x": 1224.8955974578857, + "y": 1474.3121299743652, + "z": "7c522092.2b01d", + "wires": [ + [ + "ffa06abb.9a2a48", + "cc923e40.7eb57" + ] + ] + }, + { + "id": "cc923e40.7eb57", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 1458.0039043426514, + "y": 1433.0039434432983, + "z": "7c522092.2b01d", + "wires": [ + [ + "7c9ff36f.d8d7bc" + ] + ] + }, + { + "id": "ffa06abb.9a2a48", + "type": "other", + "name": "Other", + "xml": "<outcome value='Other'>", + "comments": "", + "outputs": 1, + "x": 1411.2894840240479, + "y": 1527.0040216445923, + "z": "7c522092.2b01d", + "wires": [ + [ + "d1efa0cc.71a21" + ] + ] + }, + { + "id": "d1efa0cc.71a21", + "type": "set", + "name": "set prop.tenant-id", + "xml": "<set>\n<parameter name='prop.tenant-id' value='`$tmp.AnAI-data-tenant.temp-ub-sub-account-id`' />\n", + "comments": "", + "x": 1580.1466655731201, + "y": 1525.1110353469849, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "7c9ff36f.d8d7bc", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1570.4322299957275, + "y": 1477.8253078460693, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "7e6a4a74.fb8064", + "type": "for", + "name": "for ntidx.. mdsal-psd.service-data.networks.network_length[]", + "xml": "<for index='ntidx' start='0' end='`$mdsal-psd.service-data.networks.network_length`' >\n", + "comments": "", + "outputs": 1, + "x": 776.0312480926514, + "y": 903.0312495231628, + "z": "7c522092.2b01d", + "wires": [ + [ + "b21fb0ff.7db48" + ] + ] + }, + { + "id": "ad8228ad.984598", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1907.031270980835, + "y": 1324.0312895774841, + "z": "7c522092.2b01d", + "wires": [ + [ + "adf75159.a4939" + ] + ] + }, + { + "id": "b21fb0ff.7db48", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 740.0312480926514, + "y": 975.0312495231628, + "z": "7c522092.2b01d", + "wires": [ + [ + "e497173b.c24408" + ] + ] + }, + { + "id": "e497173b.c24408", + "type": "switchNode", + "name": "switch ActivateSDWANConnectivityInstance", + "xml": "<switch test=\"`$mdsal-psd.service-data.networks.network[$ntidx].network-data.request-information.request-action == 'ActivateSDWANConnectivityInstance'`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 1015.9797954559326, + "y": 976.9958739280701, + "z": "7c522092.2b01d", + "wires": [ + [ + "d6c139b3.090dd8" + ] + ] + }, + { + "id": "d6c139b3.090dd8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1272.9792881011963, + "y": 975.9960041046143, + "z": "7c522092.2b01d", + "wires": [ + [ + "b4139f80.a76b4" + ] + ] + }, + { + "id": "b4139f80.a76b4", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 732.3299388885498, + "y": 1072.6630549430847, + "z": "7c522092.2b01d", + "wires": [ + [ + "ba5ecb28.66e198" + ] + ] + }, + { + "id": "ba5ecb28.66e198", + "type": "for", + "name": "for loop paramidx - Get topology from servicedata", + "xml": "<for index=\"paramidx\" start=\"0\" end=\"`$mdsal-psd.service-data.networks.network[$ntidx].network-data.network-request-input.network-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 1011.9800395965576, + "y": 1061.995677471161, + "z": "7c522092.2b01d", + "wires": [ + [ + "bcfcaf76.f471a" + ] + ] + }, + { + "id": "bcfcaf76.f471a", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1209.9796695709229, + "y": 1114.996165752411, + "z": "7c522092.2b01d", + "wires": [ + [ + "808f1a6b.ade978", + "8fc5fee9.2e70f", + "7c2cd6d7.da9468" + ] + ] + }, + { + "id": "8fc5fee9.2e70f", + "type": "switchNode", + "name": "switch vpnId", + "xml": "<switch test=\"`$mdsal-psd.service-data.networks.network[$ntidx].network-data.network-request-input.network-input-parameters.param[$paramidx].name == 'vpn-id'`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1359.6458168029785, + "y": 1129.3284697532654, + "z": "7c522092.2b01d", + "wires": [ + [ + "5eeff931.68f088" + ] + ] + }, + { + "id": "808f1a6b.ade978", + "type": "switchNode", + "name": "switch topology", + "xml": "<switch test=\"`$mdsal-psd.service-data.networks.network[$ntidx].network-data.network-request-input.network-input-parameters.param[$paramidx].name == 'topology'`\">\n", + "comments": "", + "outputs": 1, + "x": 1367.9800930023193, + "y": 1086.995487689972, + "z": "7c522092.2b01d", + "wires": [ + [ + "385cddcb.23c372" + ] + ] + }, + { + "id": "5eeff931.68f088", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1511.6458072662354, + "y": 1131.3285002708435, + "z": "7c522092.2b01d", + "wires": [ + [ + "827b7756.0101b8" + ] + ] + }, + { + "id": "385cddcb.23c372", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1519.9800834655762, + "y": 1088.99551820755, + "z": "7c522092.2b01d", + "wires": [ + [ + "9cc5fb84.591a88" + ] + ] + }, + { + "id": "9cc5fb84.591a88", + "type": "set", + "name": "set topology", + "xml": "<set>\n<parameter name='prop.topology' value='`$mdsal-psd.service-data.networks.network[$ntidx].network-data.network-request-input.network-input-parameters.param[$paramidx].value`' />\n", + "comments": "", + "x": 1604.9800968170166, + "y": 1026.5954375267029, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "827b7756.0101b8", + "type": "set", + "name": "set prop.vpn1Id", + "xml": "<set>\n<parameter name='prop.vpn1Id' value='`$mdsal-psd.service-data.networks.network[$ntidx].network-data.network-request-input.network-input-parameters.param[$paramidx].value`' />\n", + "comments": "", + "x": 1659.6458721160889, + "y": 1120.9284148216248, + "z": "7c522092.2b01d", + "wires": [] + }, + { + "id": "7c2cd6d7.da9468", + "type": "switchNode", + "name": "switch vpn name", + "xml": "<switch test=\"`$mdsal-psd.service-data.networks.network[$ntidx].network-data.network-request-input.network-input-parameters.param[$paramidx].name == 'name'`\">\n", + "comments": "", + "outputs": 1, + "x": 1331.031270980835, + "y": 1045.031277179718, + "z": "7c522092.2b01d", + "wires": [ + [ + "829e0f12.c7157" + ] + ] + }, + { + "id": "829e0f12.c7157", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1441.0312747955322, + "y": 989.0312466621399, + "z": "7c522092.2b01d", + "wires": [ + [ + "16fe2ddd.1cfe92" + ] + ] + }, + { + "id": "16fe2ddd.1cfe92", + "type": "set", + "name": "set vpn name", + "xml": "<set>\n<parameter name='prop.name' value='`$mdsal-psd.service-data.networks.network[$ntidx].network-data.network-request-input.network-input-parameters.param[$paramidx].value`' />\n", + "comments": "", + "x": 1562.0312747955322, + "y": 954.6312832832336, + "z": "7c522092.2b01d", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-delete.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-delete.json new file mode 100644 index 00000000..074dee31 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-attachment-topology-operation-delete.json @@ -0,0 +1,941 @@ +[ + { + "id": "b9f06b07.f3a768", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 131, + "y": 70, + "z": "4de23974.164008", + "wires": [ + [ + "56d70828.f50c48" + ] + ] + }, + { + "id": "56d70828.f50c48", + "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": 343.00000381469727, + "y": 142.0000171661377, + "z": "4de23974.164008", + "wires": [ + [ + "8c1c122c.922b4" + ] + ] + }, + { + "id": "8c1c122c.922b4", + "type": "method", + "name": "sdwan-attachment-topology-operation-delete", + "xml": "<method rpc='sdwan-attachment-topology-operation-delete' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 331.0001220703125, + "y": 230, + "z": "4de23974.164008", + "wires": [ + [ + "b8453101.deebe" + ] + ] + }, + { + "id": "b8453101.deebe", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 347.0001220703125, + "y": 785.0002446174622, + "z": "4de23974.164008", + "wires": [ + [ + "57dbee5c.be95e", + "ca7d47f1.45f358", + "7673909c.5a2e3", + "ecea06e3.25a318", + "da0989a1.945518", + "ae3090d.67bd97", + "3ac1cb4a.bcc3b4", + "e3865992.7e3fc8", + "4734b343.474b9c", + "b32dbc09.e3051", + "d3caba2b.d332f8", + "cfc2e19e.1fcac", + "61e84275.3bc6fc", + "cc50854b.9b5d18", + "2036e77.af47618" + ] + ] + }, + { + "id": "57dbee5c.be95e", + "type": "set", + "name": "set tmp.ar.allotted-resource-id,etc", + "xml": "<set>\n<parameter name='tmp.ar.allotted-resource-id' value='`$connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-id`' />\n<parameter name='tmp.ar.parent-service-instance-id' value='`$connection-attachment-topology-operation-input.allotted-resource-information.parent-service-instance-id`' />\n\n\n", + "comments": "", + "x": 743.9935607910156, + "y": 183.9934868812561, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "dd97f979.9eaae8", + "type": "comment", + "name": "set tmp ar-id to fetch resource from MDSAL", + "info": "", + "comments": "", + "x": 772.9538726806641, + "y": 148.02528285980225, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "ca7d47f1.45f358", + "type": "set", + "name": "set tmp.ar.self-link", + "xml": "<set>\n<parameter name='tmp.ar.self-link' value=\"`'restconf/config/GENERIC-RESOURCE-API:connection-attachment-allotted-resources/connection-attachment-allotted-resource/'\n + $tmp.ar.allotted-resource-id\n + '/allotted-resource-data/connection-attachment-topology/'` \" />\n\n", + "comments": "", + "x": 697.9934997558594, + "y": 276.99349212646484, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "da0989a1.945518", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 704.2553901672363, + "y": 364.6602210998535, + "z": "4de23974.164008", + "wires": [ + [] + ] + }, + { + "id": "7673909c.5a2e3", + "type": "execute", + "name": "generate allotted-resource url", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"`$prop.restapi.connection-attachment-allottedresource`\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url\"/>\n <parameter name=\"target\" value=\"{allotted-resource-id}\"/>\n <parameter name=\"replacement\" value=\"`$tmp.ar.allotted-resource-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 736.2554168701172, + "y": 452.66020250320435, + "z": "4de23974.164008", + "wires": [ + [] + ] + }, + { + "id": "8315ba14.0dc648", + "type": "comment", + "name": "Used for setting output to API Handler", + "info": "", + "comments": "", + "x": 751.9935302734375, + "y": 243.993501663208, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "3c54e364.ade40c", + "type": "comment", + "name": "Obtain different URL, template location etc", + "info": "For saving resource information to MDSAL & for AAI", + "comments": "", + "x": 769.9934959411621, + "y": 329.8823823928833, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "67f0dba1.ee0bc4", + "type": "comment", + "name": "Used to Get AR by id to MDSAL, same as self-link", + "info": "", + "comments": "", + "x": 795.9935150146484, + "y": 416.8823413848877, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "22c383eb.e7131c", + "type": "comment", + "name": "GET parent-service-data from mdsal to check existence of other End point", + "info": "", + "comments": "", + "x": 863.0003280639648, + "y": 871.5316228866577, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "810e2b6c.9f1de8", + "type": "for", + "name": "for pidx..mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource[]", + "xml": "<for index='pidx' start='0' end='`$mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1691.1849365234375, + "y": 1105.00425863266, + "z": "4de23974.164008", + "wires": [ + [ + "690c4edc.5f401" + ] + ] + }, + { + "id": "ecea06e3.25a318", + "type": "switchNode", + "name": "switch mdsal-psd.service-data.provided-allotted-resources_length", + "xml": "<switch test='`$mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource_length`'>\n", + "comments": "", + "outputs": 1, + "x": 842.1842956542969, + "y": 1111.718041419983, + "z": "4de23974.164008", + "wires": [ + [ + "384921c2.c1fd6e", + "9a1aea32.687248" + ] + ] + }, + { + "id": "e406b111.f8cad", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1292.4544582366943, + "y": 1151.7015271186829, + "z": "4de23974.164008", + "wires": [ + [ + "810e2b6c.9f1de8", + "9caa2a43.39ddb8" + ] + ] + }, + { + "id": "690c4edc.5f401", + "type": "switchNode", + "name": "switch allotted-resource-id", + "xml": "<switch test=\"`$mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource[$pidx].allotted-resource-id == $tmp.ar.allotted-resource-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 2141.296142578125, + "y": 1103.0041165351868, + "z": "4de23974.164008", + "wires": [ + [ + "e114982a.497cc8" + ] + ] + }, + { + "id": "ae3090d.67bd97", + "type": "set", + "name": "set tmp.ar.parent-service-instance-id", + "xml": "<set>\n<parameter name='tmp.ar.parent-service-instance-id' value=\"`$connection-attachment-topology-operation-input.allotted-resource-information.parent-service-instance-id` \" />\n\n", + "comments": "", + "x": 753.9687118530273, + "y": 907.0000677108765, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "7a941a2c.6b5534", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1133.968994140625, + "y": 985.0001826286316, + "z": "4de23974.164008", + "wires": [ + [ + "f87fdce1.8f426" + ] + ] + }, + { + "id": "616b8620.cffa38", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1125.8207969665527, + "y": 1020.066267490387, + "z": "4de23974.164008", + "wires": [ + [ + "c66c8fc5.25841" + ] + ] + }, + { + "id": "c66c8fc5.25841", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"Error: SOTN resource not found\" />\n \n", + "comments": "", + "x": 1300.969482421875, + "y": 1016.3336176872253, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "f87fdce1.8f426", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1284.968994140625, + "y": 983.0001826286316, + "z": "4de23974.164008", + "wires": [ + [] + ] + }, + { + "id": "ba29c90b.a2ba18", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 987.7307624816895, + "y": 1300.952815413475, + "z": "4de23974.164008", + "wires": [ + [ + "a31d3239.91ffa" + ] + ] + }, + { + "id": "a31d3239.91ffa", + "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=\"AAI failed\" />\n", + "comments": "", + "x": 1154.2546424865723, + "y": 1312.57188642025, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "30824867.291518", + "type": "failure", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 994.8260498046875, + "y": 1333.7147830724716, + "z": "4de23974.164008", + "wires": [ + [ + "a31d3239.91ffa" + ] + ] + }, + { + "id": "a9de303.1918dd", + "type": "comment", + "name": "TODO: Rework after confirmation from AAI", + "info": "", + "comments": "", + "x": 1119.1374282836914, + "y": 1251.8732151985168, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "3ac1cb4a.bcc3b4", + "type": "set", + "name": "set output to api handler", + "xml": "<set>\n<parameter name='allotted-resource-id' value='`$tmp.ar.allotted-resource-id`' />\n<parameter name='connection-attachment-object-path' value=\"`$tmp.ar.self-link`\"/>\n<parameter name='service-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $connection-attachment-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'`\"/>\n \n", + "comments": "", + "x": 720.5461502075195, + "y": 1264.8276824951172, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "e3865992.7e3fc8", + "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": 689.9592666625977, + "y": 1371.4435625076294, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "4734b343.474b9c", + "type": "execute", + "name": "execute RestApiCallNode - PUT AR by id", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='Delete' />\n <parameter name=\"responsePrefix\" value=\"mdsal-ar\" />\n\n", + "comments": "", + "outputs": 1, + "x": 769.6666641235352, + "y": 541.3333625793457, + "z": "4de23974.164008", + "wires": [ + [ + "6ade3c12.7994f4", + "e1a0637a.9ebf2", + "b8627e78.eb192" + ] + ] + }, + { + "id": "6ade3c12.7994f4", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 1009.3081665039062, + "y": 581.6649107933044, + "z": "4de23974.164008", + "wires": [ + [ + "a87c397.af463c8" + ] + ] + }, + { + "id": "e1a0637a.9ebf2", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1006.3081665039062, + "y": 538.1649084091187, + "z": "4de23974.164008", + "wires": [ + [ + "a87c397.af463c8" + ] + ] + }, + { + "id": "b8627e78.eb192", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1013.0582466125488, + "y": 497.5220036506653, + "z": "4de23974.164008", + "wires": [ + [ + "b1cd793e.5e9dc8" + ] + ] + }, + { + "id": "a87c397.af463c8", + "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=\"Error updating md-sal for connection-attachment-allotted-resource\" />\n", + "comments": "", + "x": 1165.058334350586, + "y": 559.9149088859558, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "b1cd793e.5e9dc8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1150.7141780853271, + "y": 497.7141833305359, + "z": "4de23974.164008", + "wires": [ + [] + ] + }, + { + "id": "bd3b6f56.caa65", + "type": "comment", + "name": "Delete Allotted Resource", + "info": "", + "comments": "", + "x": 717.0000457763672, + "y": 510.0000286102295, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "7503ea37.fd6c04", + "type": "for", + "name": "for cidx..service-data.consumed-allotted-resources.consumed-allotted-resource[]", + "xml": "<for index='cidx' start='0' end='`$service-data.consumed-allotted-resources.consumed-allotted-resource_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1667.00390625, + "y": 747.00390625, + "z": "4de23974.164008", + "wires": [ + [ + "f40e177b.0b9868" + ] + ] + }, + { + "id": "b32dbc09.e3051", + "type": "switchNode", + "name": "switch service-data.consumed-allotted-resources_length", + "xml": "<switch test='`$service-data.consumed-allotted-resources.consumed-allotted-resource_length`'>\n", + "comments": "", + "outputs": 1, + "x": 820.0032920837402, + "y": 707.71790766716, + "z": "4de23974.164008", + "wires": [ + [ + "c43d45d0.725118", + "b1813741.d0a008" + ] + ] + }, + { + "id": "c43d45d0.725118", + "type": "other", + "name": "outcome Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1144.1461563110352, + "y": 690.5753421783447, + "z": "4de23974.164008", + "wires": [ + [ + "494b4b44.f09f14" + ] + ] + }, + { + "id": "b1813741.d0a008", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1130.1461791992188, + "y": 753.5753309726715, + "z": "4de23974.164008", + "wires": [ + [ + "a0d3a795.96d2a8" + ] + ] + }, + { + "id": "a0d3a795.96d2a8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1290.2732696533203, + "y": 751.7013075351715, + "z": "4de23974.164008", + "wires": [ + [ + "7503ea37.fd6c04", + "8fef3486.f53f48" + ] + ] + }, + { + "id": "d3caba2b.d332f8", + "type": "set", + "name": "set consumed allotted resources for deletion", + "xml": "<set>\n<parameter name=\"service-data.consumed-allotted-resources.consumed-allotted-resource[$cidx].\" value=\"\" />\n<parameter name='service-data.consumed-allotted-resources.consumed-allotted-resource_length' value='`$service-data.consumed-allotted-resources.consumed-allotted-resource_length - 1`' />\n\n", + "comments": "", + "x": 776.8606262207031, + "y": 778.28955078125, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "f40e177b.0b9868", + "type": "switchNode", + "name": "switch allotted-resource-id", + "xml": "<switch test=\"`$service-data.consumed-allotted-resources.consumed-allotted-resource[$cidx].allotted-resource-id == $tmp.ar.allotted-resource-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 2105.1155166625977, + "y": 743.0040283203125, + "z": "4de23974.164008", + "wires": [ + [ + "5f3df777.af7b38" + ] + ] + }, + { + "id": "5f3df777.af7b38", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2300.925338745117, + "y": 742.4683527946472, + "z": "4de23974.164008", + "wires": [ + [ + "6d89866f.0d32c8" + ] + ] + }, + { + "id": "e9496ef8.3a3c5", + "type": "set", + "name": "set tmp.cidx", + "xml": "<set>\n<parameter name='tmp.cidx' value='`$cidx`' />\n", + "comments": "", + "x": 2616.2618713378906, + "y": 743.2246108055115, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "e2abacaf.782bf", + "type": "comment", + "name": "Delete consumed service consumed-allotted-resources in mdsal", + "info": "", + "comments": "", + "x": 831.0045623779297, + "y": 640.0038724095793, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "e6fb5c22.b2976", + "type": "comment", + "name": "This set resource will be deleted in MDSAL by provider code", + "info": "", + "comments": "", + "x": 821.337345123291, + "y": 744.781964302063, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "e963214.b61b0e", + "type": "comment", + "name": "Obtain the index of conusumed AR", + "info": "", + "comments": "", + "x": 743.7817535400391, + "y": 671.8927326202393, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "494b4b44.f09f14", + "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=\"Resource to be deleted doesn't exist in MDSAL.\" />\n", + "comments": "", + "x": 1306.00390625, + "y": 691.00390625, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "6d89866f.0d32c8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 2450.003936767578, + "y": 743.2539558410645, + "z": "4de23974.164008", + "wires": [ + [ + "e9496ef8.3a3c5" + ] + ] + }, + { + "id": "851fd9bb.09d5f8", + "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=\"resource to be deleted is not available in mdsal\" />\n", + "comments": "", + "x": 1760.25390625, + "y": 800.25390625, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "d98b4681.77ed08", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1622.75390625, + "y": 800.25390625, + "z": "4de23974.164008", + "wires": [ + [ + "851fd9bb.09d5f8" + ] + ] + }, + { + "id": "8fef3486.f53f48", + "type": "switchNode", + "name": "switch tmp.cidx ", + "xml": "<switch test=\"`$tmp.cidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1468.75390625, + "y": 800.25390625, + "z": "4de23974.164008", + "wires": [ + [ + "d98b4681.77ed08" + ] + ] + }, + { + "id": "3dd9973a.4ea7a8", + "type": "comment", + "name": "Delete provided service provided-allotted-resources in mdsal", + "info": "", + "comments": "", + "x": 817.5039215087891, + "y": 836.00390625, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "9a1aea32.687248", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1145.5041770935059, + "y": 1150.7540984153748, + "z": "4de23974.164008", + "wires": [ + [ + "e406b111.f8cad" + ] + ] + }, + { + "id": "384921c2.c1fd6e", + "type": "other", + "name": "outcome Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1162.5040969848633, + "y": 1062.7539324760437, + "z": "4de23974.164008", + "wires": [ + [ + "a35171cd.d90da" + ] + ] + }, + { + "id": "a35171cd.d90da", + "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=\"Resource to be deleted doesn't exist in MDSAL.\" />\n", + "comments": "", + "x": 1326.3616943359375, + "y": 1063.1824774742126, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "702543f3.ec4a8c", + "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=\"resource to be deleted is not available in mdsal\" />\n", + "comments": "", + "x": 1757.7539501190186, + "y": 1180.753936290741, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "f0b84e69.39376", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1620.2539501190186, + "y": 1180.753936290741, + "z": "4de23974.164008", + "wires": [ + [ + "702543f3.ec4a8c" + ] + ] + }, + { + "id": "9caa2a43.39ddb8", + "type": "switchNode", + "name": "switch tmp.pidx ", + "xml": "<switch test=\"`$tmp.pidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1466.2539501190186, + "y": 1180.753936290741, + "z": "4de23974.164008", + "wires": [ + [ + "f0b84e69.39376" + ] + ] + }, + { + "id": "e114982a.497cc8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2330.504367828369, + "y": 1100.7540946006775, + "z": "4de23974.164008", + "wires": [ + [ + "5dc21145.7fddd" + ] + ] + }, + { + "id": "9af67acf.f5f308", + "type": "set", + "name": "set tmp.pidx", + "xml": "<set>\n<parameter name='tmp.pidx' value='`$pidx`' />\n", + "comments": "", + "x": 2398.8404846191406, + "y": 1235.5101914405823, + "z": "4de23974.164008", + "wires": [] + }, + { + "id": "5dc21145.7fddd", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 2390.582820892334, + "y": 1171.539580821991, + "z": "4de23974.164008", + "wires": [ + [ + "9af67acf.f5f308" + ] + ] + }, + { + "id": "2036e77.af47618", + "type": "update", + "name": "update AAI allotted-resource", + "xml": "<delete plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" resource='allotted-resource' \n\t\tkey=\"customer.global-customer-id = $connection-attachment-topology-operation-input.service-information.global-customer-id AND\n\t\t\tservice-subscription.service-type = $connection-attachment-topology-operation-input.service-information.subscription-service-type AND\n\t\t\tservice-instance.service-instance-id = $connection-attachment-topology-operation-input.service-information.service-instance-id AND\n\t\t\tallotted-resource.id = $tmp.ar.allotted-resource-id\">\n", + "comments": "", + "outputs": 1, + "x": 733.2227554321289, + "y": 1320.754346370697, + "z": "4de23974.164008", + "wires": [ + [ + "ba29c90b.a2ba18", + "30824867.291518" + ] + ] + }, + { + "id": "61e84275.3bc6fc", + "type": "execute", + "name": "execute RestApiCallNode - get-resource parent service data", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-psd`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-psd\" />\n\n", + "comments": "", + "outputs": 1, + "x": 823.3334197998047, + "y": 1006.333366394043, + "z": "4de23974.164008", + "wires": [ + [ + "7a941a2c.6b5534", + "616b8620.cffa38" + ] + ] + }, + { + "id": "cfc2e19e.1fcac", + "type": "execute", + "name": "get parent-service-data tmp.ar-url-psd", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"/restconf/config/GENERIC-RESOURCE-API:services/service/{service-instance-id}/service-data\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url-psd\"/>\n <parameter name=\"target\" value=\"{service-instance-id}\"/>\n <parameter name=\"replacement\" value=\"`$tmp.ar.parent-service-instance-id`\"/>", + "comments": "", + "outputs": 1, + "x": 757.3333587646484, + "y": 964.3332056999207, + "z": "4de23974.164008", + "wires": [ + [] + ] + }, + { + "id": "cc50854b.9b5d18", + "type": "execute", + "name": "execute RestApiCallNode - delete-resource parent service data", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value=\"`$prop.controller.url + $tmp.ar-url-psd + '/provided-allotted-resources/provided-allotted-resource/' + $tmp.ar.allotted-resource-id`\" />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='DELETE' />\n <parameter name=\"responsePrefix\" value=\"mdsal-psd-delete\" />\n\n", + "comments": "", + "outputs": 1, + "x": 839.00390625, + "y": 1211.00390625, + "z": "4de23974.164008", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-device-param.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-device-param.json new file mode 100644 index 00000000..9d0c3722 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-device-param.json @@ -0,0 +1,551 @@ +[ + { + "id": "e671d21c.c380e", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 277.03125, + "y": 215.03125, + "z": "1814fac9.dedad5", + "wires": [ + [ + "f0968433.54c598" + ] + ] + }, + { + "id": "f0968433.54c598", + "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": 489.03125381469727, + "y": 287.0312671661377, + "z": "1814fac9.dedad5", + "wires": [ + [ + "7b5a64d7.27af4c" + ] + ] + }, + { + "id": "7b5a64d7.27af4c", + "type": "method", + "name": "sdwan-get-device-param", + "xml": "<method rpc='sdwan-get-device-param' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 477.0313720703125, + "y": 375.03125, + "z": "1814fac9.dedad5", + "wires": [ + [ + "9e54cfd4.f7511" + ] + ] + }, + { + "id": "9e54cfd4.f7511", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 484.03126525878906, + "y": 461.0313081741333, + "z": "1814fac9.dedad5", + "wires": [ + [ + "ea233a0.a925fc8" + ] + ] + }, + { + "id": "ea233a0.a925fc8", + "type": "for", + "name": "for each sdwan-get-request-input-param", + "xml": "<for index='idx' start='0' end='`$vnf-request-input.vnf-input-parameters.param_length`' >\n\n", + "comments": "", + "outputs": 1, + "x": 520.6980285644531, + "y": 543.697904586792, + "z": "1814fac9.dedad5", + "wires": [ + [ + "12792477.556d8c" + ] + ] + }, + { + "id": "12792477.556d8c", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 794.5315780639648, + "y": 458.0313220024109, + "z": "1814fac9.dedad5", + "wires": [ + [ + "767840a2.12ebe", + "4f1ecfa3.e420a", + "677e6bce.a725e4", + "c52d2d4b.f41f6", + "670874dc.6417bc", + "4166beff.b664d", + "a2380a78.a15bf8", + "af7f20a9.e338", + "3250af42.4d49", + "2508e2f5.08983e", + "a475c38.ffd7a4" + ] + ] + }, + { + "id": "767840a2.12ebe", + "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": 1002.0321960449219, + "y": 750.0318946838379, + "z": "1814fac9.dedad5", + "wires": [] + }, + { + "id": "677e6bce.a725e4", + "type": "switchNode", + "name": "switch name", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'name'`\">\n", + "comments": "", + "outputs": 1, + "x": 1030.0312843322754, + "y": 303.03130531311035, + "z": "1814fac9.dedad5", + "wires": [ + [ + "61f5048e.ac410c" + ] + ] + }, + { + "id": "61f5048e.ac410c", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1172.0312843322754, + "y": 304.03130531311035, + "z": "1814fac9.dedad5", + "wires": [ + [ + "e11fc0f2.f0b7" + ] + ] + }, + { + "id": "e11fc0f2.f0b7", + "type": "set", + "name": "set name", + "xml": "<set>\n<parameter name='prop.device.name' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1306.0312843322754, + "y": 304.631311416626, + "z": "1814fac9.dedad5", + "wires": [] + }, + { + "id": "4f1ecfa3.e420a", + "type": "switchNode", + "name": "switch esn", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'esn'`\">\n", + "comments": "", + "outputs": 1, + "x": 1022.8710298538208, + "y": 340.0312442779541, + "z": "1814fac9.dedad5", + "wires": [ + [ + "d4274273.0421a" + ] + ] + }, + { + "id": "d4274273.0421a", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1166.8710298538208, + "y": 340.0312442779541, + "z": "1814fac9.dedad5", + "wires": [ + [ + "ecaa4a78.97cd58" + ] + ] + }, + { + "id": "ecaa4a78.97cd58", + "type": "set", + "name": "set esn", + "xml": "<set>\n<parameter name='prop.device.esn' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1287.2044038772583, + "y": 339.4924259185791, + "z": "1814fac9.dedad5", + "wires": [] + }, + { + "id": "c52d2d4b.f41f6", + "type": "switchNode", + "name": "switch type", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'type'`\">\n", + "comments": "", + "outputs": 1, + "x": 1010.9264497756958, + "y": 414.99419593811035, + "z": "1814fac9.dedad5", + "wires": [ + [ + "66c8ac7e.f99d04" + ] + ] + }, + { + "id": "670874dc.6417bc", + "type": "switchNode", + "name": "switch systemIp", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'systemIp'`\">\n", + "comments": "", + "outputs": 1, + "x": 1010.9265079498291, + "y": 506.99421310424805, + "z": "1814fac9.dedad5", + "wires": [ + [ + "ce9aa789.cf24d8" + ] + ] + }, + { + "id": "66c8ac7e.f99d04", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1156.9264497756958, + "y": 414.99419593811035, + "z": "1814fac9.dedad5", + "wires": [ + [ + "fb4cb630.0c2d68" + ] + ] + }, + { + "id": "fb4cb630.0c2d68", + "type": "set", + "name": "set type", + "xml": "<set>\n<parameter name='prop.device.deviceModel' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1287.9264497756958, + "y": 414.594202041626, + "z": "1814fac9.dedad5", + "wires": [] + }, + { + "id": "ce9aa789.cf24d8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1156.926507949829, + "y": 503.99421310424805, + "z": "1814fac9.dedad5", + "wires": [ + [ + "e5052022.3061f" + ] + ] + }, + { + "id": "e5052022.3061f", + "type": "set", + "name": "set systemIp", + "xml": "<set>\n<parameter name='prop.device.systemIP' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1299.926507949829, + "y": 502.5942192077637, + "z": "1814fac9.dedad5", + "wires": [] + }, + { + "id": "a7ed8e98.b2bb8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1166.926507949829, + "y": 539.994213104248, + "z": "1814fac9.dedad5", + "wires": [ + [ + "a40c04f3.889538" + ] + ] + }, + { + "id": "4166beff.b664d", + "type": "switchNode", + "name": "switch description", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'description'`\">\n", + "comments": "", + "outputs": 1, + "x": 1012.9265079498291, + "y": 542.994213104248, + "z": "1814fac9.dedad5", + "wires": [ + [ + "a7ed8e98.b2bb8" + ] + ] + }, + { + "id": "a40c04f3.889538", + "type": "set", + "name": "set description", + "xml": "<set>\n<parameter name='prop.device.description' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1309.926507949829, + "y": 538.5942192077637, + "z": "1814fac9.dedad5", + "wires": [] + }, + { + "id": "a2380a78.a15bf8", + "type": "switchNode", + "name": "switch vendor", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'vendor'`\">\n", + "comments": "", + "outputs": 1, + "x": 1000.2597932815552, + "y": 589.9942474365234, + "z": "1814fac9.dedad5", + "wires": [ + [ + "6443e0a9.71388" + ] + ] + }, + { + "id": "6443e0a9.71388", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1168.2597513198853, + "y": 586.9941883087158, + "z": "1814fac9.dedad5", + "wires": [ + [ + "a3c7adc8.39913" + ] + ] + }, + { + "id": "a3c7adc8.39913", + "type": "set", + "name": "set vendor", + "xml": "<set>\n<parameter name='prop.device.vendor' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1311.2597513198853, + "y": 585.5941944122314, + "z": "1814fac9.dedad5", + "wires": [] + }, + { + "id": "af7f20a9.e338", + "type": "switchNode", + "name": "switch class", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'class'`\">\n", + "comments": "", + "outputs": 1, + "x": 1024.03125, + "y": 377.03125, + "z": "1814fac9.dedad5", + "wires": [ + [ + "9089a4f7.9d1f38" + ] + ] + }, + { + "id": "9089a4f7.9d1f38", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1168.03125, + "y": 377.03125, + "z": "1814fac9.dedad5", + "wires": [ + [ + "5a35e54e.7450dc" + ] + ] + }, + { + "id": "5a35e54e.7450dc", + "type": "set", + "name": "set class", + "xml": "<set>\n<parameter name='prop.device.class' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1288.3646240234375, + "y": 376.492431640625, + "z": "1814fac9.dedad5", + "wires": [] + }, + { + "id": "3250af42.4d49", + "type": "switchNode", + "name": "switch version", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'version'`\">\n", + "comments": "", + "outputs": 1, + "x": 1022.03125, + "y": 461.03125, + "z": "1814fac9.dedad5", + "wires": [ + [ + "9b60c77d.bb4828" + ] + ] + }, + { + "id": "9b60c77d.bb4828", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1168.03125, + "y": 458.03125, + "z": "1814fac9.dedad5", + "wires": [ + [ + "2e69598b.782ac6" + ] + ] + }, + { + "id": "2e69598b.782ac6", + "type": "set", + "name": "set version", + "xml": "<set>\n<parameter name='prop.device.version' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1311.03125, + "y": 456.6312561035156, + "z": "1814fac9.dedad5", + "wires": [] + }, + { + "id": "2508e2f5.08983e", + "type": "switchNode", + "name": "switch deviceId", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'deviceId'`\">\n", + "comments": "", + "outputs": 1, + "x": 1014.0313186645508, + "y": 637.0312986373901, + "z": "1814fac9.dedad5", + "wires": [ + [ + "fa6b8cf5.4b327" + ] + ] + }, + { + "id": "fa6b8cf5.4b327", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1170.031406402588, + "y": 633.031343460083, + "z": "1814fac9.dedad5", + "wires": [ + [ + "8e7714d.acaece8" + ] + ] + }, + { + "id": "8e7714d.acaece8", + "type": "set", + "name": "set deviceId", + "xml": "<set>\n<parameter name='prop.device.deviceId' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1308.3651542663574, + "y": 621.4924793243408, + "z": "1814fac9.dedad5", + "wires": [] + }, + { + "id": "a475c38.ffd7a4", + "type": "switchNode", + "name": "switch sdncCreate", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'sdncCreate'`\">\n", + "comments": "", + "outputs": 1, + "x": 1003.03125, + "y": 683.03125, + "z": "1814fac9.dedad5", + "wires": [ + [ + "a771c2de.63a74" + ] + ] + }, + { + "id": "a771c2de.63a74", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1159.031337738037, + "y": 679.0312948226929, + "z": "1814fac9.dedad5", + "wires": [ + [ + "665de992.e62df8" + ] + ] + }, + { + "id": "665de992.e62df8", + "type": "set", + "name": "set sdncCreate", + "xml": "<set>\n<parameter name='prop.device.sdncCreate' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1297.3650856018066, + "y": 667.4924306869507, + "z": "1814fac9.dedad5", + "wires": [] + } +]
\ No newline at end of file diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-saved-ar-param.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-saved-ar-param.json new file mode 100644 index 00000000..1db61c8c --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-saved-ar-param.json @@ -0,0 +1,199 @@ +[ + { + "id": "3dce5aae.d1aee6", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 156, + "y": 74, + "z": "15a92351.612ddd", + "wires": [ + [ + "aa9eff05.9e62c" + ] + ] + }, + { + "id": "aa9eff05.9e62c", + "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": 368.00000381469727, + "y": 146.0000171661377, + "z": "15a92351.612ddd", + "wires": [ + [ + "b770609e.14977" + ] + ] + }, + { + "id": "b770609e.14977", + "type": "method", + "name": "sdwan-get-saved-ar-param", + "xml": "<method rpc='sdwan-get-saved-ar-param' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 356.0001220703125, + "y": 234, + "z": "15a92351.612ddd", + "wires": [ + [ + "a63eeccf.054de" + ] + ] + }, + { + "id": "a63eeccf.054de", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 363.00001525878906, + "y": 320.0000581741333, + "z": "15a92351.612ddd", + "wires": [ + [ + "cef1b9ba.94d2a8" + ] + ] + }, + { + "id": "cef1b9ba.94d2a8", + "type": "for", + "name": "for each sdwan-get-request-input-param", + "xml": "<for index='idx' start='0' end='`$connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param_length`' >\n", + "comments": "", + "outputs": 1, + "x": 399.6667785644531, + "y": 402.666654586792, + "z": "15a92351.612ddd", + "wires": [ + [ + "c63bf491.f9e008" + ] + ] + }, + { + "id": "c63bf491.f9e008", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 664.5002822875977, + "y": 312.00004625320435, + "z": "15a92351.612ddd", + "wires": [ + [ + "2cd7df9b.ab1b", + "10f6f64f.edbe1a", + "95d1c864.f5bfb8" + ] + ] + }, + { + "id": "2cd7df9b.ab1b", + "type": "switchNode", + "name": "switch sdwanVpnName", + "xml": "<switch test=\"`$connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$idx].name == 'sdwanVpnName'`\">", + "comments": "", + "outputs": 1, + "x": 886.5000534057617, + "y": 216.0000514984131, + "z": "15a92351.612ddd", + "wires": [ + [ + "2a8eb492.677abc" + ] + ] + }, + { + "id": "2a8eb492.677abc", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1073.5000534057617, + "y": 212.0000514984131, + "z": "15a92351.612ddd", + "wires": [ + [ + "e2c23ccb.74de1" + ] + ] + }, + { + "id": "e2c23ccb.74de1", + "type": "set", + "name": "set sdwanVpnName", + "xml": "<set>\n<parameter name='prop.connection-attachment.sdwanVpnName' value='`$connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$idx].value`' />\n", + "comments": "", + "x": 1241.5000534057617, + "y": 212.6000576019287, + "z": "15a92351.612ddd", + "wires": [] + }, + { + "id": "10f6f64f.edbe1a", + "type": "switchNode", + "name": "switch role", + "xml": "<switch test=\"`$connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$idx].name == 'role'`\">", + "comments": "", + "outputs": 1, + "x": 849.0105400085449, + "y": 280.00007152557373, + "z": "15a92351.612ddd", + "wires": [ + [ + "ab95aeff.fed7f" + ] + ] + }, + { + "id": "ab95aeff.fed7f", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1074.010482788086, + "y": 271.0000514984131, + "z": "15a92351.612ddd", + "wires": [ + [ + "73eae7d6.c393c8" + ] + ] + }, + { + "id": "73eae7d6.c393c8", + "type": "set", + "name": "set role", + "xml": "<set>\n<parameter name='prop.connection-attachment.role' value='`$connection-attachment-ar.allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$idx].value`' />\n", + "comments": "", + "x": 1242.010482788086, + "y": 271.6000576019287, + "z": "15a92351.612ddd", + "wires": [] + }, + { + "id": "95d1c864.f5bfb8", + "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": 863.0002212524414, + "y": 344.000036239624, + "z": "15a92351.612ddd", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-site-param.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-site-param.json new file mode 100644 index 00000000..4224a324 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-site-param.json @@ -0,0 +1,895 @@ +[ + { + "id": "a907ba2f.81c9d8", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 97, + "y": 49, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "46194736.3f09f8" + ] + ] + }, + { + "id": "46194736.3f09f8", + "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": 275.00000381469727, + "y": 114.0000171661377, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "5cc16d87.a8a744" + ] + ] + }, + { + "id": "5cc16d87.a8a744", + "type": "method", + "name": "sdwan-get-site-param", + "xml": "<method rpc='sdwan-get-site-param' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 263.0001220703125, + "y": 202, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "2fcad45c.204f2c" + ] + ] + }, + { + "id": "2fcad45c.204f2c", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 270.00001525878906, + "y": 288.0000581741333, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "a59bab93.b75108" + ] + ] + }, + { + "id": "a59bab93.b75108", + "type": "for", + "name": "for each sdwan-get-request-input-param", + "xml": "<for index='idx' start='0' end='`$vnf-request-input.vnf-input-parameters.param_length`' >\n\n", + "comments": "", + "outputs": 1, + "x": 306.6667785644531, + "y": 370.666654586792, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "e896db23.035228" + ] + ] + }, + { + "id": "e896db23.035228", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 593.5003280639648, + "y": 288.00010204315186, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "17beedf5.3fa3a2", + "9658f5ce.551378", + "9f759735.d76cd8", + "9966cd8b.1697a", + "11d51c5.93463e4", + "8cb0a11.7bd686", + "5f3ab5eb.71688c", + "ca7858b9.e061c8", + "5ff23f08.f8215", + "5dd3c67.a478d38", + "4f1e9b40.0d5344", + "32f8d4e8.435a2c", + "3e3aefd6.843cc" + ] + ] + }, + { + "id": "17beedf5.3fa3a2", + "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": 795.001106262207, + "y": 721.0007653236389, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "9658f5ce.551378", + "type": "switchNode", + "name": "switch name", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'name'`\">\n", + "comments": "", + "outputs": 1, + "x": 813.0000381469727, + "y": 84.000075340271, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "1180c11c.4e5d3f" + ] + ] + }, + { + "id": "1180c11c.4e5d3f", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 955.0000381469727, + "y": 85.000075340271, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "c4a1ef6b.cb92a" + ] + ] + }, + { + "id": "c4a1ef6b.cb92a", + "type": "set", + "name": "set name", + "xml": "<set>\n<parameter name='prop.site.name' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1089.0000381469727, + "y": 85.60008144378662, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "9f759735.d76cd8", + "type": "switchNode", + "name": "switch name", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'name'`\">\n", + "comments": "", + "outputs": 1, + "x": 809.0001449584961, + "y": 175.00003337860107, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "d7f5a60b.3b5968" + ] + ] + }, + { + "id": "d7f5a60b.3b5968", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 987.0001583099365, + "y": 178.00003337860107, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "a9112d64.3441b" + ] + ] + }, + { + "id": "a9112d64.3441b", + "type": "set", + "name": "set name", + "xml": "<set>\n<parameter name='prop.site.name' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1134.0001678466797, + "y": 177.60002899169922, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "5dd3c67.a478d38", + "type": "switchNode", + "name": "switch type", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'type'`\">\n", + "comments": "", + "outputs": 1, + "x": 787.8958168029785, + "y": 472.9734830856323, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "abf743a3.45204" + ] + ] + }, + { + "id": "59ff6271.db05ec", + "type": "set", + "name": "set type", + "xml": "<set>\n<parameter name='prop.site.type' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n<parameter name='prop.site.sdwan' value='true' />", + "comments": "", + "x": 1439.8958778381348, + "y": 526.5734176635742, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "4f1e9b40.0d5344", + "type": "switchNode", + "name": "switch role", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'role'`\">\n", + "comments": "", + "outputs": 1, + "x": 786.8955307006836, + "y": 580.9735260009766, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "30daf487.0dff4c" + ] + ] + }, + { + "id": "30daf487.0dff4c", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 956.8955383300781, + "y": 590.9734888076782, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "685d8c42.5d6ca4" + ] + ] + }, + { + "id": "9966cd8b.1697a", + "type": "switchNode", + "name": "switch location-name", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'location-name'`\">\n", + "comments": "", + "outputs": 1, + "x": 831.8953323364258, + "y": 216.9733419418335, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "cc9616ce.430f58" + ] + ] + }, + { + "id": "cc9616ce.430f58", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 995.8955039978027, + "y": 216.9733428955078, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "ec0a2191.fba48" + ] + ] + }, + { + "id": "ec0a2191.fba48", + "type": "set", + "name": "set location-name", + "xml": "<set>\n<parameter name='prop.site.location-name' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1157.8955154418945, + "y": 216.5733995437622, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "11d51c5.93463e4", + "type": "switchNode", + "name": "switch address", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'address'`\">\n", + "comments": "", + "outputs": 1, + "x": 814.8953323364258, + "y": 252.97334575653076, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "c8c98295.92206" + ] + ] + }, + { + "id": "c8c98295.92206", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 984.8951797485352, + "y": 260.97334480285645, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "c8183604.5bf978" + ] + ] + }, + { + "id": "c8183604.5bf978", + "type": "set", + "name": "set location-address", + "xml": "<set>\n<parameter name='prop.site.location-address' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1172.8953552246094, + "y": 256.57332038879395, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "8cb0a11.7bd686", + "type": "switchNode", + "name": "switch postcode", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'postcode'`\">\n", + "comments": "", + "outputs": 1, + "x": 815.8953323364258, + "y": 294.9733066558838, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "164b8673.bea07a" + ] + ] + }, + { + "id": "164b8673.bea07a", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 980.8955039978027, + "y": 293.9733066558838, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "9880bf16.cc774" + ] + ] + }, + { + "id": "9880bf16.cc774", + "type": "set", + "name": "set location-postcode", + "xml": "<set>\n<parameter name='prop.site.location-postcode' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1167.8953552246094, + "y": 295.5733232498169, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "32f8d4e8.435a2c", + "type": "switchNode", + "name": "switch controlPoint", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'controlPoint'`\">\n", + "comments": "", + "outputs": 1, + "x": 805.7787551879883, + "y": 641.0003271102905, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "f9a2e4bf.e893d8" + ] + ] + }, + { + "id": "f9a2e4bf.e893d8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 967.778678894043, + "y": 637.0003499984741, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "8f9ebae3.f9c1f8" + ] + ] + }, + { + "id": "cdec920f.b6fa4", + "type": "set", + "name": "set role", + "xml": "<set>\n<parameter name='prop.site.role' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n\n", + "comments": "", + "x": 1339.7788467407227, + "y": 565.0002994537354, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "f025176.9eb87e8", + "type": "set", + "name": "set controlPoint", + "xml": "<set>\n<parameter name='prop.site.controlPoint' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n\n", + "comments": "", + "x": 1713.7786865234375, + "y": 684.0004281997681, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "95df77a9.2015c8", + "type": "execute", + "name": "execute split roles", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$prop.site.role`'/>\n<parameter name=\"regex\" value=\",\"/>\n<parameter name=\"ctx_memory_result_key\" value=\"prop.site.roles\"/>\n", + "comments": "", + "outputs": 1, + "x": 1367.445053100586, + "y": 614.0001821517944, + "z": "94b1afc3.a0dc", + "wires": [ + [] + ] + }, + { + "id": "685d8c42.5d6ca4", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1114.4451904296875, + "y": 594.0001821517944, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "cdec920f.b6fa4", + "95df77a9.2015c8" + ] + ] + }, + { + "id": "2b1dae74.689ae2", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1531.4451026916504, + "y": 704.0001840591431, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "f025176.9eb87e8", + "9399b06c.d4d46" + ] + ] + }, + { + "id": "9399b06c.d4d46", + "type": "execute", + "name": "execute split control points", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$prop.site.controlPoint`'/>\n<parameter name=\"regex\" value=\",\"/>\n<parameter name=\"ctx_memory_result_key\" value=\"prop.site.controlpoints\"/>\n", + "comments": "", + "outputs": 1, + "x": 1738.4451637268066, + "y": 736.0002880096436, + "z": "94b1afc3.a0dc", + "wires": [ + [] + ] + }, + { + "id": "5f3ab5eb.71688c", + "type": "switchNode", + "name": "switch latitude", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'latitude'`\">\n", + "comments": "", + "outputs": 1, + "x": 806.1116409301758, + "y": 339.00008392333984, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "17934d90.83f8b2" + ] + ] + }, + { + "id": "17934d90.83f8b2", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 982.1114883422852, + "y": 334.00004291534424, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "c1cb3429.151d98" + ] + ] + }, + { + "id": "c1cb3429.151d98", + "type": "set", + "name": "set location-latitude", + "xml": "<set>\n<parameter name='prop.site.location-latitude' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1156.1114959716797, + "y": 332.60005950927734, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "ca7858b9.e061c8", + "type": "switchNode", + "name": "switch longitude", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'longitude'`\">\n", + "comments": "", + "outputs": 1, + "x": 809.1116409301758, + "y": 379.0001268386841, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "8f39dcfa.83f0e" + ] + ] + }, + { + "id": "8f39dcfa.83f0e", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 981.1116485595703, + "y": 374.000168800354, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "257b4537.3c066a" + ] + ] + }, + { + "id": "257b4537.3c066a", + "type": "set", + "name": "set location-longitude", + "xml": "<set>\n<parameter name='prop.site.location-longitude' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1163.1115036010742, + "y": 377.60002040863037, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "44ed6e14.4ca7e", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 972.1116485595703, + "y": 424.00017166137695, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "e5a3e724.d41f08" + ] + ] + }, + { + "id": "2490dffe.947e9", + "type": "set", + "name": "set emails", + "xml": "<set>\n<parameter name='prop.site.emails' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1330.111343383789, + "y": 392.6000237464905, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "5ff23f08.f8215", + "type": "switchNode", + "name": "switch emails", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'emails'`\">\n", + "comments": "", + "outputs": 1, + "x": 799.1117172241211, + "y": 424.00017166137695, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "44ed6e14.4ca7e" + ] + ] + }, + { + "id": "b15996ac.1ac678", + "type": "execute", + "name": "execute split emails", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$prop.site.emails`'/>\n<parameter name=\"regex\" value=\",\"/>\n<parameter name=\"ctx_memory_result_key\" value=\"prop.site.email\"/>\n", + "comments": "", + "outputs": 1, + "x": 1355.777687072754, + "y": 438.99992656707764, + "z": "94b1afc3.a0dc", + "wires": [ + [] + ] + }, + { + "id": "e5a3e724.d41f08", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1134.1116561889648, + "y": 425.0000891685486, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "2490dffe.947e9", + "b15996ac.1ac678" + ] + ] + }, + { + "id": "3e3aefd6.843cc", + "type": "switchNode", + "name": "switch description", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'description'`\">\n", + "comments": "", + "outputs": 1, + "x": 814, + "y": 129, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "2b975758.fb5fb8" + ] + ] + }, + { + "id": "2b975758.fb5fb8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 956, + "y": 130, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "d08aa9c0.911c88" + ] + ] + }, + { + "id": "d08aa9c0.911c88", + "type": "set", + "name": "set description", + "xml": "<set>\n<parameter name='prop.site.description' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1102.0000762939453, + "y": 130.60002994537354, + "z": "94b1afc3.a0dc", + "wires": [] + }, + { + "id": "e1339417.d483a8", + "type": "other", + "name": "outcome Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1329.00004196167, + "y": 478.00005531311035, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "9d513524.b6af68" + ] + ] + }, + { + "id": "d2b9e663.ae14c8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1312.5003700256348, + "y": 526.0000152587891, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "59ff6271.db05ec" + ] + ] + }, + { + "id": "abf743a3.45204", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 925.8956985473633, + "y": 472.97340202331543, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "b178377b.d61118" + ] + ] + }, + { + "id": "b178377b.d61118", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1042.0000305175781, + "y": 475.00001430511475, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "bb291d8b.bac3a" + ] + ] + }, + { + "id": "bb291d8b.bac3a", + "type": "switchNode", + "name": "switch value", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].value`\">\n", + "comments": "", + "outputs": 1, + "x": 1172.0000343322754, + "y": 507.00001335144043, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "e1339417.d483a8", + "d2b9e663.ae14c8" + ] + ] + }, + { + "id": "9d513524.b6af68", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1468.0000457763672, + "y": 478.00001335144043, + "z": "94b1afc3.a0dc", + "wires": [ + [] + ] + }, + { + "id": "8f9ebae3.f9c1f8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1105, + "y": 650, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "c5f963e7.1c042" + ] + ] + }, + { + "id": "c5f963e7.1c042", + "type": "switchNode", + "name": "switch value", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].value`\">\n", + "comments": "", + "outputs": 1, + "x": 1235.0000038146973, + "y": 681.9999990463257, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "50780dd0.f16eb4", + "cef68888.786a28" + ] + ] + }, + { + "id": "50780dd0.f16eb4", + "type": "other", + "name": "outcome Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1392.0000114440918, + "y": 653.0000410079956, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "9c84c418.3907d8" + ] + ] + }, + { + "id": "cef68888.786a28", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1375.5003395080566, + "y": 701.0000009536743, + "z": "94b1afc3.a0dc", + "wires": [ + [ + "2b1dae74.689ae2" + ] + ] + }, + { + "id": "9c84c418.3907d8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1531.000015258789, + "y": 652.9999990463257, + "z": "94b1afc3.a0dc", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-tenant-auth.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-tenant-auth.json new file mode 100644 index 00000000..919c397a --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-tenant-auth.json @@ -0,0 +1,212 @@ +[ + { + "id": "30fe9468.76f32c", + "type": "get-resource", + "name": "get-resource service-subscription", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"service-subscription\" \n key= 'service-subscription.service-type = $service-data.vnfs.vnf[$tmp.vidx].vnf-data.service-information.subscription-service-type \n AND customer.global-customer-id = $service-data.vnfs.vnf[$tmp.vidx].vnf-data.service-information.global-customer-id'\n force=\"true\" pfx=\"tmp.AnAI-data-tenant\">\n \n", + "comments": "", + "outputs": 1, + "x": 632.8652648925781, + "y": 374.2938051223755, + "z": "97aa802d.404bc", + "wires": [ + [ + "a889eb39.2fcd08", + "483504b1.ecba4c" + ] + ] + }, + { + "id": "516f9f53.00463", + "type": "switchNode", + "name": "switch temp-ub-sub-account-id", + "xml": "<switch test='`$tmp.AnAI-data-tenant.temp-ub-sub-account-id`'>\n", + "comments": "", + "outputs": 1, + "x": 1044.8653564453125, + "y": 339.0438861846924, + "z": "97aa802d.404bc", + "wires": [ + [ + "f1e993a3.ae05f", + "6af3c030.9694c" + ] + ] + }, + { + "id": "f1e993a3.ae05f", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 1237.5798072814941, + "y": 313.043927192688, + "z": "97aa802d.404bc", + "wires": [ + [ + "be0f95e9.861918" + ] + ] + }, + { + "id": "6af3c030.9694c", + "type": "other", + "name": "Other", + "xml": "<outcome value='Other'>", + "comments": "", + "outputs": 1, + "x": 1237.8653717041016, + "y": 368.04388999938965, + "z": "97aa802d.404bc", + "wires": [ + [ + "3bf7a2b9.96247e" + ] + ] + }, + { + "id": "a889eb39.2fcd08", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 843.3651275634766, + "y": 347.0398635864258, + "z": "97aa802d.404bc", + "wires": [ + [ + "516f9f53.00463" + ] + ] + }, + { + "id": "483504b1.ecba4c", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 837.0437164306641, + "y": 399.2541751861572, + "z": "97aa802d.404bc", + "wires": [ + [ + "212060fe.4fc32" + ] + ] + }, + { + "id": "212060fe.4fc32", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 989.7937164306641, + "y": 399.0042362213135, + "z": "97aa802d.404bc", + "wires": [] + }, + { + "id": "b6a8c3c7.8bc03", + "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": 212.86526489257812, + "y": 101.43669128417969, + "z": "97aa802d.404bc", + "wires": [ + [ + "68fe5032.b2685" + ] + ] + }, + { + "id": "f788aa3b.dab3e8", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 133.57955932617188, + "y": 39.19858169555664, + "z": "97aa802d.404bc", + "wires": [ + [ + "b6a8c3c7.8bc03" + ] + ] + }, + { + "id": "672a5bc8.7ace04", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 366.81766510009766, + "y": 338.0081157684326, + "z": "97aa802d.404bc", + "wires": [ + [ + "30fe9468.76f32c", + "ef87bbc7.0bf428" + ] + ] + }, + { + "id": "68fe5032.b2685", + "type": "method", + "name": "method sdwan-get-tenant-auth", + "xml": "<method rpc='sdwan-get-tenant-auth' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 224.57955932617188, + "y": 195.7849235534668, + "z": "97aa802d.404bc", + "wires": [ + [ + "672a5bc8.7ace04" + ] + ] + }, + { + "id": "3bf7a2b9.96247e", + "type": "set", + "name": "set prop.tenant-id", + "xml": "<set>\n<parameter name='prop.tenant-id' value='`$tmp.AnAI-data-tenant.temp-ub-sub-account-id`' />\n", + "comments": "", + "x": 1415.7224426269531, + "y": 367.15094566345215, + "z": "97aa802d.404bc", + "wires": [] + }, + { + "id": "ef87bbc7.0bf428", + "type": "execute", + "name": "execute RestApiCallNode Create tenant auth", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/baseservice/tenants/authorization/' + $prop.tenant-id`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"tenant-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 660.3652954101562, + "y": 477.1866149902344, + "z": "97aa802d.404bc", + "wires": [ + [] + ] + }, + { + "id": "be0f95e9.861918", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1420.0080490112305, + "y": 312.86523628234863, + "z": "97aa802d.404bc", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-wan-param.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-wan-param.json new file mode 100644 index 00000000..dbd911b5 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-wan-param.json @@ -0,0 +1,727 @@ +[ + { + "id": "439a8dde.a54294", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 95, + "y": 67, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "885d7f3c.d7635" + ] + ] + }, + { + "id": "885d7f3c.d7635", + "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": 307.00000381469727, + "y": 139.0000171661377, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "715e2390.5052fc" + ] + ] + }, + { + "id": "715e2390.5052fc", + "type": "method", + "name": "sdwan-get-wan-param", + "xml": "<method rpc='sdwan-get-wan-param' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 295.0001220703125, + "y": 227, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "9d4aea5e.ef6f48" + ] + ] + }, + { + "id": "9d4aea5e.ef6f48", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 302.00001525878906, + "y": 313.0000581741333, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "6b944277.796b7c" + ] + ] + }, + { + "id": "6b944277.796b7c", + "type": "for", + "name": "for each sdwan-get-request-input-param", + "xml": "<for index='idx' start='0' end='`$vnf-request-input.vnf-input-parameters.param_length`' >\n\n", + "comments": "", + "outputs": 1, + "x": 338.6667785644531, + "y": 395.666654586792, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "37470750.b03bb8" + ] + ] + }, + { + "id": "37470750.b03bb8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 603.5002822875977, + "y": 305.00004625320435, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "7ac07f9d.deb5a", + "f51dc11b.c63d", + "390047c.48de9b8", + "19863ae8.c2ed05", + "a84af135.691bc", + "40a2ce76.5acb8", + "743ccae1.1d4ed4", + "da2a6768.0f1b08", + "937e7e7c.abe2b", + "d7a63229.55ffb", + "52f8113f.08404", + "dd33b364.8ca5b", + "edbcab35.7a44e8", + "d34e678f.eeed98", + "54c67966.b6a9c8" + ] + ] + }, + { + "id": "7ac07f9d.deb5a", + "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": 837.0006408691406, + "y": 671.0003890991211, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "a84af135.691bc", + "type": "switchNode", + "name": "switch deviceName", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'deviceName'`\">\n", + "comments": "", + "outputs": 1, + "x": 836.0000877380371, + "y": 220.00005626678467, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "e491e463.e045e8" + ] + ] + }, + { + "id": "e491e463.e045e8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1038.000494003296, + "y": 221.00012683868408, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "946002ca.03b1f" + ] + ] + }, + { + "id": "946002ca.03b1f", + "type": "set", + "name": "set deviceName", + "xml": "<set>\n<parameter name='prop.wan.deviceName' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1190.0005569458008, + "y": 218.60021209716797, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "d7a63229.55ffb", + "type": "switchNode", + "name": "switch vlanId", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'vlanId'`\">\n", + "comments": "", + "outputs": 1, + "x": 828.8402290344238, + "y": 406.00011920928955, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "d3962f14.7c3b3" + ] + ] + }, + { + "id": "d3962f14.7c3b3", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1013.8403167724609, + "y": 404.0001497268677, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "1b718234.ee52ce" + ] + ] + }, + { + "id": "1b718234.ee52ce", + "type": "set", + "name": "set vlanId", + "xml": "<set>\n<parameter name='prop.wan.vlanId' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1161.1742248535156, + "y": 401.4614086151123, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "390047c.48de9b8", + "type": "switchNode", + "name": "switch name", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'name'`\">\n", + "comments": "", + "outputs": 1, + "x": 833.8951606750488, + "y": 149.97332763671875, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "eba68f46.eff61" + ] + ] + }, + { + "id": "eba68f46.eff61", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1021.8952484130859, + "y": 150.97335720062256, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "7dfe338e.aacb9c" + ] + ] + }, + { + "id": "7dfe338e.aacb9c", + "type": "set", + "name": "set name", + "xml": "<set>\n<parameter name='prop.wan.name' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1171.8954982757568, + "y": 145.57343292236328, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "da2a6768.0f1b08", + "type": "switchNode", + "name": "switch ipAddress", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'ipAddress'`\">\n", + "comments": "", + "outputs": 1, + "x": 832.8954048156738, + "y": 332.37682247161865, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "d6f71f04.c7866" + ] + ] + }, + { + "id": "d6f71f04.c7866", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1026.895652770996, + "y": 333.37677097320557, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "65be0cd2.03f094" + ] + ] + }, + { + "id": "65be0cd2.03f094", + "type": "set", + "name": "set ipAddress", + "xml": "<set>\n<parameter name='prop.wan.ipAddress' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1179.2295608520508, + "y": 331.8380317687988, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "937e7e7c.abe2b", + "type": "switchNode", + "name": "switch providerIpAddress", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'providerIpAddress'`\">\n", + "comments": "", + "outputs": 1, + "x": 864.895565032959, + "y": 367.3767442703247, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "d6c02774.fd7328" + ] + ] + }, + { + "id": "d6c02774.fd7328", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1040.8958168029785, + "y": 367.3766899108887, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "86d16286.a90f7" + ] + ] + }, + { + "id": "86d16286.a90f7", + "type": "set", + "name": "set providerIpAddress", + "xml": "<set>\n<parameter name='prop.wan.providerIpAddress' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1207.2294006347656, + "y": 367.8378715515137, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "dd33b364.8ca5b", + "type": "switchNode", + "name": "switch inputBandwidth", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'inputBandwidth'`\">\n", + "comments": "", + "outputs": 1, + "x": 855.8953742980957, + "y": 479.3765506744385, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "8c8b118b.1a16e" + ] + ] + }, + { + "id": "8c8b118b.1a16e", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1032.8955726623535, + "y": 478.376615524292, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "52559144.3d725" + ] + ] + }, + { + "id": "52559144.3d725", + "type": "set", + "name": "set inputBandwidth", + "xml": "<set>\n<parameter name='prop.wan.inputBandwidth' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1240.2293224334717, + "y": 472.8377799987793, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "edbcab35.7a44e8", + "type": "switchNode", + "name": "switch outputBandwidth", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'outputBandwidth'`\">\n", + "comments": "", + "outputs": 1, + "x": 861.8953742980957, + "y": 518.3765506744385, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "9785a401.84f478" + ] + ] + }, + { + "id": "9785a401.84f478", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1045.8955707550049, + "y": 518.3766593933105, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "29877f00.328f52" + ] + ] + }, + { + "id": "29877f00.328f52", + "type": "set", + "name": "set outputBandwidth", + "xml": "<set>\n<parameter name='prop.wan.outputBandwidth' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1242.2293453216553, + "y": 511.8377628326416, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "19863ae8.c2ed05", + "type": "switchNode", + "name": "switch description", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'description'`\">\n", + "comments": "", + "outputs": 1, + "x": 840.8953132629395, + "y": 183.3767032623291, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "c907441.ebe9bb8" + ] + ] + }, + { + "id": "c907441.ebe9bb8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1032.8955574035645, + "y": 184.3767328262329, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "1126e041.4a24d" + ] + ] + }, + { + "id": "1126e041.4a24d", + "type": "set", + "name": "set description", + "xml": "<set>\n<parameter name='prop.wan.description' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1183.2295608520508, + "y": 183.8379421234131, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "743ccae1.1d4ed4", + "type": "switchNode", + "name": "switch portNumber", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'portNumber'`\">\n", + "comments": "", + "outputs": 1, + "x": 844.228572845459, + "y": 291.9943332672119, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "ebcd50b1.0b3d6" + ] + ] + }, + { + "id": "ebcd50b1.0b3d6", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1035.228744506836, + "y": 294.9943628311157, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "a1a449ce.d26a18" + ] + ] + }, + { + "id": "a1a449ce.d26a18", + "type": "set", + "name": "set portNumber", + "xml": "<set>\n<parameter name='prop.wan.portNumber' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1189.2290725708008, + "y": 294.5943775177002, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "40a2ce76.5acb8", + "type": "switchNode", + "name": "switch portType", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'portType'`\">\n", + "comments": "", + "outputs": 1, + "x": 834.1236763000488, + "y": 255.96763801574707, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "6ea5c966.7c8868" + ] + ] + }, + { + "id": "6ea5c966.7c8868", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1029.123764038086, + "y": 255.96766757965088, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "f40a6475.4548d8" + ] + ] + }, + { + "id": "f40a6475.4548d8", + "type": "set", + "name": "set portType", + "xml": "<set>\n<parameter name='prop.wan.portType' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1176.1240921020508, + "y": 256.56768226623535, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "90cd2791.ea5778", + "type": "set", + "name": "set transportnetworkName", + "xml": "<set>\n<parameter name='prop.wan.transportNetworkName' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1288.9998302459717, + "y": 437.38701152801514, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "c9247859.1c5528", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1077.6659240722656, + "y": 438.92592906951904, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "90cd2791.ea5778" + ] + ] + }, + { + "id": "52f8113f.08404", + "type": "switchNode", + "name": "switch transportnetworkName", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'transportNetworkName'`\">\n", + "comments": "", + "outputs": 1, + "x": 878.6657485961914, + "y": 442.9256591796875, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "c9247859.1c5528" + ] + ] + }, + { + "id": "f51dc11b.c63d", + "type": "switchNode", + "name": "switch id", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'id'`\">\n", + "comments": "", + "outputs": 1, + "x": 825.999340057373, + "y": 117.38670539855957, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "ebf6555a.abbb88" + ] + ] + }, + { + "id": "ebf6555a.abbb88", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1026.9994812011719, + "y": 115.3867359161377, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "1a802dda.2caca2" + ] + ] + }, + { + "id": "1a802dda.2caca2", + "type": "set", + "name": "set id", + "xml": "<set>\n<parameter name='prop.wan.id' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1168.999828338623, + "y": 110.98684310913086, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "d34e678f.eeed98", + "type": "switchNode", + "name": "switch devicePortId", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'devicePortId'`\">\n", + "comments": "", + "outputs": 1, + "x": 847.0000610351562, + "y": 563.0000381469727, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "67b4d68f.872058" + ] + ] + }, + { + "id": "67b4d68f.872058", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1046.0002269744873, + "y": 557.000114440918, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "8e605ff5.22a2d" + ] + ] + }, + { + "id": "8e605ff5.22a2d", + "type": "set", + "name": "set devicePortId", + "xml": "<set>\n<parameter name='prop.wan.devicePortId' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1245.3339710235596, + "y": 556.4612121582031, + "z": "1a0d2992.253ae6", + "wires": [] + }, + { + "id": "54c67966.b6a9c8", + "type": "switchNode", + "name": "switch wanPortId", + "xml": "<switch test=\"`$vnf-request-input.vnf-input-parameters.param[$idx].name == 'wanPortId'`\">\n", + "comments": "", + "outputs": 1, + "x": 837.0000610351562, + "y": 599.0000400543213, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "cda45636.504778" + ] + ] + }, + { + "id": "cda45636.504778", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1048.0002250671387, + "y": 592.0001173019409, + "z": "1a0d2992.253ae6", + "wires": [ + [ + "651ea7f2.7fd2a8" + ] + ] + }, + { + "id": "651ea7f2.7fd2a8", + "type": "set", + "name": "set wanPortId", + "xml": "<set>\n<parameter name='prop.wan.wanPortId' value='`$vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1245.3339710235596, + "y": 596.4612121582031, + "z": "1a0d2992.253ae6", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-activate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-activate.json new file mode 100644 index 00000000..3f7cbdc4 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-activate.json @@ -0,0 +1,847 @@ +[ + { + "id": "b728dcab.e2e08", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 93, + "y": 47, + "z": "4c287bc.f107e84", + "wires": [ + [ + "f1013e83.11195" + ] + ] + }, + { + "id": "f1013e83.11195", + "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": 279.00000381469727, + "y": 119.0000171661377, + "z": "4c287bc.f107e84", + "wires": [ + [ + "4636719f.41274" + ] + ] + }, + { + "id": "4636719f.41274", + "type": "method", + "name": "method sdwan-network-topology-operation-activate", + "xml": "<method rpc='sdwan-network-topology-operation-activate' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 267.0001220703125, + "y": 207, + "z": "4c287bc.f107e84", + "wires": [ + [ + "c7a7aadf.8ed488" + ] + ] + }, + { + "id": "c7a7aadf.8ed488", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 441.00001525878906, + "y": 315.0000591278076, + "z": "4c287bc.f107e84", + "wires": [ + [ + "98d3b92f.70fc48", + "189da6d2.5a6819", + "e988ff0f.b5aae", + "e4aad21c.e7ff7", + "39e02c84.3177e4", + "b96459be.6fd7a8", + "747d96dd.f43d58", + "39860903.53b456", + "69af4cc7.202f04", + "bc16f27b.ec50b", + "29cb6e2b.ecafd2", + "f71b9190.340d8", + "3eb35468.4702ac", + "d3877bd.f214188", + "73dbb3c3.f1d1fc", + "9bf6657f.dd37a8" + ] + ] + }, + { + "id": "98d3b92f.70fc48", + "type": "call", + "name": "call GENERIC-RESOURCE-API:validate-sdwan-network-input-parameters", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='validate-sdwan-network-input-parameters' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 899.3889007568359, + "y": 64, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + }, + { + "id": "189da6d2.5a6819", + "type": "record", + "name": "record", + "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"sdwan-network-topology-operation-activate\"/>\n<parameter name=\"field3\" value=\"SDWAN-Activate\"/>\n", + "comments": "", + "outputs": 1, + "x": 699.5555992126465, + "y": 117.77785301208496, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + }, + { + "id": "e988ff0f.b5aae", + "type": "set", + "name": "set networkId and network-object-path", + "xml": "<set>\n<parameter name='networkId' value='`$network-topology-operation-input.network-information.network-id`' />\n<parameter name=\"network-object-path\" value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/' + $network-topology-operation-input.service-information.service-instance-id + '/service-data/networks/network/' + $network-topology-operation-input.network-information.network-id + '/network-data/'` \" />", + "comments": "", + "x": 786.5558776855469, + "y": 1040.313469171524, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "e4aad21c.e7ff7", + "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": 708.3336791992188, + "y": 1229.868889093399, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "39e02c84.3177e4", + "type": "set", + "name": "set network-level-oper-status", + "xml": "<set>\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.order-status' value='Active' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.last-rpc-action' value='`$network-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.last-action' value='`$network-topology-operation-input.request-information.request-action`' />", + "comments": "", + "x": 753.4447937011719, + "y": 1101.5356438159943, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "b96459be.6fd7a8", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 731.8577041625977, + "y": 170.77788925170898, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + }, + { + "id": "747d96dd.f43d58", + "type": "update", + "name": "update SDWAN VPN status to AAI", + "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='sdwan-vpn' \n key='sdwan-vpn.sdwan-vpn-id = $network-topology-operation-input.network-information.network-id' >\n<parameter name='sdwan-vpn-id' value='`$network-topology-operation-input.network-information.network-id`' />\n<parameter name='operational-status' value='Active' />\n<parameter name='tenanat-id' value='`$prop.tenant-id`' />\n<parameter name='vpn-id' value='`$prop.vpn-id`' />", + "comments": "", + "outputs": 1, + "x": 770.6635093688965, + "y": 1164.2388553619385, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + }, + { + "id": "39860903.53b456", + "type": "set", + "name": "set network in service-data", + "xml": "<set>\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.sdnc-request-header.' value='`$network-topology-operation-input.sdnc-request-header.`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.request-information.' value='`$network-topology-operation-input.request-information.`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.service-information.' value='`$network-topology-operation-input.service-information.`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-information.' value='`$network-topology-operation-input.network-information.`' />", + "comments": "", + "x": 747.0004081726074, + "y": 987.0913031101227, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "69af4cc7.202f04", + "type": "for", + "name": "for each network-input-parameters", + "xml": "<for index='idx' start='0' end='`$ctx.network-data.network-request-input.network-input-parameters.param_length`' >\n", + "comments": "", + "outputs": 1, + "x": 784, + "y": 241.00390753149986, + "z": "4c287bc.f107e84", + "wires": [ + [ + "e4f0bee4.ba4a3" + ] + ] + }, + { + "id": "e4f0bee4.ba4a3", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1040.8334312438965, + "y": 175.33725866675377, + "z": "4c287bc.f107e84", + "wires": [ + [ + "9e11c248.9eb9d", + "9793f672.805878" + ] + ] + }, + { + "id": "9e11c248.9eb9d", + "type": "switchNode", + "name": "switch name", + "xml": "<switch test=\"`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].name == 'name'`\">\n", + "comments": "", + "outputs": 1, + "x": 1231.8334922790527, + "y": 171.33729109168053, + "z": "4c287bc.f107e84", + "wires": [ + [ + "8c9ad24.52d233" + ] + ] + }, + { + "id": "8c9ad24.52d233", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1405.8336181640625, + "y": 171.3372949063778, + "z": "4c287bc.f107e84", + "wires": [ + [ + "360dce92.bcd8b2" + ] + ] + }, + { + "id": "360dce92.bcd8b2", + "type": "set", + "name": "set name", + "xml": "<set>\n<parameter name='prop.name' value='`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1568.8335037231445, + "y": 170.93728956580162, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "f71b9190.340d8", + "type": "get-resource", + "name": "get-resource esr-thirdparty-sdnc", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = 'SDWANController' AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n", + "comments": "", + "outputs": 1, + "x": 778, + "y": 350.00390625, + "z": "4c287bc.f107e84", + "wires": [ + [ + "35c5eced.422b74", + "5db3feca.9679c", + "84542dcd.8c846" + ] + ] + }, + { + "id": "35c5eced.422b74", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1023, + "y": 296.00390753149986, + "z": "4c287bc.f107e84", + "wires": [ + [ + "b858bea3.dfbd9" + ] + ] + }, + { + "id": "5db3feca.9679c", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 1026.490966796875, + "y": 343.5779431760311, + "z": "4c287bc.f107e84", + "wires": [ + [ + "ea674168.c4155" + ] + ] + }, + { + "id": "84542dcd.8c846", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1021.823974609375, + "y": 384.91125616431236, + "z": "4c287bc.f107e84", + "wires": [ + [ + "95ebd94d.24be88" + ] + ] + }, + { + "id": "b858bea3.dfbd9", + "type": "set", + "name": "set controller data", + "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n", + "comments": "", + "x": 1220.5000610351562, + "y": 284.00390753149986, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "ea674168.c4155", + "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1203.0623779296875, + "y": 331.8636792600155, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "95ebd94d.24be88", + "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1209.5965309143066, + "y": 380.350448936224, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "3eb35468.4702ac", + "type": "execute", + "name": "execute RestApiCallNode Get token", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>", + "comments": "", + "outputs": 1, + "x": 786, + "y": 461.00390625, + "z": "4c287bc.f107e84", + "wires": [ + [ + "d801cca4.51d79", + "c1258051.e7f45" + ] + ] + }, + { + "id": "d801cca4.51d79", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1025.000072479248, + "y": 439.00393772125244, + "z": "4c287bc.f107e84", + "wires": [ + [ + "f717dae9.6ebf18" + ] + ] + }, + { + "id": "c1258051.e7f45", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1017.250072479248, + "y": 492.6468210220337, + "z": "4c287bc.f107e84", + "wires": [ + [ + "d37810c8.811c7" + ] + ] + }, + { + "id": "f717dae9.6ebf18", + "type": "set", + "name": "set token-id", + "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n", + "comments": "", + "x": 1175, + "y": 440.00390625, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "d37810c8.811c7", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1170.000072479248, + "y": 492.39688205718994, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "9793f672.805878", + "type": "switchNode", + "name": "switch topology", + "xml": "<switch test=\"`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].name == 'topology'`\">\n", + "comments": "", + "outputs": 1, + "x": 1230.25, + "y": 224.00390753149986, + "z": "4c287bc.f107e84", + "wires": [ + [ + "cfe36c58.4801f" + ] + ] + }, + { + "id": "cfe36c58.4801f", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1404.2501258850098, + "y": 224.00391134619713, + "z": "4c287bc.f107e84", + "wires": [ + [ + "3cd1ca28.cc1526" + ] + ] + }, + { + "id": "3cd1ca28.cc1526", + "type": "set", + "name": "set topology", + "xml": "<set>\n<parameter name='prop.topology' value='`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1567.2500114440918, + "y": 223.60390600562096, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "d3877bd.f214188", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 707.7500457763672, + "y": 707.0040292739868, + "z": "4c287bc.f107e84", + "wires": [ + [ + "7110150.fd1e8ec" + ] + ] + }, + { + "id": "7110150.fd1e8ec", + "type": "execute", + "name": "execute RestApiCallNode Create network orchestration", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-network-orchestration.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/network-orchestration-resources'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"orchestration-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 1028.2501525878906, + "y": 696.0041122436523, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + }, + { + "id": "bc16f27b.ec50b", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 710.2500152587891, + "y": 769.0039575994015, + "z": "4c287bc.f107e84", + "wires": [ + [ + "39c058d0.1d59d8", + "4d96e12b.86876", + "50f144c4.b6b2ac" + ] + ] + }, + { + "id": "4d96e12b.86876", + "type": "execute", + "name": "execute RestApiCallNode Create vpn", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-vpn-create.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/vpn'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 981.7500610351562, + "y": 759.0040815770626, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + }, + { + "id": "39c058d0.1d59d8", + "type": "set", + "name": "set prop.vpn-id and prop.vpn1Id", + "xml": "<set>\n<parameter name='prop.vpn-id' value='`$vpn-result.success[0].id`' />\n<parameter name='prop.vpn1Id' value='`$vpn-result.success[0].id`' />\n", + "comments": "", + "x": 977.7502174377441, + "y": 811.0041809082031, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "50f144c4.b6b2ac", + "type": "execute", + "name": "execute RestApiCallNode Create vpn topology", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-vpn-topology-create.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/' + $prop.vpn-id + '/topology'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 1009.2500648498535, + "y": 863.0039558410645, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + }, + { + "id": "29cb6e2b.ecafd2", + "type": "set", + "name": "set tenant-id to service-data", + "xml": "<set>\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param[$network-topology-operation-input.network-request-input.network-input-parameters.param_length].name' value='tenant-id' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param[$network-topology-operation-input.network-request-input.network-input-parameters.param_length].value' value='`$prop.tenant-id`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param_length' value='`$network-topology-operation-input.network-request-input.network-input-parameters.param_length + 1`' />", + "comments": "", + "x": 745.2501525878906, + "y": 904.7540903091431, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "9bf6657f.dd37a8", + "type": "get-resource", + "name": "get-resource service-subscription", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"service-subscription\" \n key= 'service-subscription.service-type = $service-data.networks.network[$tmp.nidx].network-data.service-information.subscription-service-type \n AND customer.global-customer-id = $service-data.networks.network[$tmp.nidx].network-data.service-information.global-customer-id'\n force=\"true\" pfx=\"tmp.AnAI-data\">\n \n", + "comments": "", + "outputs": 1, + "x": 762.0715408325195, + "y": 611.6825218200684, + "z": "4c287bc.f107e84", + "wires": [ + [ + "fbe99e6e.4017e", + "457e75b8.5e8e7c" + ] + ] + }, + { + "id": "ba35b9dd.539428", + "type": "switchNode", + "name": "switch temp-ub-sub-account-id", + "xml": "<switch test='`$tmp.AnAI-data.temp-ub-sub-account-id`'>\n", + "comments": "", + "outputs": 1, + "x": 1174.071632385254, + "y": 576.4326028823853, + "z": "4c287bc.f107e84", + "wires": [ + [ + "76b51f1a.0801", + "efbb35c.45c87c8" + ] + ] + }, + { + "id": "76b51f1a.0801", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 1366.78609085083, + "y": 550.432635307312, + "z": "4c287bc.f107e84", + "wires": [ + [ + "a2a000be.ae6b" + ] + ] + }, + { + "id": "efbb35c.45c87c8", + "type": "other", + "name": "Other", + "xml": "<outcome value='Other'>", + "comments": "", + "outputs": 1, + "x": 1367.071647644043, + "y": 605.4326066970825, + "z": "4c287bc.f107e84", + "wires": [ + [ + "864dc517.ee5aa8" + ] + ] + }, + { + "id": "5407a489.2a82dc", + "type": "set", + "name": "set prop.tenant-id", + "xml": "<set>\n<parameter name='prop.tenant-id' value='`$tmp.AnAI-data.temp-ub-sub-account-id`' />\n", + "comments": "", + "x": 1614.5002403259277, + "y": 690.5754070281982, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "a2a000be.ae6b", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1506.2499885559082, + "y": 550.7539038658142, + "z": "4c287bc.f107e84", + "wires": [ + [ + "d533a7b3.2b7aa8", + "68abe37a.a97c3c", + "ebb2a924.447738", + "3179cec4.da2412", + "df370d35.edba", + "5f23c930.bf33c8", + "d5098f7f.2d7c" + ] + ] + }, + { + "id": "3179cec4.da2412", + "type": "set", + "name": "set prop.customer-id", + "xml": "<set>\n<parameter name='prop.customer-id' value='`$ctx.network-data.service-information.global-customer-id`' />\n", + "comments": "", + "x": 1717.8930969238281, + "y": 361.3254642486572, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "d533a7b3.2b7aa8", + "type": "execute", + "name": "execute RestApiCallNode Create tenant", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-tenant.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/baseservice/tenants'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"tenant-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 1776.8929138183594, + "y": 491.89675521850586, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + }, + { + "id": "68abe37a.a97c3c", + "type": "set", + "name": "set prop.tenant-id", + "xml": "<set>\n<parameter name='prop.tenant-id' value='`$tenant-result.data.tenantId`' />\n", + "comments": "", + "x": 1729.7502326965332, + "y": 616.753984451294, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "ebb2a924.447738", + "type": "execute", + "name": "execute RestApiCallNode Create tenant auth", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/baseservice/tenants/authorization/' + $prop.tenant-id`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"tenant-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 1797.250228881836, + "y": 652.503984451294, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + }, + { + "id": "df370d35.edba", + "type": "get-resource", + "name": "update-resource customer-id in service-subscription", + "xml": "<update plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"service-subscription\" \n key= 'service-subscription.service-type = $service-data.networks.network[$tmp.nidx].network-data.service-information.subscription-service-type \n AND customer.global-customer-id = $service-data.networks.network[$tmp.nidx].network-data.service-information.global-customer-id'>\n<parameter name='temp-ub-sub-account-id' value='`$tenant-result.data.tenantId`' />\n<!--parameter name='temp-ub-sub-account-id' value='`$prop.customer-id`' /-->\n\n\n", + "comments": "", + "outputs": 1, + "x": 1821.1786041259766, + "y": 552.8968715667725, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + }, + { + "id": "fbe99e6e.4017e", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 972.571403503418, + "y": 584.4285802841187, + "z": "4c287bc.f107e84", + "wires": [ + [ + "ba35b9dd.539428" + ] + ] + }, + { + "id": "457e75b8.5e8e7c", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 966.2499923706055, + "y": 636.6428918838501, + "z": "4c287bc.f107e84", + "wires": [ + [ + "df05b13b.b352c" + ] + ] + }, + { + "id": "df05b13b.b352c", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1118.9999923706055, + "y": 636.3929529190063, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "73dbb3c3.f1d1fc", + "type": "set", + "name": "set vpn-id to service-data", + "xml": "<set>\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param[$network-topology-operation-input.network-request-input.network-input-parameters.param_length].name' value='vpn-id' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param[$network-topology-operation-input.network-request-input.network-input-parameters.param_length].value' value='`$prop.vpn-id`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param_length' value='`$network-topology-operation-input.network-request-input.network-input-parameters.param_length + 1`' />", + "comments": "", + "x": 743.5000762939453, + "y": 942.5039682388306, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "864dc517.ee5aa8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1425.7224044799805, + "y": 688.5795984268188, + "z": "4c287bc.f107e84", + "wires": [ + [ + "5407a489.2a82dc", + "75fd5cb0.1720a4" + ] + ] + }, + { + "id": "75fd5cb0.1720a4", + "type": "execute", + "name": "execute RestApiCallNode Create tenant auth", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/baseservice/tenants/authorization/' + $prop.tenant-id`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"tenant-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 1697.1510009765625, + "y": 737.1510009765625, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + }, + { + "id": "5f23c930.bf33c8", + "type": "set", + "name": "set prop.userAccount", + "xml": "<set>\n<parameter name='prop.userAccount' value='`$tmp.userAccountEmail`' />\n<parameter name='prop.userEmail' value='`$tmp.userAccountEmail`' />", + "comments": "", + "x": 1718, + "y": 439, + "z": "4c287bc.f107e84", + "wires": [] + }, + { + "id": "d5098f7f.2d7c", + "type": "execute", + "name": "execute concat customer-id and @test.com", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='concat' >\n <parameter name=\"source\" value='`$prop.customer-id`'/>\n <parameter name=\"outputPath\" value=\"tmp.userAccountEmail\"/>\n <parameter name=\"target\" value=\"@test.com\"/>\n\n\n", + "comments": "", + "outputs": 1, + "x": 1793.0038757324219, + "y": 403.003942489624, + "z": "4c287bc.f107e84", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-create.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-create.json new file mode 100644 index 00000000..b7276f20 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-create.json @@ -0,0 +1,481 @@ +[ + { + "id": "e738f63f.208ea8", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 87.00390625, + "y": 55.857561140786856, + "z": "d1658b32.d98238", + "wires": [ + [ + "80341a9d.8eb738" + ] + ] + }, + { + "id": "80341a9d.8eb738", + "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": 341.50390625, + "y": 55.857561140786856, + "z": "d1658b32.d98238", + "wires": [ + [ + "5110d08c.83594" + ] + ] + }, + { + "id": "5110d08c.83594", + "type": "method", + "name": "sdwan-network-topology-operation-create", + "xml": "<method rpc='sdwan-network-topology-operation-create' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 340.50390625, + "y": 155.85756114078686, + "z": "d1658b32.d98238", + "wires": [ + [ + "a22e3b13.76c488" + ] + ] + }, + { + "id": "a22e3b13.76c488", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 480.50390625, + "y": 255.85756114078686, + "z": "d1658b32.d98238", + "wires": [ + [ + "f691075.4d857f8", + "cb88cbb7.42bd98", + "8ba6b398.46ed6", + "346ae50a.91fcda", + "9b181769.a4b628", + "e7358faf.a402d", + "dbb7121b.abe6a", + "fdf26bca.f03768", + "a7873db9.8b28e", + "d8cec38f.bc599", + "74be5192.2ede4" + ] + ] + }, + { + "id": "f691075.4d857f8", + "type": "call", + "name": "call GENERIC-RESOURCE-API:validate-sdwan-network-input-parameters", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='validate-sdwan-network-input-parameters' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 910.5039176940918, + "y": 73.63531306339428, + "z": "d1658b32.d98238", + "wires": [ + [] + ] + }, + { + "id": "cb88cbb7.42bd98", + "type": "record", + "name": "record", + "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"sdwan-network-topology-operation-create\"/>\n<parameter name=\"field3\" value=\"SDWAN-Config\"/>\n", + "comments": "", + "outputs": 1, + "x": 704.0595626831055, + "y": 251.07977294921875, + "z": "d1658b32.d98238", + "wires": [ + [] + ] + }, + { + "id": "8ba6b398.46ed6", + "type": "execute", + "name": "execute generate prop.sdwan.network-id", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='generateUUID' >\n<parameter name=\"ctx-destination\" value=\"prop.sdwan.network-id\"/>\n", + "comments": "", + "outputs": 1, + "x": 806.5039138793945, + "y": 117.63531541824341, + "z": "d1658b32.d98238", + "wires": [ + [] + ] + }, + { + "id": "346ae50a.91fcda", + "type": "switchNode", + "name": "switch service-data.networks_length", + "xml": "<switch test='`$service-data.networks.network_length`'>\n", + "comments": "", + "outputs": 1, + "x": 795.0595626831055, + "y": 211.07977294921875, + "z": "d1658b32.d98238", + "wires": [ + [ + "5636a9a3.7efe68", + "b63f0739.980f28" + ] + ] + }, + { + "id": "5636a9a3.7efe68", + "type": "other", + "name": "Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1024.0595626831055, + "y": 191.07977294921875, + "z": "d1658b32.d98238", + "wires": [ + [ + "c36e2515.dba218" + ] + ] + }, + { + "id": "b63f0739.980f28", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1024.0595626831055, + "y": 231.07977294921875, + "z": "d1658b32.d98238", + "wires": [ + [ + "75983c07.a5a874" + ] + ] + }, + { + "id": "c36e2515.dba218", + "type": "set", + "name": "set nidx", + "xml": "<set>\n<parameter name='nidx' value='0' />\n", + "comments": "", + "x": 1166.5595626831055, + "y": 191.07977294921875, + "z": "d1658b32.d98238", + "wires": [] + }, + { + "id": "99e46d9c.cb058", + "type": "set", + "name": "set nidx", + "xml": "<set>\n<parameter name='nidx' value='`$service-data.networks.network_length`' />\n", + "comments": "", + "x": 1300.1150817871094, + "y": 192.63538265228271, + "z": "d1658b32.d98238", + "wires": [] + }, + { + "id": "9b181769.a4b628", + "type": "set", + "name": "set network in service-data", + "xml": "<set>\n<parameter name='service-data.networks.network[$nidx].network-id' value='`$prop.sdwan.network-id`' />\n<parameter name='service-data.networks.network[$nidx].network-data.sdnc-request-header.' value='`$network-topology-operation-input.sdnc-request-header.`' />\n<parameter name='service-data.networks.network[$nidx].network-data.request-information.' value='`$network-topology-operation-input.request-information.`' />\n<parameter name='service-data.networks.network[$nidx].network-data.service-information.' value='`$network-topology-operation-input.service-information.`' />\n<parameter name='service-data.networks.network[$nidx].network-data.network-information.' value='`$network-topology-operation-input.network-information.`' />\n<parameter name='service-data.networks.network[$nidx].network-data.network-request-input.' value='`$network-topology-operation-input.network-request-input.`' />\n<parameter name='service-data.networks.network_length' value='`$nidx+1`' />\n\n", + "comments": "", + "x": 765.5595626831055, + "y": 291.07977294921875, + "z": "d1658b32.d98238", + "wires": [] + }, + { + "id": "e7358faf.a402d", + "type": "set", + "name": "set networkId and network-object-path", + "xml": "<set>\n<parameter name='networkId' value='`$prop.sdwan.network-id`' />\n<parameter name=\"network-object-path\" value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/' + $network-topology-operation-input.service-information.service-instance-id + '/service-data/networks/network/' + $prop.sdwan.network-id + '/network-data/'` \" />", + "comments": "", + "x": 801.0595626831055, + "y": 331.07977294921875, + "z": "d1658b32.d98238", + "wires": [] + }, + { + "id": "dbb7121b.abe6a", + "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": 725.7264022827148, + "y": 500.7464985847473, + "z": "d1658b32.d98238", + "wires": [] + }, + { + "id": "fdf26bca.f03768", + "type": "set", + "name": "set network-level-oper-status", + "xml": "<set>\n<parameter name='service-data.networks.network[$nidx].network-data.network-level-oper-status.order-status' value='Created' />\n<parameter name='service-data.networks.network[$nidx].network-data.network-level-oper-status.last-rpc-action' value='`$network-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='service-data.networks.network[$nidx].network-data.network-level-oper-status.last-action' value='`$network-topology-operation-input.request-information.request-action`' />", + "comments": "", + "x": 772.5595626831055, + "y": 371.07977294921875, + "z": "d1658b32.d98238", + "wires": [] + }, + { + "id": "713ce360.f628ac", + "type": "for", + "name": "for each existing network", + "xml": "<for index='idx' start='0' end='`$nidx`' >\n", + "comments": "", + "outputs": 1, + "x": 1169.5436248779297, + "y": 335.8575248424895, + "z": "d1658b32.d98238", + "wires": [ + [ + "eb4807cf.0d23d8" + ] + ] + }, + { + "id": "75983c07.a5a874", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1168.4166069030762, + "y": 231.01628494262695, + "z": "d1658b32.d98238", + "wires": [ + [ + "713ce360.f628ac", + "99e46d9c.cb058" + ] + ] + }, + { + "id": "eb4807cf.0d23d8", + "type": "switchNode", + "name": "switch networkid found", + "xml": "<switch test=\"`$service-data.networks.network[$idx].network-id == $network-topology-operation-input.network-information.network-id`\">\n", + "comments": "", + "outputs": 1, + "x": 1444.829345703125, + "y": 335.4290275280364, + "z": "d1658b32.d98238", + "wires": [ + [ + "ad204630.0981b8" + ] + ] + }, + { + "id": "ad204630.0981b8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1345.5595436096191, + "y": 394.00045868800953, + "z": "d1658b32.d98238", + "wires": [ + [ + "5de29638.c9b308" + ] + ] + }, + { + "id": "e4848432.b300d8", + "type": "comment", + "name": "make sure this network doesn't exist already", + "info": "", + "comments": "", + "x": 1393.1943550109863, + "y": 294.11158224986866, + "z": "d1658b32.d98238", + "wires": [] + }, + { + "id": "5de29638.c9b308", + "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=\"network-topology-operation-input.network-request-input.network-id already found in service-data\" />\n", + "comments": "", + "x": 1493.3096466064453, + "y": 393.85765075683594, + "z": "d1658b32.d98238", + "wires": [] + }, + { + "id": "3a8170a.8edea9", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1459.961139678955, + "y": 163.6353702545166, + "z": "d1658b32.d98238", + "wires": [ + [ + "5e4af687.3413b8", + "267dff81.9df9a" + ] + ] + }, + { + "id": "5e4af687.3413b8", + "type": "switchNode", + "name": "switch name", + "xml": "<switch test=\"`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].name == 'name'`\">\n", + "comments": "", + "outputs": 1, + "x": 1648.1829833984375, + "y": 145.96867442131042, + "z": "d1658b32.d98238", + "wires": [ + [ + "e9584cec.7c047" + ] + ] + }, + { + "id": "e9584cec.7c047", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1835.1829833984375, + "y": 141.96867442131042, + "z": "d1658b32.d98238", + "wires": [ + [ + "4f9d1895.e6c898" + ] + ] + }, + { + "id": "4f9d1895.e6c898", + "type": "set", + "name": "set name", + "xml": "<set>\n<parameter name='prop.name' value='`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1985.1831130981445, + "y": 140.5686810016632, + "z": "d1658b32.d98238", + "wires": [] + }, + { + "id": "267dff81.9df9a", + "type": "switchNode", + "name": "switch topology", + "xml": "<switch test=\"`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].name == 'topology'`\">\n", + "comments": "", + "outputs": 1, + "x": 1659.0226440429688, + "y": 185.9686725139618, + "z": "d1658b32.d98238", + "wires": [ + [ + "a3ecb652.b268e8" + ] + ] + }, + { + "id": "a3ecb652.b268e8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1829.0226440429688, + "y": 181.9686725139618, + "z": "d1658b32.d98238", + "wires": [ + [ + "5ddbd0bc.06582" + ] + ] + }, + { + "id": "5ddbd0bc.06582", + "type": "set", + "name": "set topology", + "xml": "<set>\n<parameter name='prop.topology' value='`$network-topology-operation-input.network-request-input.network-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 2016.3560848236084, + "y": 180.42982935905457, + "z": "d1658b32.d98238", + "wires": [] + }, + { + "id": "a7873db9.8b28e", + "type": "for", + "name": "for loop i - Network input parameters", + "xml": "<for index=\"idx\" start=\"0\" end=\"`$network-topology-operation-input.network-request-input.network-input-parameters.param_length`\">\n", + "comments": "", + "outputs": 1, + "x": 797.7383041381836, + "y": 161.41310119628906, + "z": "d1658b32.d98238", + "wires": [ + [ + "3a8170a.8edea9" + ] + ] + }, + { + "id": "3a427aaa.1513f6", + "type": "comment", + "name": "TODO: Recheck AAI schemas", + "info": "", + "comments": "", + "x": 769.0351867675781, + "y": 20, + "z": "d1658b32.d98238", + "wires": [] + }, + { + "id": "d8cec38f.bc599", + "type": "save", + "name": "save sdwan vpn resource in AAI", + "xml": "<save plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='sdwan-vpn' \n key='sdwan-vpn.sdwan-vpn-id = $prop.sdwan.network-id' >\n<parameter name='sdwan-vpn-id' value='`$prop.sdwan.network-id`' />\n<parameter name='sdwan-vpn-name' value='`$prop.name`' />\n<parameter name='topology' value='`$prop.topology`' />\n<parameter name='operational-status' value='Created' />\n<parameter name='model-customization-id' value='`$network-topology-operation-input.network-information.onap-model-information.model-customization-uuid`' />\n<parameter name='model-invariant-id' value='`$network-topology-operation-input.network-information.onap-model-information.model-invariant-uuid`' />\n<parameter name='model-version-id' value='`$network-topology-operation-input.network-information.onap-model-information.model-uuid`' />\n<parameter name='selflink' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/' + $network-topology-operation-input.service-information.service-instance-id + '/service-data/networks/network/' + $prop.sdwan.network-id + '/network-data/'` \" />", + "comments": "", + "outputs": 1, + "x": 782.0038986206055, + "y": 410.57261514663696, + "z": "d1658b32.d98238", + "wires": [ + [] + ] + }, + { + "id": "74be5192.2ede4", + "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.networks.network[$nidx].network-data.service-information.global-customer-id \n AND service-subscription.service-type = $service-data.networks.network[$nidx].network-data.service-information.subscription-service-type' \n force=\"true\" pfx=\"tmp.AnAI-data\">\n<parameter name=\"relationship-list.relationship[0].related-to\" value=\"sdwan-vpn\" />\n<parameter name=\"relationship-list.relationship[0].related-link\" value=\"`'/network/sdwan-vpns/sdwan-vpn/' + $prop.sdwan.network-id`\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-key\" value=\"sdwan-vpn.id\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-value\" value=\"`$prop.sdwan.network-id`\" />", + "comments": "", + "outputs": 1, + "x": 778.00390625, + "y": 457.57258653640747, + "z": "d1658b32.d98238", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-deactivate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-deactivate.json new file mode 100644 index 00000000..b0c215aa --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-deactivate.json @@ -0,0 +1,721 @@ +[ + { + "id": "fd56c256.6611d", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 102, + "y": 37, + "z": "88e745dd.c19a68", + "wires": [ + [ + "e8a2c571.7151d8" + ] + ] + }, + { + "id": "e8a2c571.7151d8", + "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": 264.00000381469727, + "y": 109.00001621246338, + "z": "88e745dd.c19a68", + "wires": [ + [ + "501691b7.b8579" + ] + ] + }, + { + "id": "501691b7.b8579", + "type": "method", + "name": "method sdwan-network-topology-operation-deactivate", + "xml": "<method rpc='sdwan-network-topology-operation-deactivate' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 252.0001220703125, + "y": 196.99999904632568, + "z": "88e745dd.c19a68", + "wires": [ + [ + "f268dab.9a2e128" + ] + ] + }, + { + "id": "f268dab.9a2e128", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 426.00001525878906, + "y": 305.0000581741333, + "z": "88e745dd.c19a68", + "wires": [ + [ + "b31f4e4c.0f578", + "34c8ec0.c180514", + "613a4de8.024144", + "5f55a204.78493c", + "b7c0b37c.27c35", + "f96046b8.ac5b48", + "f78b989e.79da48", + "76b3c50a.02876c", + "ad00b85d.5bef68", + "b370ae59.4bce9", + "2ec15.4c1aa3ebc", + "988eea5f.5a0298", + "2cf3fcb4.da9384", + "9a8305f1.e08cb8" + ] + ] + }, + { + "id": "b31f4e4c.0f578", + "type": "call", + "name": "call GENERIC-RESOURCE-API:validate-sdwan-network-input-parameters", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='validate-sdwan-network-input-parameters' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 884.3889007568359, + "y": 53.999999046325684, + "z": "88e745dd.c19a68", + "wires": [ + [] + ] + }, + { + "id": "34c8ec0.c180514", + "type": "record", + "name": "record", + "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"sdwan-network-topology-operation-deactivate\"/>\n<parameter name=\"field3\" value=\"SDWAN-Deactivate\"/>\n", + "comments": "", + "outputs": 1, + "x": 684.5555992126465, + "y": 107.77785205841064, + "z": "88e745dd.c19a68", + "wires": [ + [] + ] + }, + { + "id": "613a4de8.024144", + "type": "set", + "name": "set networkId and network-object-path", + "xml": "<set>\n<parameter name='networkId' value='`$network-topology-operation-input.network-information.network-id`' />\n<parameter name=\"network-object-path\" value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/' + $network-topology-operation-input.service-information.service-instance-id + '/service-data/networks/network/' + $network-topology-operation-input.network-information.network-id + '/network-data/'` \" />", + "comments": "", + "x": 786.5558738708496, + "y": 849.3134832382202, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "5f55a204.78493c", + "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": 708.3336753845215, + "y": 1038.8689031600952, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "b7c0b37c.27c35", + "type": "set", + "name": "set network-level-oper-status", + "xml": "<set>\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.order-status' value='PendingDelete' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.last-rpc-action' value='`$network-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.last-action' value='`$network-topology-operation-input.request-information.request-action`' />", + "comments": "", + "x": 753.4447898864746, + "y": 910.5356578826904, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "f96046b8.ac5b48", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 716.8577041625977, + "y": 160.77788829803467, + "z": "88e745dd.c19a68", + "wires": [ + [] + ] + }, + { + "id": "f78b989e.79da48", + "type": "set", + "name": "set network in service-data", + "xml": "<set>\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.sdnc-request-header.' value='`$network-topology-operation-input.sdnc-request-header.`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.request-information.' value='`$network-topology-operation-input.request-information.`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.service-information.' value='`$network-topology-operation-input.service-information.`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-information.' value='`$network-topology-operation-input.network-information.`' />", + "comments": "", + "x": 747.0004043579102, + "y": 796.0913171768188, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "76b3c50a.02876c", + "type": "for", + "name": "for each network-input-parameters", + "xml": "<for index='idx' start='0' end='`$ctx.network-data.network-request-input.network-input-parameters.param_length`' >\n", + "comments": "", + "outputs": 1, + "x": 769, + "y": 231.00390657782555, + "z": "88e745dd.c19a68", + "wires": [ + [ + "1c6b88c6.f49ce7" + ] + ] + }, + { + "id": "1c6b88c6.f49ce7", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1025.8334312438965, + "y": 165.33725771307945, + "z": "88e745dd.c19a68", + "wires": [ + [ + "903569b7.4e2578", + "653d2c3c.262b14", + "c5910d9a.730a3", + "5b432d19.74fce4" + ] + ] + }, + { + "id": "903569b7.4e2578", + "type": "switchNode", + "name": "switch name", + "xml": "<switch test=\"`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].name == 'name'`\">\n", + "comments": "", + "outputs": 1, + "x": 1247.833511352539, + "y": 55.33729267120361, + "z": "88e745dd.c19a68", + "wires": [ + [ + "138e36c7.964e29" + ] + ] + }, + { + "id": "138e36c7.964e29", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1421.8336372375488, + "y": 55.33729648590088, + "z": "88e745dd.c19a68", + "wires": [ + [ + "cd7bebad.986118" + ] + ] + }, + { + "id": "cd7bebad.986118", + "type": "set", + "name": "set name", + "xml": "<set>\n<parameter name='prop.name' value='`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1584.8335227966309, + "y": 54.93729114532471, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "ad00b85d.5bef68", + "type": "get-resource", + "name": "get-resource esr-thirdparty-sdnc", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = 'SDWANController' AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n", + "comments": "", + "outputs": 1, + "x": 763, + "y": 340.00390657782555, + "z": "88e745dd.c19a68", + "wires": [ + [ + "2b0c648a.f8433c", + "f2e86cdd.3128a", + "918162b5.31748" + ] + ] + }, + { + "id": "2b0c648a.f8433c", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1008, + "y": 286.00390657782555, + "z": "88e745dd.c19a68", + "wires": [ + [ + "a06faa05.f76618" + ] + ] + }, + { + "id": "f2e86cdd.3128a", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 1011.490966796875, + "y": 333.5779422223568, + "z": "88e745dd.c19a68", + "wires": [ + [ + "37a1f73b.b96e68" + ] + ] + }, + { + "id": "918162b5.31748", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1006.823974609375, + "y": 374.91125521063805, + "z": "88e745dd.c19a68", + "wires": [ + [ + "4f66c6a.4583438" + ] + ] + }, + { + "id": "a06faa05.f76618", + "type": "set", + "name": "set controller data", + "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n", + "comments": "", + "x": 1205.5000610351562, + "y": 274.00390657782555, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "37a1f73b.b96e68", + "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1188.0623779296875, + "y": 321.86367830634117, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "4f66c6a.4583438", + "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1194.5965309143066, + "y": 370.35044798254967, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "b370ae59.4bce9", + "type": "execute", + "name": "execute RestApiCallNode Get token", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>", + "comments": "", + "outputs": 1, + "x": 771, + "y": 451.00390657782555, + "z": "88e745dd.c19a68", + "wires": [ + [ + "61a5287d.5d14f8", + "99df3ba8.a50248" + ] + ] + }, + { + "id": "61a5287d.5d14f8", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1006, + "y": 429.00390657782555, + "z": "88e745dd.c19a68", + "wires": [ + [ + "951e43bb.f165" + ] + ] + }, + { + "id": "99df3ba8.a50248", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 998.25, + "y": 482.6467898786068, + "z": "88e745dd.c19a68", + "wires": [ + [ + "f26ec62f.ef46a8" + ] + ] + }, + { + "id": "951e43bb.f165", + "type": "set", + "name": "set token-id", + "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n", + "comments": "", + "x": 1160, + "y": 430.00390657782555, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "f26ec62f.ef46a8", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1151, + "y": 482.39685091376305, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "653d2c3c.262b14", + "type": "switchNode", + "name": "switch topology", + "xml": "<switch test=\"`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].name == 'topology'`\">\n", + "comments": "", + "outputs": 1, + "x": 1253.249984741211, + "y": 98.00390696525574, + "z": "88e745dd.c19a68", + "wires": [ + [ + "42e996e4.f57c78" + ] + ] + }, + { + "id": "42e996e4.f57c78", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1427.2501106262207, + "y": 98.003910779953, + "z": "88e745dd.c19a68", + "wires": [ + [ + "36533d51.327db2" + ] + ] + }, + { + "id": "36533d51.327db2", + "type": "set", + "name": "set topology", + "xml": "<set>\n<parameter name='prop.topology' value='`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1590.2499961853027, + "y": 97.60390543937683, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "2ec15.4c1aa3ebc", + "type": "execute", + "name": "execute RestApiCallNode delete vpn", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-vpn-delete.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/vpn/action/batch-delete'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 779.7501068115234, + "y": 733.0041427612305, + "z": "88e745dd.c19a68", + "wires": [ + [] + ] + }, + { + "id": "988eea5f.5a0298", + "type": "execute", + "name": "execute RestApiCallNode delete vpn topology", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/' + $prop.vpn-id + '/topology'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"delete\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 809.2501220703125, + "y": 666.0040273666382, + "z": "88e745dd.c19a68", + "wires": [ + [] + ] + }, + { + "id": "c5910d9a.730a3", + "type": "switchNode", + "name": "switch vpn-id", + "xml": "<switch test=\"`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].name == 'vpn-id'`\">\n", + "comments": "", + "outputs": 1, + "x": 1247.5000629425049, + "y": 181.00000095367432, + "z": "88e745dd.c19a68", + "wires": [ + [ + "648a246c.73b5ec" + ] + ] + }, + { + "id": "648a246c.73b5ec", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1429.5000953674316, + "y": 180.99999976158142, + "z": "88e745dd.c19a68", + "wires": [ + [ + "701a4c1a.83d604" + ] + ] + }, + { + "id": "701a4c1a.83d604", + "type": "set", + "name": "set prop.vpn-id", + "xml": "<set>\n<parameter name='prop.vpn-id' value='`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1592.4999809265137, + "y": 180.59999442100525, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "5b432d19.74fce4", + "type": "switchNode", + "name": "switch tenant-id", + "xml": "<switch test=\"`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].name == 'tenant-id'`\">\n", + "comments": "", + "outputs": 1, + "x": 1253.25, + "y": 223.99999904632568, + "z": "88e745dd.c19a68", + "wires": [ + [ + "f053b806.9e46f8" + ] + ] + }, + { + "id": "f053b806.9e46f8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1427.2501258850098, + "y": 224.00000286102295, + "z": "88e745dd.c19a68", + "wires": [ + [ + "7fc67227.287a4c" + ] + ] + }, + { + "id": "7fc67227.287a4c", + "type": "set", + "name": "set prop.tenant-id", + "xml": "<set>\n<parameter name='prop.tenant-id' value='`$ctx.network-data.network-request-input.network-input-parameters.param[$idx].value`' />\n", + "comments": "", + "x": 1590.2500114440918, + "y": 223.59999752044678, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "2cf3fcb4.da9384", + "type": "update", + "name": "update SDWAN VPN status to AAI", + "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='sdwan-vpn' \n key='sdwan-vpn.sdwan-vpn-id = $network-topology-operation-input.network-information.network-id' >\n<parameter name='sdwan-vpn-id' value='`$network-topology-operation-input.network-information.network-id`' />\n<parameter name='operational-status' value='PendingDelete' />", + "comments": "", + "outputs": 1, + "x": 767.0000686645508, + "y": 977.5001134872437, + "z": "88e745dd.c19a68", + "wires": [ + [] + ] + }, + { + "id": "9a8305f1.e08cb8", + "type": "get-resource", + "name": "get-resource service-subscription", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"service-subscription\" \n key= 'service-subscription.service-type = $service-data.networks.network[$tmp.nidx].network-data.service-information.subscription-service-type \n AND customer.global-customer-id = $service-data.networks.network[$tmp.nidx].network-data.service-information.global-customer-id'\n force=\"true\" pfx=\"tmp.AnAI-data\">\n \n", + "comments": "", + "outputs": 1, + "x": 758.0038909912109, + "y": 533.0038976669312, + "z": "88e745dd.c19a68", + "wires": [ + [ + "6497125a.d4efec", + "61153347.107bfc" + ] + ] + }, + { + "id": "61153347.107bfc", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 973.1824684143066, + "y": 584.9642953872681, + "z": "88e745dd.c19a68", + "wires": [ + [ + "2a04bd37.e27582" + ] + ] + }, + { + "id": "6497125a.d4efec", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 979.5038795471191, + "y": 532.7499837875366, + "z": "88e745dd.c19a68", + "wires": [ + [ + "954bff66.85de8" + ] + ] + }, + { + "id": "2a04bd37.e27582", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1125.9324684143066, + "y": 584.7143564224243, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "954bff66.85de8", + "type": "switchNode", + "name": "switch temp-ub-sub-account-id", + "xml": "<switch test='`$tmp.AnAI-data.temp-ub-sub-account-id`'>\n", + "comments": "", + "outputs": 1, + "x": 1181.004108428955, + "y": 524.7540063858032, + "z": "88e745dd.c19a68", + "wires": [ + [ + "81f571ba.fc753" + ] + ] + }, + { + "id": "81f571ba.fc753", + "type": "other", + "name": "Other", + "xml": "<outcome value='Other'>", + "comments": "", + "outputs": 1, + "x": 1374.0041236877441, + "y": 553.7540102005005, + "z": "88e745dd.c19a68", + "wires": [ + [ + "d50c5253.93df5" + ] + ] + }, + { + "id": "d50c5253.93df5", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1432.6548805236816, + "y": 636.9010019302368, + "z": "88e745dd.c19a68", + "wires": [ + [ + "5e8c6620.18c828", + "29548e46.007002" + ] + ] + }, + { + "id": "5e8c6620.18c828", + "type": "set", + "name": "set prop.tenant-id", + "xml": "<set>\n<parameter name='prop.tenant-id' value='`$tmp.AnAI-data.temp-ub-sub-account-id`' />\n", + "comments": "", + "x": 1621.432716369629, + "y": 638.8968105316162, + "z": "88e745dd.c19a68", + "wires": [] + }, + { + "id": "29548e46.007002", + "type": "execute", + "name": "execute RestApiCallNode Create tenant auth", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/baseservice/tenants/authorization/' + $prop.tenant-id`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"tenant-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 1704.0834770202637, + "y": 685.4724044799805, + "z": "88e745dd.c19a68", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-delete.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-delete.json new file mode 100644 index 00000000..8e84a93f --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-network-topology-operation-delete.json @@ -0,0 +1,159 @@ +[ + { + "id": "557c0d2.e91edf4", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 121.00390625, + "y": 50.00390625, + "z": "f08fa760.244488", + "wires": [ + [ + "93294ef3.ba70b" + ] + ] + }, + { + "id": "93294ef3.ba70b", + "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": 333.00391006469727, + "y": 122.0039234161377, + "z": "f08fa760.244488", + "wires": [ + [ + "d7638881.bfb4c8" + ] + ] + }, + { + "id": "d7638881.bfb4c8", + "type": "method", + "name": "method sdwan-network-topology-operation-delete", + "xml": "<method rpc='sdwan-network-topology-operation-delete' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 321.0040283203125, + "y": 210.00390625, + "z": "f08fa760.244488", + "wires": [ + [ + "96e57ca9.97c2e" + ] + ] + }, + { + "id": "96e57ca9.97c2e", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 491.44836044311523, + "y": 272.44836235046387, + "z": "f08fa760.244488", + "wires": [ + [ + "3ea486fa.98e8fa", + "5a29219c.c419d", + "8d5f8731.51c938", + "40643a2d.08d114", + "24e3bcc2.2186b4", + "c8f5f5d0.be2858", + "cb920ad8.ed1188" + ] + ] + }, + { + "id": "3ea486fa.98e8fa", + "type": "call", + "name": "call GENERIC-RESOURCE-API:validate-sdwan-network-input-parameters", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='validate-sdwan-network-input-parameters' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 972.3928146362305, + "y": 67.00391006469727, + "z": "f08fa760.244488", + "wires": [ + [] + ] + }, + { + "id": "5a29219c.c419d", + "type": "record", + "name": "record", + "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"sdwan-network-topology-operation-delete\"/>\n<parameter name=\"field3\" value=\"SDWAN-Delete\"/>\n", + "comments": "", + "outputs": 1, + "x": 766.7816314697266, + "y": 133.33727836608887, + "z": "f08fa760.244488", + "wires": [ + [] + ] + }, + { + "id": "8d5f8731.51c938", + "type": "set", + "name": "set networkId and network-object-path", + "xml": "<set>\n<parameter name='networkId' value='`$network-topology-operation-input.network-information.network-id`' />\n<parameter name='service-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $network-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'` \" />", + "comments": "", + "x": 851.448314666748, + "y": 381.4281978607178, + "z": "f08fa760.244488", + "wires": [] + }, + { + "id": "40643a2d.08d114", + "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": 780.5595626831055, + "y": 444.9835858345032, + "z": "f08fa760.244488", + "wires": [] + }, + { + "id": "c8f5f5d0.be2858", + "type": "set", + "name": "set new network length", + "xml": "<set>\n\t<parameter name=\"service-data.networks.network_length\" value=\"`$service-data.networks.network_length - 1`\"/>\n\n\t\n", + "comments": "", + "x": 810.0809860229492, + "y": 258.89910793304443, + "z": "f08fa760.244488", + "wires": [] + }, + { + "id": "24e3bcc2.2186b4", + "type": "set", + "name": "Remove networks from ServiceData", + "xml": "<set>\n\t<parameter name=\"service-data.networks.network[$tmp.nidx].\" value=\"\"/>\n\n", + "comments": "", + "x": 850.7051429748535, + "y": 306.8670496940613, + "z": "f08fa760.244488", + "wires": [] + }, + { + "id": "cb920ad8.ed1188", + "type": "delete", + "name": "delete SDWAN VPNInstance connectivity in AAI", + "xml": "<delete plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" resource='sdwan-vpn' \n key='sdwan-vpn.sdwan-vpn-id = $network-topology-operation-input.network-information.network-id'>\n", + "comments": "", + "outputs": 1, + "x": 888.6364860534668, + "y": 200.01019191741943, + "z": "f08fa760.244488", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-activate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-activate.json new file mode 100644 index 00000000..1f43d75b --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-activate.json @@ -0,0 +1,634 @@ +[ + { + "id": "206c85aa.5a072a", + "type": "comment", + "name": "sdwan-vnf-topology-operation-device-activate", + "info": "", + "comments": "", + "x": 508.3447952270508, + "y": 68, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "ca427018.80bcb", + "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": 188.28570556640625, + "y": 139.0002670288086, + "z": "51909408.51161c", + "wires": [ + [ + "2fa01ba0.438244" + ] + ] + }, + { + "id": "d277668e.e654a8", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 109, + "y": 76.76215744018555, + "z": "51909408.51161c", + "wires": [ + [ + "ca427018.80bcb" + ] + ] + }, + { + "id": "29e19c37.979fb4", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 183.6666717529297, + "y": 418.42884254455566, + "z": "51909408.51161c", + "wires": [ + [ + "d0145adc.c61398", + "8a8e6e5a.af8ac", + "5365293b.242938", + "2b32a3df.95a32c", + "7f49e88e.6ac0a8", + "8f8a4ade.fb21d8", + "9162baea.a58618", + "96cec913.036c98", + "f1cfd3b2.a98b6", + "7bfd6f06.aec7d", + "a82fd005.9ab21", + "752aae5e.411ae", + "feaf1629.1e79e8", + "bd5ee22a.cd67b" + ] + ] + }, + { + "id": "8a8e6e5a.af8ac", + "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": 589.0477142333984, + "y": 1021.6670913696289, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "d0145adc.c61398", + "type": "set", + "name": "set vnf-level-oper-status to Active", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.order-status' value='Active' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].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[$tmp.vidx].vnf-data.vnf-level-oper-status.last-action' value='`$vnf-topology-operation-input.request-information.request-action`' />\n", + "comments": "", + "x": 670.527774810791, + "y": 829.0042400360107, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "7f49e88e.6ac0a8", + "type": "set", + "name": "copy input data to service data", + "xml": "<set>\n<!--parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' /-->\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.sdnc-request-header.' value='`$vnf-topology-operation-input.sdnc-request-header.`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.request-information.' value='`$vnf-topology-operation-input.request-information.`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.service-information.' value='`$vnf-topology-operation-input.service-information.`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-information.' value='`$vnf-topology-operation-input.vnf-information.`' />\n", + "comments": "", + "x": 648.3809661865234, + "y": 885.000415802002, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "7ac7ee71.334c", + "type": "comment", + "name": "make sure this VNF doesn't exist already", + "info": "", + "comments": "", + "x": 1383.7143249511719, + "y": 661.9527359008789, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "7bfd6f06.aec7d", + "type": "save", + "name": "update deviceInstance configuration in AAI", + "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='device' \n key='device.device-id = $vnf-topology-operation-input.vnf-information.vnf-id' >\n<parameter name='device-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' />\n<!--parameter name='device-id' value='`$deviceResp.success[0].id`' /-->\n<parameter name='operational-status' value='Active' />", + "comments": "", + "outputs": 1, + "x": 672.7144622802734, + "y": 934.8894157409668, + "z": "51909408.51161c", + "wires": [ + [] + ] + }, + { + "id": "2fa01ba0.438244", + "type": "method", + "name": "method sdwan-vnf-topology-operation-device-activate", + "xml": "<method rpc='sdwan-vnf-topology-operation-device-activate' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 200, + "y": 233.3484992980957, + "z": "51909408.51161c", + "wires": [ + [ + "29e19c37.979fb4" + ] + ] + }, + { + "id": "5365293b.242938", + "type": "set", + "name": "set vnfId and vnf-object-path", + "xml": "<set>\n<parameter name='vnfId' value='`$vnf-topology-operation-input.vnf-information.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/' + $vnf-topology-operation-input.vnf-information.vnf-id + '/vnf-data/'` \" />", + "comments": "", + "x": 651.7144165039062, + "y": 777.9200525283813, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "feaf1629.1e79e8", + "type": "execute", + "name": "execute RestApiCallNode Create Devcie Instance", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-device.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v3/devices'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"deviceResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 724.3017807006836, + "y": 666.1265420913696, + "z": "51909408.51161c", + "wires": [ + [ + "1fffde57.79b802", + "1d6faab2.67fba5" + ] + ] + }, + { + "id": "752aae5e.411ae", + "type": "execute", + "name": "execute RestApiCallNode Get token", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>", + "comments": "", + "outputs": 1, + "x": 675.4445495605469, + "y": 516.1263904571533, + "z": "51909408.51161c", + "wires": [ + [ + "32c81884.3acf08", + "5b1f77c1.6546b8" + ] + ] + }, + { + "id": "32c81884.3acf08", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 907.4445495605469, + "y": 496.1263904571533, + "z": "51909408.51161c", + "wires": [ + [ + "8863e5c0.8fc5a8" + ] + ] + }, + { + "id": "5b1f77c1.6546b8", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 899.6945495605469, + "y": 537.7692737579346, + "z": "51909408.51161c", + "wires": [ + [ + "1b01e427.5d582c" + ] + ] + }, + { + "id": "8863e5c0.8fc5a8", + "type": "set", + "name": "set token-id", + "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n", + "comments": "", + "x": 1044.4445495605469, + "y": 496.1263904571533, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "1b01e427.5d582c", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1025.7780456542969, + "y": 538.0153064727783, + "z": "51909408.51161c", + "wires": [ + [] + ] + }, + { + "id": "b65e0d53.3b7ed", + "type": "comment", + "name": "Do Nothing", + "info": "", + "comments": "", + "x": 1287.3335914611816, + "y": 338.9041233062744, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "aa15cb9e.3cdaa8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1150.968246459961, + "y": 636.0153303146362, + "z": "51909408.51161c", + "wires": [ + [] + ] + }, + { + "id": "12eca3bc.6e077c", + "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=\"Error executing Activate Device rest api\" />\n", + "comments": "", + "x": 1152.412826538086, + "y": 686.5708627700806, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "1d6faab2.67fba5", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 999.412670135498, + "y": 689.5708169937134, + "z": "51909408.51161c", + "wires": [ + [ + "12eca3bc.6e077c" + ] + ] + }, + { + "id": "1fffde57.79b802", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 998.8571853637695, + "y": 633.2375288009644, + "z": "51909408.51161c", + "wires": [ + [ + "aa15cb9e.3cdaa8" + ] + ] + }, + { + "id": "8f8a4ade.fb21d8", + "type": "set", + "name": "set deviceId to service data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].name' value=\"deviceId\" />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].value' value='`$deviceResp.success[0].id`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1`' />\n", + "comments": "", + "x": 657.7145690917969, + "y": 729.9202995300293, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "a82fd005.9ab21", + "type": "get-resource", + "name": "get-resource esr-thirdparty-sdnc", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n", + "comments": "", + "outputs": 1, + "x": 670.0002136230469, + "y": 420.34861183166504, + "z": "51909408.51161c", + "wires": [ + [ + "342b0391.a4834c", + "7a108269.f3476c", + "87289215.d0cea" + ] + ] + }, + { + "id": "342b0391.a4834c", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 911.0002708435059, + "y": 345.3485860824585, + "z": "51909408.51161c", + "wires": [ + [ + "21df5526.b03a8a" + ] + ] + }, + { + "id": "21df5526.b03a8a", + "type": "set", + "name": "set controller data", + "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n", + "comments": "", + "x": 1087.5003128051758, + "y": 336.34857511520386, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "7a108269.f3476c", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 902.4911079406738, + "y": 393.92263412475586, + "z": "51909408.51161c", + "wires": [ + [ + "e9fd26db.c0e278" + ] + ] + }, + { + "id": "e9fd26db.c0e278", + "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1076.0625190734863, + "y": 382.20837020874023, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "87289215.d0cea", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 894.8241157531738, + "y": 435.2559471130371, + "z": "51909408.51161c", + "wires": [ + [ + "d7092d64.71989" + ] + ] + }, + { + "id": "d7092d64.71989", + "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1082.5966720581055, + "y": 430.69513988494873, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "2b32a3df.95a32c", + "type": "record", + "name": "record", + "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"Provided alloted resource length\"/>\n<parameter name=\"field3\" value=\"'parameters length'\"/>\n<parameter name=\"field4\" value='`$vnf-topology-operation-input.vnf-request-input.vnf-input-parameters.param_length`'/>\n\n\n\n", + "comments": "", + "outputs": 1, + "x": 615.0000152587891, + "y": 298.0151786804199, + "z": "51909408.51161c", + "wires": [ + [] + ] + }, + { + "id": "9162baea.a58618", + "type": "for", + "name": "for vidx..service-data.vnfs.vnf_length[]", + "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 703.0313034057617, + "y": 184.0312786102295, + "z": "51909408.51161c", + "wires": [ + [ + "b4173a9a.c4a2c8" + ] + ] + }, + { + "id": "b4173a9a.c4a2c8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 951.3808975219727, + "y": 184.57134628295898, + "z": "51909408.51161c", + "wires": [ + [ + "8ed61ccb.fe1d2" + ] + ] + }, + { + "id": "8ed61ccb.fe1d2", + "type": "switchNode", + "name": "switch vnfid found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1105.4604949951172, + "y": 184.28142833709717, + "z": "51909408.51161c", + "wires": [ + [ + "25dffe3f.86e402" + ] + ] + }, + { + "id": "94dc5d4a.a00f9", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1399.058006286621, + "y": 185.5817413330078, + "z": "51909408.51161c", + "wires": [ + [ + "fa685102.6e48e", + "a75f325a.531e1", + "1c8ecc84.ad1ff3" + ] + ] + }, + { + "id": "25dffe3f.86e402", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1260.4124870300293, + "y": 185.1741075515747, + "z": "51909408.51161c", + "wires": [ + [ + "94dc5d4a.a00f9" + ] + ] + }, + { + "id": "a75f325a.531e1", + "type": "set", + "name": "set vnf-request-input.", + "xml": "<set>\n<parameter name='vnf-request-input.' value='`$ctx.vnf-data.vnf-data.vnf-request-input.`' />\n\n", + "comments": "", + "x": 1640.3908615112305, + "y": 141.58180141448975, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "fa685102.6e48e", + "type": "set", + "name": "set tmp.vidx and ctx.vnf-data", + "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].`' />\n", + "comments": "", + "x": 1667.9445724487305, + "y": 94.92416572570801, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "1c8ecc84.ad1ff3", + "type": "call", + "name": "call sdwan-get-device-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-device-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 1645.0313110351562, + "y": 204.03127193450928, + "z": "51909408.51161c", + "wires": [ + [] + ] + }, + { + "id": "96cec913.036c98", + "type": "switchNode", + "name": "switch tmp.vidx ", + "xml": "<switch test=\"`$tmp.vidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 634.0311889648438, + "y": 245.03125, + "z": "51909408.51161c", + "wires": [ + [ + "dd74e5cf.ddfed8" + ] + ] + }, + { + "id": "dd74e5cf.ddfed8", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 781.459831237793, + "y": 244.60266017913818, + "z": "51909408.51161c", + "wires": [ + [ + "f70bcb29.83b348" + ] + ] + }, + { + "id": "f70bcb29.83b348", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 930.888557434082, + "y": 245.74557781219482, + "z": "51909408.51161c", + "wires": [] + }, + { + "id": "f1cfd3b2.a98b6", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 629.0311889648438, + "y": 341.03125, + "z": "51909408.51161c", + "wires": [ + [] + ] + }, + { + "id": "bd5ee22a.cd67b", + "type": "call", + "name": "call sdwan-get-tenant-auth", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-tenant-auth' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 654.2938385009766, + "y": 604.2938222885132, + "z": "51909408.51161c", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-create.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-create.json new file mode 100644 index 00000000..36a7cfdc --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-create.json @@ -0,0 +1,641 @@ +[ + { + "id": "fd0440a.ecd51c", + "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": 196, + "y": 82.23810958862305, + "z": "842fbc05.cce04", + "wires": [ + [ + "127bb9c5.150526" + ] + ] + }, + { + "id": "e5b0a995.906238", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 116.71429443359375, + "y": 20, + "z": "842fbc05.cce04", + "wires": [ + [ + "fd0440a.ecd51c" + ] + ] + }, + { + "id": "23553cdf.889914", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 197.3809585571289, + "y": 343.66666984558105, + "z": "842fbc05.cce04", + "wires": [ + [ + "bf0f7a26.a11068", + "f71d7490.89bd28", + "ed1f7a5f.52aa38", + "20a30a30.b04286", + "1a809147.c1ebef", + "53d08385.3ed46c", + "d658c8ee.f13848", + "8e20e633.b9b588", + "61dc4d5e.3ba864", + "43e73a53.fc83c4", + "ff98826e.6bc6d", + "60a78e84.5e55" + ] + ] + }, + { + "id": "f71d7490.89bd28", + "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": 578.0479011535645, + "y": 965.3337297439575, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "bf0f7a26.a11068", + "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": 667.5279121398926, + "y": 697.6708345413208, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "20a30a30.b04286", + "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.`' />", + "comments": "", + "x": 645.381103515625, + "y": 753.667010307312, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "ef25e38.ee9742", + "type": "save", + "name": "save deviceInstance configuration in AAI", + "xml": "<save plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='device' \n key='device.device-id = $prop.vnf-id' >\n<parameter name='device-id' value='`$prop.vnf-id`' />\n<parameter name='esn' value='`$prop.device.esn`' />\n<parameter name='device-name' value='`$prop.device.name`' />\n<parameter name='description' value='`$prop.device.description`' />\n<parameter name='vendor' value='`$prop.device.vendor`' />\n<parameter name='class' value='`$prop.device.class`' />\n<parameter name='type' value='`$prop.device.deviceModel`' />\n<parameter name='version' value='`$prop.device.version`' />\n<parameter name='system-ip' value='`$prop.device.systemIp`' />\n<parameter name='operational-status' value='Created' />\n<parameter name='model-customization-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`' />\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='selflink' 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/'` \" />\n", + "comments": "", + "outputs": 1, + "x": 1123.7149963378906, + "y": 770.5563173294067, + "z": "842fbc05.cce04", + "wires": [ + [] + ] + }, + { + "id": "127bb9c5.150526", + "type": "method", + "name": "method sdwan-vnf-topology-operation-device-create", + "xml": "<method rpc='sdwan-vnf-topology-operation-device-create' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 207.71429443359375, + "y": 176.58634185791016, + "z": "842fbc05.cce04", + "wires": [ + [ + "23553cdf.889914" + ] + ] + }, + { + "id": "ed1f7a5f.52aa38", + "type": "set", + "name": "set vnfId 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": 648.7145538330078, + "y": 646.5866470336914, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "abbdb9a7.a00168", + "type": "set", + "name": "set deviceId to service data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-id' value='`$prop.vnf-id`' />\n", + "comments": "", + "x": 654.7147064208984, + "y": 598.5868940353394, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "c106be0b.38899", + "type": "comment", + "name": "AAI resource need to update", + "info": "", + "comments": "", + "x": 969.714599609375, + "y": 724.5867567062378, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "63a58c6c.370174", + "type": "execute", + "name": "execute generate-vnf-id", + "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": 1153.7149810791016, + "y": 111.58645248413086, + "z": "842fbc05.cce04", + "wires": [ + [] + ] + }, + { + "id": "60a78e84.5e55", + "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=\"device\" />\n<parameter name=\"relationship-list.relationship[0].related-link\" value=\"`'/network/devices/device/' + $prop.vnf-id`\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-key\" value=\"device.device-id\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-value\" value=\"`$prop.vnf-id`\" />", + "comments": "", + "outputs": 1, + "x": 635.7148551940918, + "y": 920.3336315155029, + "z": "842fbc05.cce04", + "wires": [ + [] + ] + }, + { + "id": "1a809147.c1ebef", + "type": "switchNode", + "name": "switch vnf-id", + "xml": "<switch test=\"`$vnf-topology-operation-input.vnf-information.vnf-id`\">\n", + "comments": "", + "outputs": 1, + "x": 617.7144012451172, + "y": 215.23787117004395, + "z": "842fbc05.cce04", + "wires": [ + [ + "ecde6b48.bbfc48", + "1019aeef.5808d1" + ] + ] + }, + { + "id": "ecde6b48.bbfc48", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 758.7144050598145, + "y": 190.2378625869751, + "z": "842fbc05.cce04", + "wires": [ + [ + "81003234.70dcc" + ] + ] + }, + { + "id": "81003234.70dcc", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 906.7145080566406, + "y": 126.23785495758057, + "z": "842fbc05.cce04", + "wires": [ + [ + "63a58c6c.370174", + "69aa8a5d.0ac9a4", + "6eb09a3f.09bc74" + ] + ] + }, + { + "id": "1019aeef.5808d1", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 755.2455825805664, + "y": 250.26910018920898, + "z": "842fbc05.cce04", + "wires": [ + [ + "b2303be.abcc1c8" + ] + ] + }, + { + "id": "fe4dccde.57bcf", + "type": "set", + "name": "set prop.vnf-id", + "xml": "<set>\n<parameter name='prop.vnf-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' />\n", + "comments": "", + "x": 1094.246337890625, + "y": 329.2694733142853, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "b2303be.abcc1c8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 906.2460021972656, + "y": 282.2692222595215, + "z": "842fbc05.cce04", + "wires": [ + [ + "fe4dccde.57bcf", + "6eb09a3f.09bc74", + "d5a722bf.9d266" + ] + ] + }, + { + "id": "53d08385.3ed46c", + "type": "set", + "name": "set prop.sdncCreate=false", + "xml": "<set>\n<parameter name='prop.sdncCreate' value='false' />\n", + "comments": "", + "x": 692.2456512451172, + "y": 106.26909446716309, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "d658c8ee.f13848", + "type": "switchNode", + "name": "switch prop.sdncCreate", + "xml": "<switch test='`$prop.sdncCreate`'>\n", + "comments": "", + "outputs": 1, + "x": 614.7459869384766, + "y": 800.2695140838623, + "z": "842fbc05.cce04", + "wires": [ + [ + "be0155ce.278c18", + "f63d8c0c.a2846" + ] + ] + }, + { + "id": "be0155ce.278c18", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 860.7457580566406, + "y": 770.769250869751, + "z": "842fbc05.cce04", + "wires": [ + [ + "ef25e38.ee9742" + ] + ] + }, + { + "id": "f63d8c0c.a2846", + "type": "outcomeTrue", + "name": "false", + "xml": "<outcome value='false'>\n", + "comments": "", + "outputs": 1, + "x": 862.2457427978516, + "y": 825.7692651748657, + "z": "842fbc05.cce04", + "wires": [ + [ + "2097a67.fbc2c5a" + ] + ] + }, + { + "id": "69aa8a5d.0ac9a4", + "type": "set", + "name": "set prop.updateAAIsdncCreate", + "xml": "<set>\n<parameter name='prop.sdncCreate' value='true' />\n", + "comments": "", + "x": 1171.2460708618164, + "y": 71.26917839050293, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "8e20e633.b9b588", + "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": 680.2457275390625, + "y": 400.2691287994385, + "z": "842fbc05.cce04", + "wires": [ + [ + "6a3b248.f431cdc" + ] + ] + }, + { + "id": "6a3b248.f431cdc", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 895.0240707397461, + "y": 397.8247127532959, + "z": "842fbc05.cce04", + "wires": [ + [ + "c1af467b.da6408", + "b9f2cae.04bc638" + ] + ] + }, + { + "id": "b9f2cae.04bc638", + "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": 1060.7247009277344, + "y": 412.5729675292969, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "c1af467b.da6408", + "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": 1091.2802734375, + "y": 375.5728511810303, + "z": "842fbc05.cce04", + "wires": [ + [] + ] + }, + { + "id": "61dc4d5e.3ba864", + "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": 642.2453460693359, + "y": 474.593843460083, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "43e73a53.fc83c4", + "type": "call", + "name": "call sdwan-get-device-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-device-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 667.2457275390625, + "y": 506.59400367736816, + "z": "842fbc05.cce04", + "wires": [ + [] + ] + }, + { + "id": "98f6587a.b563b8", + "type": "comment", + "name": "if SO provide vnf-id use that else create new", + "info": "", + "comments": "", + "x": 709.2455749511719, + "y": 160.26910400390625, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "6eb09a3f.09bc74", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1114.746078491211, + "y": 208.26919746398926, + "z": "842fbc05.cce04", + "wires": [ + [ + "10311b8f.214a74", + "d0785948.131e88" + ] + ] + }, + { + "id": "10311b8f.214a74", + "type": "switchNode", + "name": "switch service-data.vnfs.vnf_length", + "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n", + "comments": "", + "outputs": 1, + "x": 1358.7459678649902, + "y": 165.26919078826904, + "z": "842fbc05.cce04", + "wires": [ + [ + "e8ee65b6.e0bb98", + "8e4d05a7.18d778" + ] + ] + }, + { + "id": "e8ee65b6.e0bb98", + "type": "other", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1572.460350036621, + "y": 148.41196155548096, + "z": "842fbc05.cce04", + "wires": [ + [ + "2bb1c8ad.9ae4c8" + ] + ] + }, + { + "id": "2bb1c8ad.9ae4c8", + "type": "set", + "name": "set vnf-index=0", + "xml": "<set>\n<parameter name='vnf-index' value='0' />\n", + "comments": "", + "x": 1720.7459983825684, + "y": 145.412015914917, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "8e4d05a7.18d778", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1575.8888473510742, + "y": 193.69775295257568, + "z": "842fbc05.cce04", + "wires": [ + [ + "20358c1.fc83f74" + ] + ] + }, + { + "id": "20358c1.fc83f74", + "type": "set", + "name": "set vnf-index = vnf_length", + "xml": "<set>\n<parameter name='vnf-index' value='`$service-data.vnfs.vnf_length`' />\n", + "comments": "", + "x": 1759.7465896606445, + "y": 193.98352146148682, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "d0785948.131e88", + "type": "set", + "name": "set new vnf_length", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf_length' value='`$vnf-index + 1`' />\n", + "comments": "", + "x": 1305.746109008789, + "y": 213.26918148994446, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "2097a67.fbc2c5a", + "type": "save", + "name": "update deviceInstance configuration in AAI", + "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='device' \n key='device.device-id = $prop.vnf-id' >\n<parameter name='device-id' value='`$prop.vnf-id`' />\n<parameter name='esn' value='`$prop.device.esn`' />\n<parameter name='device-name' value='`$prop.device.name`' />\n<parameter name='description' value='`$prop.device.description`' />\n<parameter name='vendor' value='`$prop.device.vendor`' />\n<parameter name='class' value='`$prop.device.class`' />\n<parameter name='type' value='`$prop.device.deviceModel`' />\n<parameter name='version' value='`$prop.device.version`' />\n<parameter name='system-ip' value='`$prop.device.systemIp`' />\n<parameter name='operational-status' value='Created' />\n<parameter name='model-customization-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`' />\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='selflink' 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/'` \" />\n", + "comments": "", + "outputs": 1, + "x": 1115.7455749511719, + "y": 828.269118309021, + "z": "842fbc05.cce04", + "wires": [ + [] + ] + }, + { + "id": "d5a722bf.9d266", + "type": "for", + "name": "for each existing VNF", + "xml": "<for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1121.7456130981445, + "y": 280.2691307067871, + "z": "842fbc05.cce04", + "wires": [ + [ + "aceae556.187d88" + ] + ] + }, + { + "id": "7b2ea8f.f293e58", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1658.3174228668213, + "y": 328.4120855331421, + "z": "842fbc05.cce04", + "wires": [ + [ + "6db207f2.3f0a88" + ] + ] + }, + { + "id": "6db207f2.3f0a88", + "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": 1796.888780593872, + "y": 328.4120464324951, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "f8ea0727.32b188", + "type": "comment", + "name": "make sure this vnf-id doesn't exist already", + "info": "", + "comments": "", + "x": 1752.1738967895508, + "y": 457.41196870803833, + "z": "842fbc05.cce04", + "wires": [] + }, + { + "id": "aceae556.187d88", + "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": 1460.745620727539, + "y": 281.26913356781006, + "z": "842fbc05.cce04", + "wires": [ + [ + "7b2ea8f.f293e58" + ] + ] + }, + { + "id": "ff98826e.6bc6d", + "type": "set", + "name": "set sdncCreate to service data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-input-parameters.param_length].name' value=\"sdncCreate\" />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-input-parameters.param_length].value' value='`$prop.sdncCreate`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-input-parameters.param_length' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1`' />\n", + "comments": "", + "x": 628.745662689209, + "y": 861.269121170044, + "z": "842fbc05.cce04", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-deactivate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-deactivate.json new file mode 100644 index 00000000..116a08f0 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-deactivate.json @@ -0,0 +1,642 @@ +[ + { + "id": "6b385e45.7a3f5", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 139.57137298583984, + "y": 40, + "z": "757466fd.415308", + "wires": [ + [ + "1dde2ff0.4c745" + ] + ] + }, + { + "id": "1dde2ff0.4c745", + "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": 214.8570785522461, + "y": 80.23811149597168, + "z": "757466fd.415308", + "wires": [ + [ + "ea4d719e.008e2" + ] + ] + }, + { + "id": "ea4d719e.008e2", + "type": "method", + "name": "method sdwan-vnf-topology-operation-device-deactivate", + "xml": "<method rpc='sdwan-vnf-topology-operation-device-deactivate' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 208, + "y": 119.9999942779541, + "z": "757466fd.415308", + "wires": [ + [ + "8022f97f.a9e9c8" + ] + ] + }, + { + "id": "8022f97f.a9e9c8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 232.73810195922852, + "y": 310.69354248046875, + "z": "757466fd.415308", + "wires": [ + [ + "fe2f71f.5a0549", + "90ac7c05.1df59", + "62c2b68c.cb8668", + "2f2e6d66.de0b42", + "499b8fd4.89df6", + "60947bb5.977bb4", + "e2cd50c2.c2f0d", + "b764369b.fbe158", + "5d47732a.38d94c", + "58377091.27285", + "dac79818.50d828", + "744539f4.efb448", + "560d559f.36474c", + "d89f363a.ca5158" + ] + ] + }, + { + "id": "fe2f71f.5a0549", + "type": "set", + "name": "set vnf in service-data", + "xml": "<set>\n<!--parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' /-->\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.sdnc-request-header.' value='`$vnf-topology-operation-input.sdnc-request-header.`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.request-information.' value='`$vnf-topology-operation-input.request-information.`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.service-information.' value='`$vnf-topology-operation-input.service-information.`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-information.' value='`$vnf-topology-operation-input.vnf-information.`' />", + "comments": "", + "x": 488.57144927978516, + "y": 733.0002317428589, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "90ac7c05.1df59", + "type": "set", + "name": "set vnfId and vnf-object-path", + "xml": "<set>\n<parameter name='vnfId' value='`$vnf-topology-operation-input.vnf-information.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/' + $vnf-topology-operation-input.vnf-information.vnf-id + '/vnf-data/'` \" />", + "comments": "", + "x": 510.12699127197266, + "y": 775.2224426269531, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "2f2e6d66.de0b42", + "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": 468.90482330322266, + "y": 937.7777910232544, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "560d559f.36474c", + "type": "update", + "name": "update SDWAN DeviceInstance status to AAI", + "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='device' \n key='device.device-id = $vnf-topology-operation-input.vnf-information.vnf-id' >\n<parameter name='device-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' />\n<parameter name='operational-status' value='PendingDelete' />", + "comments": "", + "outputs": 1, + "x": 559.2344131469727, + "y": 878.1478223800659, + "z": "757466fd.415308", + "wires": [ + [] + ] + }, + { + "id": "62c2b68c.cb8668", + "type": "set", + "name": "set vnf-level-oper-status to PendingDelete", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.order-status' value='PendingDelete' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].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[$tmp.vidx].vnf-data.vnf-level-oper-status.last-action' value='`$vnf-topology-operation-input.request-information.request-action`' />\n", + "comments": "", + "x": 548.5714797973633, + "y": 832.0001993179321, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "58377091.27285", + "type": "get-resource", + "name": "get-resource esr-thirdparty-sdnc", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n", + "comments": "", + "outputs": 1, + "x": 515.1269454956055, + "y": 359.99996280670166, + "z": "757466fd.415308", + "wires": [ + [ + "8b902f30.1edc8", + "b3b7e1bd.bb3c3", + "92ad4991.dcb358" + ] + ] + }, + { + "id": "8b902f30.1edc8", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 742.126953125, + "y": 287.99996185302734, + "z": "757466fd.415308", + "wires": [ + [ + "59a1f255.7388fc" + ] + ] + }, + { + "id": "59a1f255.7388fc", + "type": "set", + "name": "set controller data", + "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n", + "comments": "", + "x": 940.627067565918, + "y": 278.999960899353, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "b3b7e1bd.bb3c3", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 744.6178817749023, + "y": 320.573974609375, + "z": "757466fd.415308", + "wires": [ + [ + "ed08291.4824fd8" + ] + ] + }, + { + "id": "ed08291.4824fd8", + "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 921.1893501281738, + "y": 317.85972690582275, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "92ad4991.dcb358", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 736.9508895874023, + "y": 361.90728759765625, + "z": "757466fd.415308", + "wires": [ + [ + "67ab99c4.008378" + ] + ] + }, + { + "id": "67ab99c4.008378", + "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 924.723445892334, + "y": 357.34648036956787, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "dac79818.50d828", + "type": "execute", + "name": "execute RestApiCallNode Get token", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>", + "comments": "", + "outputs": 1, + "x": 538.0155982971191, + "y": 426.1111717224121, + "z": "757466fd.415308", + "wires": [ + [ + "4b92ddae.b11014", + "be0fd00e.58fcb" + ] + ] + }, + { + "id": "4b92ddae.b11014", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 773.0155982971191, + "y": 404.1111717224121, + "z": "757466fd.415308", + "wires": [ + [ + "3d2c2dc.5e83ed2" + ] + ] + }, + { + "id": "be0fd00e.58fcb", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 765.2655982971191, + "y": 457.75405502319336, + "z": "757466fd.415308", + "wires": [ + [ + "4aad0852.c2e288" + ] + ] + }, + { + "id": "3d2c2dc.5e83ed2", + "type": "set", + "name": "set token-id", + "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n", + "comments": "", + "x": 927.0155982971191, + "y": 405.1111717224121, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "6cd389a6.9d2038", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 874.1268157958984, + "y": 641.1112051010132, + "z": "757466fd.415308", + "wires": [ + [ + "dbb22ce5.43a74" + ] + ] + }, + { + "id": "dbb22ce5.43a74", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1045.2378311157227, + "y": 639.8890256881714, + "z": "757466fd.415308", + "wires": [ + [] + ] + }, + { + "id": "4aad0852.c2e288", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 913.1266403198242, + "y": 454.00000381469727, + "z": "757466fd.415308", + "wires": [ + [] + ] + }, + { + "id": "2c8ab183.9108ce", + "type": "comment", + "name": "Do Nothing", + "info": "", + "comments": "", + "x": 1048.6822141011553, + "y": 452.88887956407336, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "532a6f26.ee36", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 870.6823692321777, + "y": 694.4444913864136, + "z": "757466fd.415308", + "wires": [ + [ + "e576dd47.e4d2d" + ] + ] + }, + { + "id": "e576dd47.e4d2d", + "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=\"Error executing Create vpn rest api\" />\n", + "comments": "", + "x": 1015.6823692321777, + "y": 697.4444913864136, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "39a32b24.2df714", + "type": "comment", + "name": "deviceId need to provide here?", + "info": "", + "comments": "", + "x": 543.9046936035156, + "y": 520.0000066757202, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "8d34776a.67e9e8", + "type": "comment", + "name": "tmp.thirdparty-sdnc-id to be hardcoded here?", + "info": "", + "comments": "", + "x": 563.9047393798828, + "y": 279.0000591278076, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "be71552d.8c5378", + "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": 803.904655456543, + "y": 1682.3333358764648, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "499b8fd4.89df6", + "type": "for", + "name": "for vidx..service-data.vnfs.vnf_length[]", + "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 547.6026229858398, + "y": 208.03125, + "z": "757466fd.415308", + "wires": [ + [ + "fbacdb2a.2187b8" + ] + ] + }, + { + "id": "fbacdb2a.2187b8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 795.9522171020508, + "y": 208.5713176727295, + "z": "757466fd.415308", + "wires": [ + [ + "14a96fbf.04e25" + ] + ] + }, + { + "id": "14a96fbf.04e25", + "type": "switchNode", + "name": "switch vnfid found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 950.0318145751953, + "y": 208.28139972686768, + "z": "757466fd.415308", + "wires": [ + [ + "f8b23c28.656e4" + ] + ] + }, + { + "id": "decdca7b.a91d08", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1243.6293258666992, + "y": 209.58171272277832, + "z": "757466fd.415308", + "wires": [ + [ + "fd53ee3f.07fb6", + "d1d20e74.92e38", + "ca9cc0c9.c9a05" + ] + ] + }, + { + "id": "f8b23c28.656e4", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1104.9838066101074, + "y": 209.17407894134521, + "z": "757466fd.415308", + "wires": [ + [ + "decdca7b.a91d08" + ] + ] + }, + { + "id": "d1d20e74.92e38", + "type": "set", + "name": "set vnf-request-input.", + "xml": "<set>\n<parameter name='vnf-request-input.' value='`$ctx.vnf-data.vnf-data.vnf-request-input.`' />\n\n", + "comments": "", + "x": 1484.9621810913086, + "y": 165.58177280426025, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "fd53ee3f.07fb6", + "type": "set", + "name": "set tmp.vidx and ctx.vnf-data", + "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].`' />\n", + "comments": "", + "x": 1512.5158920288086, + "y": 118.92413711547852, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "ca9cc0c9.c9a05", + "type": "call", + "name": "call sdwan-get-device-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-device-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 1489.6026306152344, + "y": 228.03124332427979, + "z": "757466fd.415308", + "wires": [ + [] + ] + }, + { + "id": "60947bb5.977bb4", + "type": "switchNode", + "name": "switch tmp.vidx ", + "xml": "<switch test=\"`$tmp.vidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 464.60262298583984, + "y": 250.03125, + "z": "757466fd.415308", + "wires": [ + [ + "b9a00e35.ec566" + ] + ] + }, + { + "id": "b9a00e35.ec566", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 612.0312652587891, + "y": 249.60266017913818, + "z": "757466fd.415308", + "wires": [ + [ + "32fbaa62.824b86" + ] + ] + }, + { + "id": "32fbaa62.824b86", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 761.4599914550781, + "y": 250.74557781219482, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "744539f4.efb448", + "type": "execute", + "name": "execute RestApiCallNode delete Devcie Instance", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-device-del.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v3/devices'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"delete\"/>\n<parameter name=\"responsePrefix\" value=\"deviceResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 580.6026992797852, + "y": 664.0313568115234, + "z": "757466fd.415308", + "wires": [ + [ + "6cd389a6.9d2038", + "532a6f26.ee36" + ] + ] + }, + { + "id": "e2cd50c2.c2f0d", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 488.60262298583984, + "y": 314.03125, + "z": "757466fd.415308", + "wires": [ + [] + ] + }, + { + "id": "b764369b.fbe158", + "type": "set", + "name": "set device Id length and deviceId", + "xml": "<set>\n<parameter name='prop.devices[0]' value='`$prop.device.deviceId`' />\n\n\n", + "comments": "", + "x": 520.6026458740234, + "y": 601.0312871932983, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "5d47732a.38d94c", + "type": "set", + "name": "set device Id length and deviceId", + "xml": "<set>\n<parameter name='prop.devices_length' value='1' />\n\n\n", + "comments": "", + "x": 524.6026229858398, + "y": 559.03125, + "z": "757466fd.415308", + "wires": [] + }, + { + "id": "d89f363a.ca5158", + "type": "call", + "name": "call sdwan-get-tenant-auth", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-tenant-auth' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 531.00390625, + "y": 476.00390625, + "z": "757466fd.415308", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-delete.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-delete.json new file mode 100644 index 00000000..1a71611e --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-delete.json @@ -0,0 +1,656 @@ +[ + { + "id": "a1df0c8c.e610f", + "type": "switchNode", + "name": "switch service-data.vnfs.vnf_length", + "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n", + "comments": "", + "outputs": 1, + "x": 652.5634536743164, + "y": 312.26116919517517, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "a23f9932.76df28", + "eec5abe1.727dc8" + ] + ] + }, + { + "id": "dda3e77b.e1de28", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 114.46875, + "y": 76.9999988079071, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "b55d96f3.653dc8" + ] + ] + }, + { + "id": "b55d96f3.653dc8", + "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": 189.75445556640625, + "y": 117.23811030387878, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "e0c2d3e0.8a2bb" + ] + ] + }, + { + "id": "8ad52b68.cd0138", + "type": "comment", + "name": "wan port-vnf-topology-operation-delete", + "info": "", + "comments": "", + "x": 563.8136672973633, + "y": 150.58639788627625, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "c136d1d8.af3e6", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 191.13541412353516, + "y": 378.6666705608368, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "a72c9897.585208", + "d19a177f.7de988", + "30536e3.568f592", + "a1df0c8c.e610f", + "9db50f7b.a0897", + "4dffba9e.fd0434", + "28632f25.b7972", + "af6ad43e.5c24e8", + "743e7718.e7f968", + "4b8bdd76.d28184", + "cb6608fc.bd5f68" + ] + ] + }, + { + "id": "a23f9932.76df28", + "type": "other", + "name": "outcome Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 917.2857666015625, + "y": 294.81679129600525, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "81cc943f.50f958" + ] + ] + }, + { + "id": "81cc943f.50f958", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1098.2856369018555, + "y": 289.81666922569275, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "eec5abe1.727dc8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 902.7857666015625, + "y": 346.8167541027069, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "679d4612.15d218" + ] + ] + }, + { + "id": "679d4612.15d218", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1074.785472869873, + "y": 346.8167521953583, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "862951df.5fe1d", + "dc6fa4c3.5ecea8" + ] + ] + }, + { + "id": "dc6fa4c3.5ecea8", + "type": "switchNode", + "name": "switch tmp.vidx ", + "xml": "<switch test=\"`$tmp.vidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1249.78564453125, + "y": 365.81667399406433, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "1c173742.b90799" + ] + ] + }, + { + "id": "30536e3.568f592", + "type": "switchNode", + "name": "switch vnf-level-oper-status", + "xml": "<switch test='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.order-status`'>\n", + "comments": "", + "outputs": 1, + "x": 622.9524536132812, + "y": 386.70563292503357, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "ba7f62e0.c87a8", + "246d8ed1.13b9e2" + ] + ] + }, + { + "id": "ba7f62e0.c87a8", + "type": "outcome", + "name": "outcome PendingDelete", + "xml": "<outcome value='PendingDelete'>\n", + "comments": "", + "outputs": 1, + "x": 913.7857208251953, + "y": 390.81675601005554, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "7fe1211e.ac713" + ] + ] + }, + { + "id": "246d8ed1.13b9e2", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 880.7858581542969, + "y": 442.8168087005615, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "7d27948.1b45c6c" + ] + ] + }, + { + "id": "7d27948.1b45c6c", + "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 is not in appropriate state for activate. Current state is ' + $service-data.vnfs.vnf[$tmp.nidx].vnf-data.vnf-level-oper-status.order-status`\" />", + "comments": "", + "x": 1040.2856254577637, + "y": 445.8168077468872, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "9db50f7b.a0897", + "type": "switchNode", + "name": "switch vnf-id", + "xml": "<switch test=\"`$vnf-topology-operation-input.vnf-information.vnf-id`\">\n", + "comments": "", + "outputs": 1, + "x": 588.7857704162598, + "y": 267.81676268577576, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "2d92055a.30ffda" + ] + ] + }, + { + "id": "2d92055a.30ffda", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 786.7858352661133, + "y": 257.81677508354187, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "889ae61d.096b48" + ] + ] + }, + { + "id": "889ae61d.096b48", + "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-request-input.vnf-input-parameters.name is a required input\" />\n", + "comments": "", + "x": 953.2857208251953, + "y": 254.81676936149597, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "862951df.5fe1d", + "type": "for", + "name": "for vidx..service-data.vnfs.vnf[]", + "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1310.2856483459473, + "y": 301.81667017936707, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "91f5b0d9.94102" + ] + ] + }, + { + "id": "91f5b0d9.94102", + "type": "switchNode", + "name": "switch vnf-id found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1566.2856674194336, + "y": 301.81667017936707, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "8dc7c708.bc5718" + ] + ] + }, + { + "id": "8dc7c708.bc5718", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1742.7857208251953, + "y": 304.81667017936707, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "2d4f17e9.19c368" + ] + ] + }, + { + "id": "dd40fac0.73a058", + "type": "set", + "name": "set tmp.vidx and ctx.vnf-data", + "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].vnf-data.`' />\n", + "comments": "", + "x": 2159.785934448242, + "y": 383.8167221546173, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "59a5fc66.f24204", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1555.285659790039, + "y": 365.81667399406433, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "1c173742.b90799", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1417.785659790039, + "y": 365.81667399406433, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "59a5fc66.f24204" + ] + ] + }, + { + "id": "a72c9897.585208", + "type": "set", + "name": "set vnfId and vnf-object-path", + "xml": "<set>\n<parameter name='vnfId' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' />\n<parameter name='vnf-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vnf-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'` \" />", + "comments": "", + "x": 596.8022003173828, + "y": 689.3334522247314, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "d19a177f.7de988", + "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": 545.9133987426758, + "y": 808.8889608383179, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "7fe1211e.ac713", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1111.0921211242676, + "y": 401.14191031455994, + "z": "42785b1.0f2e6a4", + "wires": [ + [] + ] + }, + { + "id": "e0c2d3e0.8a2bb", + "type": "method", + "name": "method sdwan-vnf-topology-operation-device-delete", + "xml": "<method rpc='sdwan-vnf-topology-operation-device-delete' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 195, + "y": 233.26116919517517, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "c136d1d8.af3e6" + ] + ] + }, + { + "id": "4dffba9e.fd0434", + "type": "execute", + "name": "execute requiredParameters", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='requiredParameters' >\n<parameter name=\"vnf-topology-operation-input.vnf-information.vnf-id\" value=\"$vnf-topology-operation-input.vnf-information.vnf-id\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 646.2858276367188, + "y": 207.81676173210144, + "z": "42785b1.0f2e6a4", + "wires": [ + [] + ] + }, + { + "id": "7385dfef.35179", + "type": "delete", + "name": "delete wan port instance configuration in AAI", + "xml": "<delete plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" resource='device' \n key='device.device-id = $vnf-topology-operation-input.vnf-information.vnf-id'>\n", + "comments": "", + "outputs": 1, + "x": 1073.0003051757812, + "y": 744.261435508728, + "z": "42785b1.0f2e6a4", + "wires": [ + [] + ] + }, + { + "id": "3c959d82.f7e672", + "type": "call", + "name": "call sdwan-get-device-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-device-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 2151.5635147094727, + "y": 328.2611758708954, + "z": "42785b1.0f2e6a4", + "wires": [ + [] + ] + }, + { + "id": "5f3e6fd4.e37e8", + "type": "set", + "name": "set vnf-request-input.", + "xml": "<set>\n<parameter name='vnf-request-input.' value='`$ctx.vnf-data.vnf-data.vnf-request-input.`' />\n\n", + "comments": "", + "x": 2146.923065185547, + "y": 265.81170535087585, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "94ec2391.e8ee4", + "type": "set", + "name": "set tmp.vidx and ctx.vnf-data", + "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].`' />\n", + "comments": "", + "x": 2174.476776123047, + "y": 219.15406966209412, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "2d4f17e9.19c368", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1912.563331604004, + "y": 306.26116919517517, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "dd40fac0.73a058", + "3c959d82.f7e672", + "5f3e6fd4.e37e8", + "94ec2391.e8ee4" + ] + ] + }, + { + "id": "28632f25.b7972", + "type": "switchNode", + "name": "switch prop.device.sdncCreate", + "xml": "<switch test=\"`$prop.device.sdncCreate`\">\n", + "comments": "", + "outputs": 1, + "x": 597.5636672973633, + "y": 752.2614345550537, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "d02123b.6bfe7e" + ] + ] + }, + { + "id": "d02123b.6bfe7e", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 804.5635223388672, + "y": 749.2612714767456, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "7385dfef.35179" + ] + ] + }, + { + "id": "af6ad43e.5c24e8", + "type": "set", + "name": "set prop.vnfNewidx", + "xml": "<set>\n<parameter name='prop.vnfidxLen' value='`0`' />\n", + "comments": "", + "x": 589.0000381469727, + "y": 454.0000276565552, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "743e7718.e7f968", + "type": "for", + "name": "for lidx..service-data.vnfs.vnf[]", + "xml": "<for index='lidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 615.9999580383301, + "y": 518.0000123977661, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "25a69c7c.cd2204" + ] + ] + }, + { + "id": "25a69c7c.cd2204", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 859.9999389648438, + "y": 543.9999718666077, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "2e7532f9.d7b9be" + ] + ] + }, + { + "id": "2e7532f9.d7b9be", + "type": "switchNode", + "name": "switch vnf-id found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$lidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1051.999885559082, + "y": 553.0000162124634, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "fb34ff49.abebe" + ] + ] + }, + { + "id": "4b8bdd76.d28184", + "type": "set", + "name": "set new vnf length", + "xml": "<set>\n\t<parameter name=\"service-data.vnfs.vnf_length\" value='`$prop.vnfidxLen`'/>\n\n\t\n", + "comments": "", + "x": 582.1013412475586, + "y": 568.8043041229248, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "fb34ff49.abebe", + "type": "outcomeFalse", + "name": "false", + "xml": "<outcome value='false'>\n", + "comments": "", + "outputs": 1, + "x": 1237.999900817871, + "y": 536.9999027252197, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "aa789605.e97ae8" + ] + ] + }, + { + "id": "aa789605.e97ae8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1388.9998245239258, + "y": 537.9999389648438, + "z": "42785b1.0f2e6a4", + "wires": [ + [ + "79843b9d.c445e4", + "fcd82b9e.5e0628" + ] + ] + }, + { + "id": "79843b9d.c445e4", + "type": "set", + "name": "set vnf data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$prop.vnfidxLen].vnf-id' value='`$service-data.vnfs.vnf[$lidx].vnf-id`' />\n<parameter name='service-data.vnfs.vnf[$prop.vnfidxLen].vnf-data.' value='`$service-data.vnfs.vnf[$lidx].vnf-data.`' />\n", + "comments": "", + "x": 1553.9999198913574, + "y": 513.0000944137573, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "fcd82b9e.5e0628", + "type": "set", + "name": "set prop.vnfNewidx", + "xml": "<set>\n<parameter name='prop.vnfidxLen' value='`$prop.vnfidxLen + 1`' />\n", + "comments": "", + "x": 1575.9999198913574, + "y": 569.0000581741333, + "z": "42785b1.0f2e6a4", + "wires": [] + }, + { + "id": "cb6608fc.bd5f68", + "type": "set", + "name": "Remove vnf from ServiceData", + "xml": "<set>\n\t<parameter name=\"service-data.vnfs.vnf[$prop.vnfidxLen].\" value=\"\"/>\n\n", + "comments": "", + "x": 621, + "y": 630, + "z": "42785b1.0f2e6a4", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-activate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-activate.json new file mode 100644 index 00000000..12e88e0a --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-activate.json @@ -0,0 +1,1623 @@ +[ + { + "id": "d6f12b23.a89678", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 97, + "y": 43, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "c865ab04.6af178" + ] + ] + }, + { + "id": "c865ab04.6af178", + "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": 228.2856903076172, + "y": 92.23810863494873, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "6872e2ee.d6997c" + ] + ] + }, + { + "id": "6872e2ee.d6997c", + "type": "method", + "name": "method sdwan-vnf-topology-operation-wanport-activate", + "xml": "<method rpc='sdwan-vnf-topology-operation-wanport-activate' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 231.42861938476562, + "y": 177.00003242492676, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "e8a5051a.b42f68" + ] + ] + }, + { + "id": "e8a5051a.b42f68", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 294.66675567626953, + "y": 782.666989326477, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "8f3957a7.d167f8", + "4891bde.3538244", + "ffc944ec.552788", + "d579e51d.f36088", + "d09273d4.34d5b", + "d8cffa08.c70f58", + "272d2403.37c86c", + "b6ab2db8.206f6", + "e9d254c6.c408a8", + "2a8c1af8.df5bf6", + "ee4c5d7e.eaa99", + "455c32c0.dc954c", + "dc56d269.4a63b", + "1286c83c.18ccc8", + "de66785c.628fe8", + "8b82d2e5.53604", + "a401887.73e5778", + "863a36e8.4a5b78", + "2c809153.c42dee", + "2c725167.90a60e" + ] + ] + }, + { + "id": "8f3957a7.d167f8", + "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": 621.334529876709, + "y": 1514.3347115516663, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "2a8c1af8.df5bf6", + "type": "execute", + "name": "execute RestApiCallNode device port create", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-port.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/ports'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"portResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 709.3341102600098, + "y": 777.889497756958, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "e20e98c1.35cd38", + "6f78988b.f50df8" + ] + ] + }, + { + "id": "e20e98c1.35cd38", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 958.3341693878174, + "y": 791.8897037506104, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "bed4bc3f.f5932" + ] + ] + }, + { + "id": "6f78988b.f50df8", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 958.3341693878174, + "y": 753.8895392417908, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "8f1b4806.f6c948" + ] + ] + }, + { + "id": "8f1b4806.f6c948", + "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=\"Error executing Create device port rest api\" />\n", + "comments": "", + "x": 1102.3345031738281, + "y": 752.8895387649536, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "bed4bc3f.f5932", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1105.3341808319092, + "y": 792.8895425796509, + "z": "725c7d45.19d1f4", + "wires": [ + [] + ] + }, + { + "id": "ee4c5d7e.eaa99", + "type": "execute", + "name": "execute RestApiCallNode get transport network info", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/network-orchestration-resources'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"get\"/>\n<parameter name=\"responsePrefix\" value=\"transportNetworksResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 732.0004615783691, + "y": 957.0006031990051, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "72b3b752.f6bbf8", + "f75c8efc.5bc38" + ] + ] + }, + { + "id": "dc56d269.4a63b", + "type": "execute", + "name": "execute RestApiCallNode wan port create", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-wan-port.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/transport-network-ports'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"wanPortResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 705.0005531311035, + "y": 1194.000651359558, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "b358fdc8.47501", + "e8f33bf4.d74a28" + ] + ] + }, + { + "id": "4891bde.3538244", + "type": "switchNode", + "name": "switch service-data.vnfs.vnf_length", + "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n", + "comments": "", + "outputs": 1, + "x": 691.0209350585938, + "y": 121.02091217041016, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "bba0a2df.9b7fe", + "f5df4ed9.043ee", + "ad1fb0e6.30f2b" + ] + ] + }, + { + "id": "bba0a2df.9b7fe", + "type": "other", + "name": "Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 943.0209693908691, + "y": 122.02099323272705, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "2105bad4.c6ead6" + ] + ] + }, + { + "id": "2105bad4.c6ead6", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1104.7987174987793, + "y": 101.90994024276733, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "f5df4ed9.043ee", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 936.0213775634766, + "y": 155.02099704742432, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "e4ac49d6.f30708" + ] + ] + }, + { + "id": "e4ac49d6.f30708", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 959.2908935546875, + "y": 253.57559204101562, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "3335cf85.18b", + "646eb0ad.764a7", + "47895138.250a9", + "af3fc11d.805b3", + "38c64027.0dbb1" + ] + ] + }, + { + "id": "3335cf85.18b", + "type": "for", + "name": "for vidx..service-data.vnfs.vnf_length[]", + "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1239.3070373535156, + "y": 147.44955825805664, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "a85a6118.25ae3" + ] + ] + }, + { + "id": "646eb0ad.764a7", + "type": "switchNode", + "name": "switch tmp.vidx ", + "xml": "<switch test=\"`$tmp.vidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1165.608341217041, + "y": 293.43279361724854, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "e159f8e9.ab1288" + ] + ] + }, + { + "id": "e159f8e9.ab1288", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1313.0369834899902, + "y": 293.0042037963867, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "50911a7c.bcb394" + ] + ] + }, + { + "id": "ce82d617.853858", + "type": "switchNode", + "name": "switch vnfid found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1612.7362670898438, + "y": 146.69972038269043, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "bc627350.7812f" + ] + ] + }, + { + "id": "50911a7c.bcb394", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1462.4657096862793, + "y": 294.14712142944336, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "bc627350.7812f", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1767.6882591247559, + "y": 147.59239959716797, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "2709419e.cb1d4e" + ] + ] + }, + { + "id": "f97e5dae.1c8e2", + "type": "set", + "name": "set tmp.vidx and ctx.vnf-data", + "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].`' />\n", + "comments": "", + "x": 2175.220344543457, + "y": 57.34245777130127, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "ad1fb0e6.30f2b", + "type": "outcome", + "name": "0", + "xml": "<outcome value='0'>\n", + "comments": "", + "outputs": 1, + "x": 944.9897193908691, + "y": 85.98967933654785, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "2105bad4.c6ead6" + ] + ] + }, + { + "id": "1286c83c.18ccc8", + "type": "set", + "name": "set device PortId to service data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].name' value='devicePortId' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].value' value='`$prop.wan.devicePortId`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1`' />\n\n\n\n\n", + "comments": "", + "x": 673.9909210205078, + "y": 1250.9912090301514, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "57e2b01e.38cf7", + "type": "comment", + "name": "Get siteId from site resource created for this service", + "info": "", + "comments": "", + "x": 716.9899826049805, + "y": 306.32321643829346, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "a85a6118.25ae3", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1458.6566696166992, + "y": 146.98963832855225, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "ce82d617.853858" + ] + ] + }, + { + "id": "ffc944ec.552788", + "type": "set", + "name": "set vnfId and vnf-object-path", + "xml": "<set>\n<parameter name='vnfId' value='`$vnf-topology-operation-input.vnf-information.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/' + $vnf-topology-operation-input.vnf-information.vnf-id + '/vnf-data/'` \" />", + "comments": "", + "x": 654.5462341308594, + "y": 1393.213122844696, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "d579e51d.f36088", + "type": "set", + "name": "set vnf-level-oper-status to Active", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.order-status' value='Active' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].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[$tmp.vidx].vnf-data.vnf-level-oper-status.last-action' value='`$vnf-topology-operation-input.request-information.request-action`' />\n", + "comments": "", + "x": 671.9906959533691, + "y": 1432.9909586906433, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "2c809153.c42dee", + "type": "update", + "name": "update SDWAN wan port instance configuration in AAI", + "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='wan-port-config' \n key='wan-port-config.wan-port-config-id = $vnf-topology-operation-input.vnf-information.vnf-id' >\n<parameter name=\"wan-port-config-id\" value=\"`$vnf-topology-operation-input.vnf-information.vnf-id`\" />\n<parameter name='operational-status' value='Active' />\n<parameter name='device-port-id' value='`$prop.wan.devicePortId`' />\n<parameter name='wan-port-id' value='`$prop.wan.wanPortId`' />\n<parameter name='model-customization-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`' />\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", + "comments": "", + "outputs": 1, + "x": 734.653621673584, + "y": 1472.1384205818176, + "z": "725c7d45.19d1f4", + "wires": [ + [] + ] + }, + { + "id": "1e8c7f90.773b9", + "type": "set", + "name": "set prop.wan.transportNetworkId", + "xml": "<set>\n<parameter name='prop.wan.transportNetworkId' value='`$transportNetworksResp.data.transportNetworks[$tidx].id`' />\n", + "comments": "", + "x": 1486.991542816162, + "y": 1033.9906749725342, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "863a36e8.4a5b78", + "type": "for", + "name": "for loop sidx - Get siteId from servicedata", + "xml": "<for index=\"sidx\" start=\"0\" end=\"`$ctx.site.vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 696.9900054931641, + "y": 456.9898729324341, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "72a58ce.4542a74" + ] + ] + }, + { + "id": "4130ca31.df2bc4", + "type": "switchNode", + "name": "switch siteId", + "xml": "<switch test=\"`$ctx.site.vnf-data.vnf-request-input.vnf-input-parameters.param[$sidx].name == 'siteId'`\">\n", + "comments": "", + "outputs": 1, + "x": 1127.990333557129, + "y": 457.99000358581543, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "8e36b04f.9057d" + ] + ] + }, + { + "id": "8e36b04f.9057d", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1265.9907913208008, + "y": 455.98998832702637, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "b3f426b3.22a238" + ] + ] + }, + { + "id": "b3f426b3.22a238", + "type": "set", + "name": "set prop.wan.siteId", + "xml": "<set>\n<parameter name='prop.wan.siteId' value='`$ctx.site.vnf-data.vnf-request-input.vnf-input-parameters.param[$sidx].value`' />\n\n\n", + "comments": "", + "x": 1429.9908256530762, + "y": 457.58984184265137, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "455c32c0.dc954c", + "type": "execute", + "name": "execute split ip and mask", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$prop.wan.ipAddress`'/>\n<parameter name=\"regex\" value=\"/\"/>\n<parameter name=\"ctx_memory_result_key\" value=\"ipandMask\"/>\n", + "comments": "", + "outputs": 1, + "x": 655.9903297424316, + "y": 1102.3236436843872, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "33727da5.4478c2", + "c855dead.051b" + ] + ] + }, + { + "id": "c855dead.051b", + "type": "failure", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 856.990348815918, + "y": 1080.3236351013184, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "fd37a12c.b50dd" + ] + ] + }, + { + "id": "33727da5.4478c2", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 856.9903526306152, + "y": 1121.3236389160156, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "92f41c8f.e77c6" + ] + ] + }, + { + "id": "fd37a12c.b50dd", + "type": "set", + "name": "set ipAddress prefixLength", + "xml": "<set>\n<parameter name='prop.wan.ip-address' value='`$ipandMask[0]`' />\n<parameter name='prop.wan.prefixLength' value='`$ipandMask[1]`' />", + "comments": "", + "x": 1053.9903678894043, + "y": 1078.3236351013184, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "92f41c8f.e77c6", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n<parameter name='error-code' value='' />\n<parameter name='error-message' value=\"An error occured while splitting sna1_route\" />\n", + "comments": "", + "x": 1011.9903602600098, + "y": 1118.3236379623413, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "b6ab2db8.206f6", + "type": "get-resource", + "name": "get-resource esr-thirdparty-sdnc", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n", + "comments": "", + "outputs": 1, + "x": 671.4901733398438, + "y": 554.9899291992188, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "a209acee.17706", + "69e80906.c6c388", + "4690f303.905dfc" + ] + ] + }, + { + "id": "a209acee.17706", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 903.4902572631836, + "y": 518.9899520874023, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "fb6bcdc7.90b7a" + ] + ] + }, + { + "id": "69e80906.c6c388", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 905.9811401367188, + "y": 554.5639886856079, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "deef5ce.ffc72a" + ] + ] + }, + { + "id": "4690f303.905dfc", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 901.3141479492188, + "y": 590.8973474502563, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "340f62b3.ca041e" + ] + ] + }, + { + "id": "340f62b3.ca041e", + "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1055.0866394042969, + "y": 588.3364343643188, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "deef5ce.ffc72a", + "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1051.5525360107422, + "y": 552.8496761322021, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "fb6bcdc7.90b7a", + "type": "set", + "name": "set controller data", + "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n", + "comments": "", + "x": 1063.9903678894043, + "y": 516.9898920059204, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "d09273d4.34d5b", + "type": "record", + "name": "record", + "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"sdwan-wanport-vnf-topology-operation-activate\"/>\n<parameter name=\"field3\" value=\"SDWAN-Activate\"/>\n", + "comments": "", + "outputs": 1, + "x": 609.0000953674316, + "y": 177.00003004074097, + "z": "725c7d45.19d1f4", + "wires": [ + [] + ] + }, + { + "id": "d8cffa08.c70f58", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 645.3022193908691, + "y": 212.00007390975952, + "z": "725c7d45.19d1f4", + "wires": [ + [] + ] + }, + { + "id": "e9d254c6.c408a8", + "type": "execute", + "name": "execute RestApiCallNode Get token", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>", + "comments": "", + "outputs": 1, + "x": 686.0003051757812, + "y": 642.6669311523438, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "a2457d23.490bb", + "5d853693.ee5348" + ] + ] + }, + { + "id": "a2457d23.490bb", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 921.000431060791, + "y": 628.666919708252, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "7f12a9ec.69af78" + ] + ] + }, + { + "id": "7f12a9ec.69af78", + "type": "set", + "name": "set token-id", + "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n", + "comments": "", + "x": 1063.0004386901855, + "y": 627.6669206619263, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "e009ac00.02e288", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1069.0004386901855, + "y": 665.0599088668823, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "5d853693.ee5348", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 920.250431060791, + "y": 664.3098268508911, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "e009ac00.02e288" + ] + ] + }, + { + "id": "693677dc.0ea4c8", + "type": "switchNode", + "name": "switch transportNetworkName same", + "xml": "<switch test=\"`$transportNetworksResp.data.transportNetworks[$tidx].name == $prop.wan.transportNetworkName`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1126.0011558532715, + "y": 991.6670732498169, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "9e43cce2.daed1" + ] + ] + }, + { + "id": "9e43cce2.daed1", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1339.0006065368652, + "y": 991.6669912338257, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "1e8c7f90.773b9" + ] + ] + }, + { + "id": "29298ea3.31ff42", + "type": "switchNode", + "name": "switch ActivateSDWANDeviceInstance", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-data.request-information.request-action == 'ActivateSDWANDeviceInstance'`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 1553.3336029052734, + "y": 224.00005722045898, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "fb2628da.07ec78" + ] + ] + }, + { + "id": "fb2628da.07ec78", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1776.3336124420166, + "y": 224.00005722045898, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "9e951e79.2dbb" + ] + ] + }, + { + "id": "252b812c.b944de", + "type": "set", + "name": "set tmp.devicevidx", + "xml": "<set>\n<parameter name='tmp.devicevidx' value='`$vidx`' />\n\n", + "comments": "", + "x": 2741.3329467773438, + "y": 655.0000820159912, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "38c64027.0dbb1", + "type": "switchNode", + "name": "switch tmp.devicevidx", + "xml": "<switch test=\"`$tmp.devicevidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1206.3335304260254, + "y": 382.0001196861267, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "6a752755.afd058" + ] + ] + }, + { + "id": "6a752755.afd058", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1390.7620964050293, + "y": 382.57155656814575, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "12b129f0.1b9176" + ] + ] + }, + { + "id": "12b129f0.1b9176", + "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=\"ActivateSDWANDeviceInstance not found in service-data\" />\n", + "comments": "", + "x": 1531.1908378601074, + "y": 382.71443605422974, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "c3c15a47.6f9888", + "type": "comment", + "name": "Get deviceId from device resource created for this service", + "info": "", + "comments": "", + "x": 2190.6668853759766, + "y": 321.33333587646484, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "ebfe3788.f179e8", + "type": "for", + "name": "for loop didx - Get deviceId from servicedata", + "xml": "<for index=\"didx\" start=\"0\" end=\"`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2176.667095184326, + "y": 244.99997997283936, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "f245906e.04acd" + ] + ] + }, + { + "id": "3b8aa7d6.529fd8", + "type": "switchNode", + "name": "switch name (DeviceName)", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$didx].name == 'name'`\">\n", + "comments": "", + "outputs": 1, + "x": 2194.667694091797, + "y": 383.0002250671387, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "ce416efb.e644d" + ] + ] + }, + { + "id": "ce416efb.e644d", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2396.668186187744, + "y": 377.0002851486206, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "f3d4ecf0.f7b57" + ] + ] + }, + { + "id": "72a58ce.4542a74", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 959.0001983642578, + "y": 457.66669750213623, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "4130ca31.df2bc4" + ] + ] + }, + { + "id": "f245906e.04acd", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1968.999984741211, + "y": 381.6667261123657, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "3b8aa7d6.529fd8" + ] + ] + }, + { + "id": "ab84c87e.6641a8", + "type": "switchNode", + "name": "switch deviceId", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$deviceidx].name == 'deviceId'`\">\n", + "comments": "", + "outputs": 1, + "x": 3040.0011444091797, + "y": 595.6670227050781, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "dad5dabe.45cb08" + ] + ] + }, + { + "id": "dad5dabe.45cb08", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3193.0015144348145, + "y": 596.6670999526978, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "38c10a48.67b606" + ] + ] + }, + { + "id": "38c10a48.67b606", + "type": "set", + "name": "set prop.wan.deviceId", + "xml": "<set>\n<parameter name='prop.wan.deviceId' value='`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$deviceidx].value`' />\n", + "comments": "", + "x": 3362.0021209716797, + "y": 595.2671346664429, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "9e951e79.2dbb", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1917.6669311523438, + "y": 246.00007724761963, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "ebfe3788.f179e8" + ] + ] + }, + { + "id": "f3d4ecf0.f7b57", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 2215.0012283325195, + "y": 460.0002546310425, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "794ddeb5.82822" + ] + ] + }, + { + "id": "a5f1b6ac.935608", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2604.0019340515137, + "y": 463.00037956237793, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "900215dc.3d2d28" + ] + ] + }, + { + "id": "2709419e.cb1d4e", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1906.3337783813477, + "y": 148.00003337860107, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "f97e5dae.1c8e2", + "8b284d74.9bbdc", + "12ee38df.f58297", + "21551932.828fc6" + ] + ] + }, + { + "id": "d5734767.c41348", + "type": "set", + "name": "set prop.wan.wanPortId", + "xml": "<set>\n<parameter name='prop.wan.wanPortId' value='`$wanPortResp.success[0].id`' />\n", + "comments": "", + "x": 1353.3246459960938, + "y": 1194.6573886871338, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "de66785c.628fe8", + "type": "set", + "name": "set prop.wan.devicePortId", + "xml": "<set>\n<parameter name='prop.wan.devicePortId' value='`$portResp.success[0].id`' />\n", + "comments": "", + "x": 663.9913177490234, + "y": 839.9906539916992, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "cf3fd46b.92ea68", + "type": "comment", + "name": "Create port", + "info": "", + "comments": "", + "x": 611.0000495910645, + "y": 744.3335218429565, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "712fc701.3b6c28", + "type": "comment", + "name": "Get network id", + "info": "", + "comments": "", + "x": 662.0001220703125, + "y": 922.3334802985191, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "4db86c63.765344", + "type": "comment", + "name": "Create wan port", + "info": "", + "comments": "", + "x": 629.0002059936523, + "y": 1055.3336935043335, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "e8f33bf4.d74a28", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 991.0001220703125, + "y": 1154.0002393722534, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "18a023ce.91febc" + ] + ] + }, + { + "id": "b358fdc8.47501", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 991.0001182556152, + "y": 1194.0004043579102, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "c181c64d.e790a8" + ] + ] + }, + { + "id": "c181c64d.e790a8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1135.0001335144043, + "y": 1193.000241279602, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "d5734767.c41348" + ] + ] + }, + { + "id": "2ecf07cd.e22e08", + "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=\"Error executing Create wan port rest api\" />\n", + "comments": "", + "x": 1313.00048828125, + "y": 1153.0002708435059, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "f75c8efc.5bc38", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1038.0000495910645, + "y": 905.0001783370972, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "cd3f079c.c86e78" + ] + ] + }, + { + "id": "72b3b752.f6bbf8", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1038.0000457763672, + "y": 945.0003433227539, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "7039d1d0.8c0e2" + ] + ] + }, + { + "id": "7039d1d0.8c0e2", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1182.0000610351562, + "y": 944.0001802444458, + "z": "725c7d45.19d1f4", + "wires": [ + [] + ] + }, + { + "id": "cd3f079c.c86e78", + "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=\"Error executing Get transport network info rest api\" />\n", + "comments": "", + "x": 1180.0003814697266, + "y": 904.0001783370972, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "12ee38df.f58297", + "type": "call", + "name": "call sdwan-get-wan-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-wan-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 2178.666633605957, + "y": 154.0000762939453, + "z": "725c7d45.19d1f4", + "wires": [ + [] + ] + }, + { + "id": "8b284d74.9bbdc", + "type": "set", + "name": "set vnf-request-input.", + "xml": "<set>\n<parameter name='vnf-request-input.' value='`$ctx.vnf-data.vnf-data.vnf-request-input.`' />\n\n", + "comments": "", + "x": 2147.666633605957, + "y": 104.00009346008301, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "6fa219f1.a7d198", + "type": "comment", + "name": "This is also required for template parameters update", + "info": "", + "comments": "", + "x": 2543.0003967285156, + "y": 200.00003623962402, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "7a10e528.449ffc", + "type": "switchNode", + "name": "switch ActivateSiteInstance", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-data.request-information.request-action == 'ActivateSiteInstance'`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 1516.0004425048828, + "y": 189.00004959106445, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "8d8e3a.201b51c8" + ] + ] + }, + { + "id": "8d8e3a.201b51c8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1712.0006256103516, + "y": 190.00004959106445, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "3f667c94.ca8ee4" + ] + ] + }, + { + "id": "3f667c94.ca8ee4", + "type": "set", + "name": "set tmp.siteVidx", + "xml": "<set>\n<parameter name='tmp.siteVidx' value='`$vidx`' />\n<parameter name='ctx.site.' value='`$service-data.vnfs.vnf[$vidx].`' />\n\n", + "comments": "", + "x": 1897.9999237060547, + "y": 187.00005340576172, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "af3fc11d.805b3", + "type": "switchNode", + "name": "switch tmp.siteVidx", + "xml": "<switch test=\"`$tmp.siteVidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1189.6667518615723, + "y": 331.00007009506226, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "bee9b4a0.4631e8" + ] + ] + }, + { + "id": "bee9b4a0.4631e8", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1364.0954627990723, + "y": 331.5715217590332, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "cf86c583.f350f8" + ] + ] + }, + { + "id": "cf86c583.f350f8", + "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=\"ActivateSiteInstance not found in service-data\" />\n", + "comments": "", + "x": 1506.5241813659668, + "y": 330.71438455581665, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "794ddeb5.82822", + "type": "switchNode", + "name": "switch deviceName match", + "xml": "<switch test=\"`$prop.wan.deviceName == $service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$didx].value`\">\n\n\n", + "comments": "", + "outputs": 1, + "x": 2420.667953491211, + "y": 461.0003185272217, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "a5f1b6ac.935608" + ] + ] + }, + { + "id": "900215dc.3d2d28", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 2503.3338928222656, + "y": 535.0001621246338, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "841824ee.9d9cb8", + "252b812c.b944de" + ] + ] + }, + { + "id": "841824ee.9d9cb8", + "type": "for", + "name": "for loop deviceidx - Get deviceId from servicedata", + "xml": "<for index=\"deviceidx\" start=\"0\" end=\"`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2783.5310440063477, + "y": 530.0313510894775, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "3d6ed093.e41e3" + ] + ] + }, + { + "id": "3d6ed093.e41e3", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 2860.5317764282227, + "y": 594.0314502716064, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "ab84c87e.6641a8" + ] + ] + }, + { + "id": "21551932.828fc6", + "type": "record", + "name": "record", + "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\".....\"/>\n<parameter name=\"field3\" value=\"prop.wan.deviceName\"/>\n<parameter name=\"field4\" value='`$prop.wan.deviceName`'/>\n", + "comments": "", + "outputs": 1, + "x": 2106.531379699707, + "y": 202.0312671661377, + "z": "725c7d45.19d1f4", + "wires": [ + [] + ] + }, + { + "id": "47895138.250a9", + "type": "for", + "name": "for vidx..service-data.vnfs.vnf_length[]", + "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1232.000072479248, + "y": 225.0000171661377, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "29298ea3.31ff42", + "7a10e528.449ffc" + ] + ] + }, + { + "id": "272d2403.37c86c", + "type": "set", + "name": "copy input data to service data", + "xml": "<set>\n<!--parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' /-->\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.sdnc-request-header.' value='$vnf-topology-operation-input.sdnc-request-header.' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.request-information.' value='$vnf-topology-operation-input.request-information.' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.service-information.' value='$vnf-topology-operation-input.service-information.' />", + "comments": "", + "x": 667.0312881469727, + "y": 1347.5314326286316, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "41e3ce3b.fd6", + "type": "comment", + "name": "TODO: split ip/mask", + "info": "", + "comments": "", + "x": 1053, + "y": 1040.5039072036743, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "bddbd7b0.3cac18", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 905.0008735656738, + "y": 993.3337669372559, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "693677dc.0ea4c8" + ] + ] + }, + { + "id": "8b82d2e5.53604", + "type": "for", + "name": "for loop tidx - Get transportNetwork ID", + "xml": "<for index=\"tidx\" start=\"0\" end=\"`$transportNetworksResp.data.transportNetworks_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 689.0004920959473, + "y": 992.3335227966309, + "z": "725c7d45.19d1f4", + "wires": [ + [ + "bddbd7b0.3cac18" + ] + ] + }, + { + "id": "a401887.73e5778", + "type": "set", + "name": "set wan portId to service data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].name' value='wanPortId' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].value' value='`$prop.wan.wanPortId`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1`' />\n\n\n\n\n", + "comments": "", + "x": 668.0000152587891, + "y": 1297.250274181366, + "z": "725c7d45.19d1f4", + "wires": [] + }, + { + "id": "2c725167.90a60e", + "type": "call", + "name": "call sdwan-get-tenant-auth", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-tenant-auth' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 661, + "y": 698, + "z": "725c7d45.19d1f4", + "wires": [ + [] + ] + }, + { + "id": "18a023ce.91febc", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1135.0039672851562, + "y": 1152.5039310455322, + "z": "725c7d45.19d1f4", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-create.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-create.json new file mode 100644 index 00000000..5bbf0a49 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-create.json @@ -0,0 +1,443 @@ +[ + { + "id": "58d8ca80.754ee4", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 86, + "y": 38, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "9b331136.66aea" + ] + ] + }, + { + "id": "9b331136.66aea", + "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": 185.28569793701172, + "y": 112.23810789268464, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "ec9fe349.f9372" + ] + ] + }, + { + "id": "ec9fe349.f9372", + "type": "method", + "name": "method sdwan-vnf-topology-operation-wanport-create", + "xml": "<method rpc='sdwan-vnf-topology-operation-wanport-create' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 209.42861938476562, + "y": 201.0000195503235, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "87efdcb1.d6671" + ] + ] + }, + { + "id": "87efdcb1.d6671", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 317.6667022705078, + "y": 408.66668367385864, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "daaa1789.61ed38", + "40e846a4.f63368", + "b8f54335.fcb32", + "4e193e5a.f6bb9", + "83c99a9.e9d4868", + "c7efce39.0f90c", + "596fe131.2f016", + "ee0f7cd9.73819", + "618cf28.a3bd10c", + "2794c131.0510ce", + "4dbd7ea2.8473c", + "a279f8fb.0934f8", + "4f31f3dc.48bbdc" + ] + ] + }, + { + "id": "daaa1789.61ed38", + "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": 607.3336334228516, + "y": 860.3338012695312, + "z": "5ff8bbe7.b04e84", + "wires": [] + }, + { + "id": "40e846a4.f63368", + "type": "save", + "name": "save sdwan device port configuration in AAI", + "xml": "<save plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='wan-port-config' \n key='wan-port-config.wan-port-config-id = $prop.vnf-index' >\n<parameter name=\"wan-port-config-id\" value=\"`$prop.vnf-index`\" />\n<parameter name=\"wan-port-config-name\" value=\"`$prop.wan.name`\" />\n<parameter name=\"device-id\" value=\"`$prop.wan.deviceName`\" />\n<parameter name='vlan-id' value=\"`$prop.wan.vlanId`\" />\n<parameter name=\"ip-address\" value=\"`$prop.wan.ipAddress`\" />\n<parameter name=\"provider-ip-address\" value=\"`$prop.wan.providerIpAddress`\" />\n<parameter name=\"input-bandwidth\" value=\"`$prop.wan.inputBandwidth`\" />\n<parameter name=\"output-bandwidth\" value=\"`$prop.wan.outputBandwidth`\" />\n<parameter name=\"description\" value=\"`$prop.wan.description`\" />\n<parameter name=\"port-type\" value=\"`$prop.wan.portType`\" />\n<parameter name=\"port-number\" value=\"`$prop.wan.portNumber`\" />\n<parameter name=\"transport-network-name\" value=\"`$prop.wan.transportNetworkName`\" />\n<parameter name='operational-status' value='Created' />\n<parameter name='model-customization-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`' />\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='selflink' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/' + $vnf-topology-operation-input.service-information.service-instance-id + '/service-data/vnfs/vnf/' + $prop.vnf-index + '/vnf-data/'` \" />\n", + "comments": "", + "outputs": 1, + "x": 694.0003890991211, + "y": 767.5560441017151, + "z": "5ff8bbe7.b04e84", + "wires": [ + [] + ] + }, + { + "id": "b8f54335.fcb32", + "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": 672.0004577636719, + "y": 434.67542362213135, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "acd8d091.0d71d" + ] + ] + }, + { + "id": "acd8d091.0d71d", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 886.7788009643555, + "y": 432.23100757598877, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "828392b5.41563", + "a73faa8e.c89ba8" + ] + ] + }, + { + "id": "cf40793a.a6d2e8", + "type": "comment", + "name": "set input parameters", + "info": "", + "comments": "", + "x": 890.6736488342285, + "y": 560.5970115661621, + "z": "5ff8bbe7.b04e84", + "wires": [] + }, + { + "id": "4e193e5a.f6bb9", + "type": "switchNode", + "name": "switch service-data.vnfs.vnf_length", + "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n", + "comments": "", + "outputs": 1, + "x": 682.9898223876953, + "y": 131.59689903259277, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "54b6d1d2.416d5", + "503b3e94.4de07" + ] + ] + }, + { + "id": "54b6d1d2.416d5", + "type": "other", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 919.7040500640869, + "y": 121.7397289276123, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "b3cfe846.219ca8" + ] + ] + }, + { + "id": "503b3e94.4de07", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 915.1327667236328, + "y": 160.02557945251465, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "f27d7807.d35938" + ] + ] + }, + { + "id": "f27d7807.d35938", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1047.8469619750977, + "y": 165.02551937103271, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "7ed2d1b2.320ec", + "e6e34bc5.a44238" + ] + ] + }, + { + "id": "b3cfe846.219ca8", + "type": "set", + "name": "set vnf-index=0", + "xml": "<set>\n<parameter name='vnf-index' value='0' />\n", + "comments": "", + "x": 1075.9898643493652, + "y": 120.73980903625488, + "z": "5ff8bbe7.b04e84", + "wires": [] + }, + { + "id": "7ed2d1b2.320ec", + "type": "set", + "name": "set vnf-index = vnf_length", + "xml": "<set>\n<parameter name='vnf-index' value='`$service-data.vnfs.vnf_length`' />\n", + "comments": "", + "x": 1276.989875793457, + "y": 137.31122303009033, + "z": "5ff8bbe7.b04e84", + "wires": [] + }, + { + "id": "e6e34bc5.a44238", + "type": "for", + "name": "for each existing VNF", + "xml": "<for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1259.418342590332, + "y": 177.31118488311768, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "e6e708fd.086418" + ] + ] + }, + { + "id": "e6e708fd.086418", + "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": 1617.7041244506836, + "y": 176.88268852233887, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "f6e0def3.d2f88" + ] + ] + }, + { + "id": "55da435b.f5309c", + "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": 2060.5610961914062, + "y": 177.4541187286377, + "z": "5ff8bbe7.b04e84", + "wires": [] + }, + { + "id": "f6e0def3.d2f88", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1922.9897651672363, + "y": 176.45411491394043, + "z": "5ff8bbe7.b04e84", + "wires": [ + [ + "55da435b.f5309c" + ] + ] + }, + { + "id": "c7efce39.0f90c", + "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-index\"/>\n", + "comments": "", + "outputs": 1, + "x": 661.9897155761719, + "y": 263.59686851501465, + "z": "5ff8bbe7.b04e84", + "wires": [ + [] + ] + }, + { + "id": "83c99a9.e9d4868", + "type": "set", + "name": "set new vnf_length", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf_length' value='`$vnf-index + 1`' />\n", + "comments": "", + "x": 635.9897003173828, + "y": 228.59687662124634, + "z": "5ff8bbe7.b04e84", + "wires": [] + }, + { + "id": "ee0f7cd9.73819", + "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": 680.9897918701172, + "y": 679.5971269607544, + "z": "5ff8bbe7.b04e84", + "wires": [] + }, + { + "id": "596fe131.2f016", + "type": "set", + "name": "copy input data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-id' value='`$prop.vnf-index`' />\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": 614.8429145812988, + "y": 633.5933895111084, + "z": "5ff8bbe7.b04e84", + "wires": [] + }, + { + "id": "618cf28.a3bd10c", + "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=\"wan-port-config\" />\n<parameter name=\"relationship-list.relationship[0].related-link\" value=\"`'/network/wan-port-configs/wan-port-config/' + $prop.vnf-index`\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-key\" value=\"wan-port-config.wan-port-config-id\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-value\" value=\"`$prop.vnf-index`\" />", + "comments": "", + "outputs": 1, + "x": 664.9897918701172, + "y": 815.5972166061401, + "z": "5ff8bbe7.b04e84", + "wires": [ + [] + ] + }, + { + "id": "2794c131.0510ce", + "type": "set", + "name": "set vnf-index and vnf-object-path", + "xml": "<set>\n<parameter name='vnfId' value='`$prop.vnf-index`' />\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-index + '/vnf-data/'` \" />", + "comments": "", + "x": 667.9897232055664, + "y": 723.597137928009, + "z": "5ff8bbe7.b04e84", + "wires": [] + }, + { + "id": "4dbd7ea2.8473c", + "type": "record", + "name": "record", + "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"sdwan-wanport-vnf-topology-operation-create\"/>\n<parameter name=\"field3\" value=\"SDWAN-Config\"/>\n", + "comments": "", + "outputs": 1, + "x": 600.0000267028809, + "y": 316.0000305175781, + "z": "5ff8bbe7.b04e84", + "wires": [ + [] + ] + }, + { + "id": "93da82db.2cdc9", + "type": "comment", + "name": "Take the parameter names by removing prefix", + "info": "", + "comments": "", + "x": 780.0003204345703, + "y": 404.0000858306885, + "z": "5ff8bbe7.b04e84", + "wires": [] + }, + { + "id": "828392b5.41563", + "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": 1100.034912109375, + "y": 382.9791307449341, + "z": "5ff8bbe7.b04e84", + "wires": [ + [] + ] + }, + { + "id": "a73faa8e.c89ba8", + "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": 1068.4794158935547, + "y": 451.97921657562256, + "z": "5ff8bbe7.b04e84", + "wires": [] + }, + { + "id": "a279f8fb.0934f8", + "type": "call", + "name": "call sdwan-get-wan-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-wan-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 645.0004463195801, + "y": 565.0004005432129, + "z": "5ff8bbe7.b04e84", + "wires": [ + [] + ] + }, + { + "id": "4f31f3dc.48bbdc", + "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": 626.0000305175781, + "y": 532.000147819519, + "z": "5ff8bbe7.b04e84", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-deactivate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-deactivate.json new file mode 100644 index 00000000..af6f26c4 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-deactivate.json @@ -0,0 +1,736 @@ +[ + { + "id": "160bd41b.750adc", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 97, + "y": 50, + "z": "60265787.2327c8", + "wires": [ + [ + "7010ff28.09428" + ] + ] + }, + { + "id": "7010ff28.09428", + "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": 245.2856903076172, + "y": 100.23810863494873, + "z": "60265787.2327c8", + "wires": [ + [ + "f412ee4c.d62e7" + ] + ] + }, + { + "id": "f412ee4c.d62e7", + "type": "method", + "name": "method sdwan-vnf-topology-operation-wanport-deactivate", + "xml": "<method rpc='sdwan-vnf-topology-operation-wanport-deactivate' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 279.4286117553711, + "y": 184.0000171661377, + "z": "60265787.2327c8", + "wires": [ + [ + "cc23525.50310b" + ] + ] + }, + { + "id": "cc23525.50310b", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 254.66670608520508, + "y": 568.6666831970215, + "z": "60265787.2327c8", + "wires": [ + [ + "8af94d5d.882d", + "db706027.a79c1", + "a0bc8740.7ee818", + "13704b55.ddb7b5", + "f6e2bea8.930d7", + "1d165946.98b807", + "e263e9f9.47b878", + "ec6fef57.1d937", + "f2ee43ab.85fef" + ] + ] + }, + { + "id": "8af94d5d.882d", + "type": "switchNode", + "name": "switch service-data.vnfs.vnf_length", + "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n", + "comments": "", + "outputs": 1, + "x": 760.0209541320801, + "y": 93.02095350623131, + "z": "60265787.2327c8", + "wires": [ + [ + "80fd0bfd.39f738", + "7b7c3289.46689c", + "eedac48f.477958" + ] + ] + }, + { + "id": "80fd0bfd.39f738", + "type": "other", + "name": "Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1003.020881652832, + "y": 118.02103647589684, + "z": "60265787.2327c8", + "wires": [ + [ + "bd8e7274.c99a" + ] + ] + }, + { + "id": "bd8e7274.c99a", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1151.7983932495117, + "y": 97.90997156500816, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "7b7c3289.46689c", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1004.0212059020996, + "y": 151.02105936408043, + "z": "60265787.2327c8", + "wires": [ + [ + "fc040973.03bed8" + ] + ] + }, + { + "id": "fc040973.03bed8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1151.2909088134766, + "y": 140.5755818784237, + "z": "60265787.2327c8", + "wires": [ + [ + "41b2ec7a.c9fac4", + "ed9b9aab.53af18" + ] + ] + }, + { + "id": "41b2ec7a.c9fac4", + "type": "for", + "name": "for vidx..service-data.vnfs.vnf_length[]", + "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1396.306869506836, + "y": 92.44958147406578, + "z": "60265787.2327c8", + "wires": [ + [ + "da4ef740.d83fa8" + ] + ] + }, + { + "id": "ed9b9aab.53af18", + "type": "switchNode", + "name": "switch tmp.vidx ", + "xml": "<switch test=\"`$tmp.vidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1327.6082229614258, + "y": 140.432760566473, + "z": "60265787.2327c8", + "wires": [ + [ + "742d2b6f.de3234" + ] + ] + }, + { + "id": "742d2b6f.de3234", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1481.0368614196777, + "y": 139.00417360663414, + "z": "60265787.2327c8", + "wires": [ + [ + "373d4940.5a03b6" + ] + ] + }, + { + "id": "cf1a968e.65c658", + "type": "switchNode", + "name": "switch vnfid found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1767.735450744629, + "y": 89.69969400763512, + "z": "60265787.2327c8", + "wires": [ + [ + "6d3e9e16.89bfe" + ] + ] + }, + { + "id": "373d4940.5a03b6", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1617.4652557373047, + "y": 138.14703592658043, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "6d3e9e16.89bfe", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1806.687599182129, + "y": 144.59241327643394, + "z": "60265787.2327c8", + "wires": [ + [ + "c733e74a.c143c8" + ] + ] + }, + { + "id": "eedac48f.477958", + "type": "outcome", + "name": "0", + "xml": "<outcome value='0'>\n", + "comments": "", + "outputs": 1, + "x": 999.9896278381348, + "y": 85.9897321164608, + "z": "60265787.2327c8", + "wires": [ + [ + "bd8e7274.c99a" + ] + ] + }, + { + "id": "da4ef740.d83fa8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1615.6565017700195, + "y": 91.98964247107506, + "z": "60265787.2327c8", + "wires": [ + [ + "cf1a968e.65c658" + ] + ] + }, + { + "id": "db706027.a79c1", + "type": "set", + "name": "set vnf in service-data", + "xml": "<set>\n<!--parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' /-->\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.sdnc-request-header.' value='`$vnf-topology-operation-input.sdnc-request-header.`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.request-information.' value='`$vnf-topology-operation-input.request-information.`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.service-information.' value='`$vnf-topology-operation-input.service-information.`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-information.' value='`$vnf-topology-operation-input.vnf-information.`' />\n\n", + "comments": "", + "x": 715.334171295166, + "y": 741.6668876111507, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "a0bc8740.7ee818", + "type": "set", + "name": "set vnfId and vnf-object-path", + "xml": "<set>\n<parameter name='vnfId' value='`$vnf-topology-operation-input.vnf-information.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/' + $vnf-topology-operation-input.vnf-information.vnf-id + '/vnf-data/'` \" />", + "comments": "", + "x": 727.8898124694824, + "y": 798.8891824185848, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "13704b55.ddb7b5", + "type": "set", + "name": "set vnf-level-oper-status to PendingDelete", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.order-status' value='PendingDelete' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].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[$tmp.vidx].vnf-data.vnf-level-oper-status.last-action' value='`$vnf-topology-operation-input.request-information.request-action`' />\n", + "comments": "", + "x": 770.3341865539551, + "y": 833.6670182645321, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "f6e2bea8.930d7", + "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": 680.6675567626953, + "y": 922.4448512494564, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "e263e9f9.47b878", + "type": "get-resource", + "name": "get-resource esr-thirdparty-sdnc", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n", + "comments": "", + "outputs": 1, + "x": 740.5003604888916, + "y": 261.0001236796379, + "z": "60265787.2327c8", + "wires": [ + [ + "553a8d46.b43834", + "4956fcb2.4927a4", + "b5f5e61a.4229a8" + ] + ] + }, + { + "id": "553a8d46.b43834", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 959.5003299713135, + "y": 220.00012025237083, + "z": "60265787.2327c8", + "wires": [ + [ + "f8d39c98.f3e5a" + ] + ] + }, + { + "id": "4956fcb2.4927a4", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 962.9912967681885, + "y": 267.5741558969021, + "z": "60265787.2327c8", + "wires": [ + [ + "60e56df6.080ca4" + ] + ] + }, + { + "id": "b5f5e61a.4229a8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 958.3243045806885, + "y": 308.90746888518333, + "z": "60265787.2327c8", + "wires": [ + [ + "15107992.3c8136" + ] + ] + }, + { + "id": "15107992.3c8136", + "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1146.0968608856201, + "y": 304.34666165709496, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "60e56df6.080ca4", + "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1139.562707901001, + "y": 255.85989198088646, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "f8d39c98.f3e5a", + "type": "set", + "name": "set controller data", + "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n", + "comments": "", + "x": 1140.0004329681396, + "y": 214.00015896558762, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "1d346910.f82317", + "type": "execute", + "name": "execute RestApiCallNode device port delete", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-device-port-del.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/ports/action/batch-delete'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"portResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 773.0005130767822, + "y": 636.6668682992458, + "z": "60265787.2327c8", + "wires": [ + [ + "42db533e.b56eac", + "3455c58f.b562ea" + ] + ] + }, + { + "id": "42db533e.b56eac", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1019.0004978179932, + "y": 674.6669569909573, + "z": "60265787.2327c8", + "wires": [ + [ + "77804da4.2bade4" + ] + ] + }, + { + "id": "3455c58f.b562ea", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1015.0005779266357, + "y": 628.6668721139431, + "z": "60265787.2327c8", + "wires": [ + [ + "7c085513.57701c" + ] + ] + }, + { + "id": "7c085513.57701c", + "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=\"Error executing Create vpn rest api\" />\n", + "comments": "", + "x": 1156.0006694793701, + "y": 628.6668730676174, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "77804da4.2bade4", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1163.0003643035889, + "y": 672.6668759286404, + "z": "60265787.2327c8", + "wires": [ + [] + ] + }, + { + "id": "b1683370.08944", + "type": "execute", + "name": "execute RestApiCallNode wan port delete", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-wan-port-del.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/transport-network-ports/action/batch-delete'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"portResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 764.0006809234619, + "y": 529.6668654382229, + "z": "60265787.2327c8", + "wires": [ + [ + "25b510d9.36284", + "3a348892.4f4ad8" + ] + ] + }, + { + "id": "25b510d9.36284", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 997.0007762908936, + "y": 562.6668578088284, + "z": "60265787.2327c8", + "wires": [ + [ + "cc96ff80.a3e57" + ] + ] + }, + { + "id": "3a348892.4f4ad8", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1001.0008563995361, + "y": 498.6669360101223, + "z": "60265787.2327c8", + "wires": [ + [ + "ce0c3d97.4bdf8" + ] + ] + }, + { + "id": "ce0c3d97.4bdf8", + "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=\"Error executing Create vpn rest api\" />\n", + "comments": "", + "x": 1146.001028060913, + "y": 500.6669360101223, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "cc96ff80.a3e57", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1153.0006198883057, + "y": 560.6668578088284, + "z": "60265787.2327c8", + "wires": [ + [] + ] + }, + { + "id": "1d165946.98b807", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 707.9999885559082, + "y": 136.00003084540367, + "z": "60265787.2327c8", + "wires": [ + [] + ] + }, + { + "id": "ec6fef57.1d937", + "type": "execute", + "name": "execute RestApiCallNode Get token", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>", + "comments": "", + "outputs": 1, + "x": 757.0002689361572, + "y": 399.6666949689388, + "z": "60265787.2327c8", + "wires": [ + [ + "4f27175.40c29e8", + "50a6cd99.43e804" + ] + ] + }, + { + "id": "4f27175.40c29e8", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 991.0003070831299, + "y": 385.66671976447105, + "z": "60265787.2327c8", + "wires": [ + [ + "ba76090.b8b84f8" + ] + ] + }, + { + "id": "50a6cd99.43e804", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 984.2502689361572, + "y": 431.3095782697201, + "z": "60265787.2327c8", + "wires": [ + [ + "a32d5aa2.e0b408" + ] + ] + }, + { + "id": "a32d5aa2.e0b408", + "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=\"Error executing get token rest api\" />\n", + "comments": "", + "x": 1137.0002689361572, + "y": 431.0596393048763, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "ba76090.b8b84f8", + "type": "set", + "name": "set token-id", + "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n", + "comments": "", + "x": 1145.0003070831299, + "y": 386.66671976447105, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "c733e74a.c143c8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1947.0001106262207, + "y": 145.00004610419273, + "z": "60265787.2327c8", + "wires": [ + [ + "2115f98.c329d06", + "5f1edf6a.5abca", + "e126aeff.fd3f4" + ] + ] + }, + { + "id": "f2ee43ab.85fef", + "type": "update", + "name": "update SDWAN wan port instance configuration in AAI", + "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='wan-port-config' \n key='wan-port-config.wan-port-config-id = $vnf-topology-operation-input.vnf-information.vnf-id' >\n<parameter name='wan-port-config-id' value=\"`$vnf-topology-operation-input.vnf-information.vnf-id`\" />\n<parameter name='operational-status' value='PendingDelete' />\n<parameter name='model-customization-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`' />\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", + "comments": "", + "outputs": 1, + "x": 793.0002861022949, + "y": 875.0004304349422, + "z": "60265787.2327c8", + "wires": [ + [] + ] + }, + { + "id": "2115f98.c329d06", + "type": "set", + "name": "set tmp.vidx and ctx.vnf-data", + "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].`' />\n", + "comments": "", + "x": 2197.0313453674316, + "y": 96.03129276633263, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "5f1edf6a.5abca", + "type": "set", + "name": "set vnf-request-input.", + "xml": "<set>\n<parameter name='vnf-request-input.' value='`$ctx.vnf-data.vnf-data.vnf-request-input.`' />\n\n", + "comments": "", + "x": 2169.4776344299316, + "y": 142.68892845511436, + "z": "60265787.2327c8", + "wires": [] + }, + { + "id": "e126aeff.fd3f4", + "type": "call", + "name": "call sdwan-get-wan-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-wan-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 2193.477584838867, + "y": 192.6889165341854, + "z": "60265787.2327c8", + "wires": [ + [] + ] + }, + { + "id": "e35c5cc.ba705a", + "type": "call", + "name": "call sdwan-get-tenant-auth", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-tenant-auth' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 727, + "y": 462, + "z": "60265787.2327c8", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-delete.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-delete.json new file mode 100644 index 00000000..bf71f28b --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-delete.json @@ -0,0 +1,569 @@ +[ + { + "id": "d97ddb0b.9dbae8", + "type": "switchNode", + "name": "switch service-data.vnfs.vnf_length", + "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n", + "comments": "", + "outputs": 1, + "x": 657.5634536743164, + "y": 290.26117038726807, + "z": "298a9201.dd932e", + "wires": [ + [ + "78101855.a55318", + "303c0757.9740d8" + ] + ] + }, + { + "id": "ffc786dd.6d3ce8", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 119.46875, + "y": 55, + "z": "298a9201.dd932e", + "wires": [ + [ + "19627a0c.fad7f6" + ] + ] + }, + { + "id": "19627a0c.fad7f6", + "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": 194.75445556640625, + "y": 95.23811149597168, + "z": "298a9201.dd932e", + "wires": [ + [ + "90edfff9.8d8dc" + ] + ] + }, + { + "id": "89fc7e96.e130c", + "type": "comment", + "name": "wan port-vnf-topology-operation-delete", + "info": "", + "comments": "", + "x": 568.8136672973633, + "y": 128.58639907836914, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "12b8b4a9.73677b", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 196.13541412353516, + "y": 356.6666717529297, + "z": "298a9201.dd932e", + "wires": [ + [ + "79e6b6ed.e79cf8", + "a877fa3c.5b8268", + "86a0bf6e.0b80b", + "d97ddb0b.9dbae8", + "c603984a.796d78", + "b1f3fdb5.343c9", + "c5c45c6b.923e9", + "96916512.691c98", + "f2a5223f.497fa", + "14bdc57f.29da0b", + "9171f0e2.d13bf" + ] + ] + }, + { + "id": "78101855.a55318", + "type": "other", + "name": "outcome Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 922.2857666015625, + "y": 272.81679248809814, + "z": "298a9201.dd932e", + "wires": [ + [ + "74e8241b.eea89c" + ] + ] + }, + { + "id": "74e8241b.eea89c", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1103.2856369018555, + "y": 267.81667041778564, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "303c0757.9740d8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 907.7857666015625, + "y": 324.8167552947998, + "z": "298a9201.dd932e", + "wires": [ + [ + "1483b08f.bc2c8f" + ] + ] + }, + { + "id": "1483b08f.bc2c8f", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1079.785472869873, + "y": 324.8167533874512, + "z": "298a9201.dd932e", + "wires": [ + [ + "e9c362d9.eda3b", + "c7e2b23c.082b2" + ] + ] + }, + { + "id": "c7e2b23c.082b2", + "type": "switchNode", + "name": "switch tmp.vidx ", + "xml": "<switch test=\"`$tmp.vidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1254.78564453125, + "y": 343.8166751861572, + "z": "298a9201.dd932e", + "wires": [ + [ + "b277af35.24bde" + ] + ] + }, + { + "id": "86a0bf6e.0b80b", + "type": "switchNode", + "name": "switch vnf-level-oper-status", + "xml": "<switch test='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.order-status`'>\n", + "comments": "", + "outputs": 1, + "x": 627.9524536132812, + "y": 364.70563411712646, + "z": "298a9201.dd932e", + "wires": [ + [ + "bebaa9f9.5133d8", + "de5a57a9.6e5c38" + ] + ] + }, + { + "id": "bebaa9f9.5133d8", + "type": "outcome", + "name": "outcome PendingDelete", + "xml": "<outcome value='PendingDelete'>\n", + "comments": "", + "outputs": 1, + "x": 918.7857208251953, + "y": 368.81675720214844, + "z": "298a9201.dd932e", + "wires": [ + [ + "a8bce4a2.2db818" + ] + ] + }, + { + "id": "de5a57a9.6e5c38", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 864.7857818603516, + "y": 415.8167610168457, + "z": "298a9201.dd932e", + "wires": [ + [ + "c9cdcb18.116a68" + ] + ] + }, + { + "id": "c9cdcb18.116a68", + "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 is not in appropriate state for activate. Current state is ' + $service-data.vnfs.vnf[$tmp.nidx].vnf-data.vnf-level-oper-status.order-status`\" />", + "comments": "", + "x": 1024.2855491638184, + "y": 418.8167600631714, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "c603984a.796d78", + "type": "switchNode", + "name": "switch vnf-id", + "xml": "<switch test=\"`$vnf-topology-operation-input.vnf-information.vnf-id`\">\n", + "comments": "", + "outputs": 1, + "x": 593.7857704162598, + "y": 245.81676387786865, + "z": "298a9201.dd932e", + "wires": [ + [ + "9c65cfbe.e7f66" + ] + ] + }, + { + "id": "9c65cfbe.e7f66", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 791.7858352661133, + "y": 235.81677627563477, + "z": "298a9201.dd932e", + "wires": [ + [ + "16c05e83.252251" + ] + ] + }, + { + "id": "16c05e83.252251", + "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-request-input.vnf-input-parameters.name is a required input\" />\n", + "comments": "", + "x": 958.2857208251953, + "y": 232.81677055358887, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "e9c362d9.eda3b", + "type": "for", + "name": "for vidx..service-data.vnfs.vnf[]", + "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1315.2856483459473, + "y": 279.81667137145996, + "z": "298a9201.dd932e", + "wires": [ + [ + "76ffd99.2cf1928" + ] + ] + }, + { + "id": "76ffd99.2cf1928", + "type": "switchNode", + "name": "switch vnf-id found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1571.2856674194336, + "y": 279.81667137145996, + "z": "298a9201.dd932e", + "wires": [ + [ + "157a2e27.614112" + ] + ] + }, + { + "id": "157a2e27.614112", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1747.7857208251953, + "y": 282.81667137145996, + "z": "298a9201.dd932e", + "wires": [ + [ + "9ee7d32a.eb396" + ] + ] + }, + { + "id": "9ee7d32a.eb396", + "type": "set", + "name": "set tmp.vidx and ctx.vnf-data", + "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].vnf-data.`' />\n", + "comments": "", + "x": 1914.7857360839844, + "y": 343.81667137145996, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "b167d24d.6ae55", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1560.285659790039, + "y": 343.8166751861572, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "b277af35.24bde", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1422.785659790039, + "y": 343.8166751861572, + "z": "298a9201.dd932e", + "wires": [ + [ + "b167d24d.6ae55" + ] + ] + }, + { + "id": "79e6b6ed.e79cf8", + "type": "set", + "name": "set vnfId and vnf-object-path", + "xml": "<set>\n<parameter name='vnfId' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' />\n<parameter name='vnf-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vnf-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'` \" />", + "comments": "", + "x": 599.8022537231445, + "y": 647.3334503173828, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "a877fa3c.5b8268", + "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": 572.913516998291, + "y": 772.8888854980469, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "c5c45c6b.923e9", + "type": "set", + "name": "set new vnf length", + "xml": "<set>\n\t<parameter name=\"service-data.vnfs.vnf_length\" value='`$prop.vnfidxLen`'/>\n\n\t\n", + "comments": "", + "x": 577.4347686767578, + "y": 555.8044013977051, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "a8bce4a2.2db818", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1116.0921211242676, + "y": 379.14191150665283, + "z": "298a9201.dd932e", + "wires": [ + [] + ] + }, + { + "id": "90edfff9.8d8dc", + "type": "method", + "name": "method sdwan-vnf-topology-operation-wanport-delete", + "xml": "<method rpc='sdwan-vnf-topology-operation-wanport-delete' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 200, + "y": 211.26117038726807, + "z": "298a9201.dd932e", + "wires": [ + [ + "12b8b4a9.73677b" + ] + ] + }, + { + "id": "b1f3fdb5.343c9", + "type": "execute", + "name": "execute requiredParameters", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='requiredParameters' >\n<parameter name=\"vnf-topology-operation-input.vnf-information.vnf-id\" value=\"$vnf-topology-operation-input.vnf-information.vnf-id\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 651.2858276367188, + "y": 185.81676292419434, + "z": "298a9201.dd932e", + "wires": [ + [] + ] + }, + { + "id": "96916512.691c98", + "type": "delete", + "name": "delete wan port instance configuration in AAI", + "xml": "<delete plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" resource='wan-port-config' \n key='wan-port-config.wan-port-config-id = $vnf-topology-operation-input.vnf-information.vnf-id'>\n", + "comments": "", + "outputs": 1, + "x": 649.0001983642578, + "y": 685.2611904144287, + "z": "298a9201.dd932e", + "wires": [ + [] + ] + }, + { + "id": "f2a5223f.497fa", + "type": "for", + "name": "for lidx..service-data.vnfs.vnf[]", + "xml": "<for index='lidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 611.3333854675293, + "y": 505.0001096725464, + "z": "298a9201.dd932e", + "wires": [ + [ + "53b23540.75768c" + ] + ] + }, + { + "id": "53b23540.75768c", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 855.333366394043, + "y": 531.0000691413879, + "z": "298a9201.dd932e", + "wires": [ + [ + "52fdf367.fb37ac" + ] + ] + }, + { + "id": "52fdf367.fb37ac", + "type": "switchNode", + "name": "switch vnf-id found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$lidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1047.3333129882812, + "y": 540.0001134872437, + "z": "298a9201.dd932e", + "wires": [ + [ + "ae48a2e3.38f76" + ] + ] + }, + { + "id": "ae48a2e3.38f76", + "type": "outcomeFalse", + "name": "false", + "xml": "<outcome value='false'>\n", + "comments": "", + "outputs": 1, + "x": 1233.3333282470703, + "y": 524, + "z": "298a9201.dd932e", + "wires": [ + [ + "617570c9.1b48" + ] + ] + }, + { + "id": "8341b52b.a87b88", + "type": "set", + "name": "set vnf data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$prop.vnfidxLen].vnf-id' value='`$service-data.vnfs.vnf[$lidx].vnf-id`' />\n<parameter name='service-data.vnfs.vnf[$prop.vnfidxLen].vnf-data.' value='`$service-data.vnfs.vnf[$lidx].vnf-data.`' />\n", + "comments": "", + "x": 1549.3333473205566, + "y": 500.0001916885376, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "14bdc57f.29da0b", + "type": "set", + "name": "set prop.vnfNewidx", + "xml": "<set>\n<parameter name='prop.vnfidxLen' value='`0`' />\n", + "comments": "", + "x": 576.3333892822266, + "y": 469.0000686645508, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "45e47923.545468", + "type": "set", + "name": "set prop.vnfNewidx", + "xml": "<set>\n<parameter name='prop.vnfidxLen' value='`$prop.vnfidxLen + 1`' />\n", + "comments": "", + "x": 1571.3333473205566, + "y": 556.0001554489136, + "z": "298a9201.dd932e", + "wires": [] + }, + { + "id": "617570c9.1b48", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1384.333251953125, + "y": 525.000036239624, + "z": "298a9201.dd932e", + "wires": [ + [ + "8341b52b.a87b88", + "45e47923.545468" + ] + ] + }, + { + "id": "9171f0e2.d13bf", + "type": "set", + "name": "Remove vnf from ServiceData", + "xml": "<set>\n\t<parameter name=\"service-data.vnfs.vnf[$prop.vnfidxLen].\" value=\"\"/>\n\n", + "comments": "", + "x": 613.0000534057617, + "y": 598.0000357627869, + "z": "298a9201.dd932e", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-wanport-vnf-topology-operation-underlay.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-wanport-vnf-topology-operation-underlay.json new file mode 100644 index 00000000..b04fe607 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-wanport-vnf-topology-operation-underlay.json @@ -0,0 +1,4315 @@ +[ + { + "id": "df1ca662.8747b8", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 92, + "y": 26, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "f03eb016.75be2" + ] + ] + }, + { + "id": "f03eb016.75be2", + "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": 208.2856903076172, + "y": 77.23810768127441, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "d1c55e79.a107d" + ] + ] + }, + { + "id": "d1c55e79.a107d", + "type": "method", + "name": "method sdwan-wanport-vnf-topology-operation-underlay", + "xml": "<method rpc='sdwan-wanport-vnf-topology-operation-underlay' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 211.42861938476562, + "y": 162.00003147125244, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "39b0cbc5.a6e634" + ] + ] + }, + { + "id": "39b0cbc5.a6e634", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 143.66668701171875, + "y": 270.66673278808594, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "6e5ac20d.e60c4c", + "b99b3963.4b1368", + "962ad5c3.0da1a8", + "da982ae7.c19088", + "546d6174.f994f" + ] + ] + }, + { + "id": "6e5ac20d.e60c4c", + "type": "for", + "name": "for cidx..service-data.consumed-allotted-resources.consumed-allotted-resource[]", + "xml": "<for index='cidx' start='0' end='`$service-data.consumed-allotted-resources.consumed-allotted-resource_length`' >\n", + "comments": "", + "outputs": 1, + "x": 578.000431060791, + "y": 409.6668539047241, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "ad0a3663.ab8598" + ] + ] + }, + { + "id": "2acab811.c13ee8", + "type": "set", + "name": "set prop.ar.allotted-resource-id", + "xml": "<set>\n<parameter name='prop.ar.allotted-resource-id' value='`$service-data.consumed-allotted-resources.consumed-allotted-resource[$cidx].allotted-resource-id`' />\n", + "comments": "", + "x": 1368.0013427734375, + "y": 98.96877861022949, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "4102e103.78e0d", + "type": "comment", + "name": "Query MDSAL for AR", + "info": "", + "comments": "", + "x": 1693.3340148925781, + "y": 122.96864795684814, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "2988c3dc.9f08bc", + "type": "comment", + "name": "Query MDSAL to get parent service based on service instance id from AR", + "info": "", + "comments": "", + "x": 2163.334873199463, + "y": 141.96862697601318, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "43ba54c6.bea31c", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1942.66841506958, + "y": 177.63526725769043, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "90fef119.efb27" + ] + ] + }, + { + "id": "90fef119.efb27", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2097.668254852295, + "y": 177.13510036468506, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "3f50e700.ebbfb8" + ] + ] + }, + { + "id": "22fe4487.ea79bc", + "type": "other", + "name": "outcome 1", + "xml": "<outcome value='1'>\n", + "comments": "", + "outputs": 1, + "x": 2421.3587913513184, + "y": 173.75424098968506, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "eb3089e9.bab518" + ] + ] + }, + { + "id": "202db162.ce306e", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"Error: Connection attachement resource not found\" />\n \n", + "comments": "", + "x": 2567.1275672912598, + "y": 213.20122909545898, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "b9e47095.da1a3", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1935.5201416015625, + "y": 224.70127391815186, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1559b306.93fa9d" + ] + ] + }, + { + "id": "1559b306.93fa9d", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2085.5199851989746, + "y": 225.36782932281494, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "6807513b.840e7" + ] + ] + }, + { + "id": "d76066f5.ec2ac8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2409.6867446899414, + "y": 211.03460121154785, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "202db162.ce306e" + ] + ] + }, + { + "id": "3f50e700.ebbfb8", + "type": "switchNode", + "name": "switch cr length", + "xml": "<switch test='`$mdsal-ar.connection-attachment-allotted-resource_length`'>\n", + "comments": "", + "outputs": 1, + "x": 2261.668430328369, + "y": 177.6352834701538, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "22fe4487.ea79bc", + "d76066f5.ec2ac8" + ] + ] + }, + { + "id": "1ecae18f.8c5d6e", + "type": "set", + "name": "set parent-service-instance-id", + "xml": "<set>\n<parameter name='prop.parent-service-instance-id' value='`$mdsal-ar.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.allotted-resource-information.parent-service-instance-id`' />\n\n", + "comments": "", + "x": 2817.0020294189453, + "y": 174.63526439666748, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "eb3089e9.bab518", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic='true'>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2571.4778213500977, + "y": 173.80180072784424, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1ecae18f.8c5d6e", + "c22c6bf7.654618" + ] + ] + }, + { + "id": "6807513b.840e7", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"Error: Connection attachement resource not found\" />\n \n", + "comments": "", + "x": 2253.001438140869, + "y": 223.63520526885986, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "bc09ac7e.2dfa1", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 2040.303554534912, + "y": 495.7709312438965, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "4a6d5f3.c343ea" + ] + ] + }, + { + "id": "f0b156c6.5db3a8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2032.1553573608398, + "y": 530.8370161056519, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "22ca566e.18afda" + ] + ] + }, + { + "id": "22ca566e.18afda", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"Error: SOTN resource not found\" />\n \n", + "comments": "", + "x": 2178.304130554199, + "y": 531.1045122146606, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "4a6d5f3.c343ea", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2160.3038024902344, + "y": 495.771014213562, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "c9fcea4f.295c68", + "type": "for", + "name": "for pnidx.. mdsal-psd.networks.network_length[]", + "xml": "<for index='pnidx' start='0' end='`$mdsal-psd.service-data.networks.network_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1723.6683502197266, + "y": 595.3028893470764, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "d063fbaf.bf9cb8" + ] + ] + }, + { + "id": "4b3c3b19.b12c44", + "type": "switchNode", + "name": "switch ActivateSDWANConnectivityInstance", + "xml": "<switch test=\"`$mdsal-psd.service-data.networks.network[$pnidx].network-data.request-information.request-action == 'ActivateSDWANConnectivityInstance'`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 2253.3349838256836, + "y": 564.3028907775879, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "353c03be.8a3dec" + ] + ] + }, + { + "id": "353c03be.8a3dec", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2505.334518432617, + "y": 565.3028283119202, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "8948df3b.5b4e8" + ] + ] + }, + { + "id": "8948df3b.5b4e8", + "type": "set", + "name": "set tmp.pnidx ", + "xml": "<set>\n<parameter name='tmp.pnidx' value='`$pnidx`' />\n\n", + "comments": "", + "x": 2661.3342056274414, + "y": 565.3028283119202, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "f17464be.205b38", + "type": "for", + "name": "for loop paramidx - Get topology from servicedata", + "xml": "<for index=\"paramidx\" start=\"0\" end=\"`$mdsal-psd.service-data.networks.network[$tmp.pnidx].network-data.network-request-input.network-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 1655.3351593017578, + "y": 680.3025188446045, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "a24202ba.c8c7c" + ] + ] + }, + { + "id": "1134832c.af388d", + "type": "switchNode", + "name": "switch topology", + "xml": "<switch test=\"`$mdsal-psd.service-data.networks.network[$tmp.pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].name == 'topology'`\">\n", + "comments": "", + "outputs": 1, + "x": 2107.335250854492, + "y": 659.3024244308472, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "b4638122.81f25" + ] + ] + }, + { + "id": "b4638122.81f25", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2258.335262298584, + "y": 657.3024663925171, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "6ab1ecb6.c4b6a4" + ] + ] + }, + { + "id": "6ab1ecb6.c4b6a4", + "type": "set", + "name": "set topology", + "xml": "<set>\n<parameter name='prop.topology' value='`$mdsal-psd.service-data.networks.network[$tmp.pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].value`' />\n", + "comments": "", + "x": 2399.334991455078, + "y": 656.9024000167847, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "427fd71a.a641b8", + "type": "switchNode", + "name": "switch tmp.pnidx ", + "xml": "<switch test=\"`$tmp.pnidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1626.334976196289, + "y": 639.9690914154053, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "3b308668.883fda" + ] + ] + }, + { + "id": "3b308668.883fda", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1781.7636489868164, + "y": 638.5404710769653, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1025ab31.d734f5" + ] + ] + }, + { + "id": "1025ab31.d734f5", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1922.1922721862793, + "y": 639.6835603713989, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "3aec24fb.014f5c", + "type": "switchNode", + "name": "switch topology hub-spoke", + "xml": "<switch test=\"`$prop.topology == 'hub-spoke'`\">\n", + "comments": "", + "outputs": 1, + "x": 1534.3348426818848, + "y": 742.3023405075073, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "11a1e34f.7c4fdd", + "32341b46.a26b84" + ] + ] + }, + { + "id": "11a1e34f.7c4fdd", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1724.334529876709, + "y": 767.3028259277344, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "26c0cc7e.899014" + ] + ] + }, + { + "id": "32341b46.a26b84", + "type": "outcomeTrue", + "name": "false", + "xml": "<outcome value='false'>\n", + "comments": "", + "outputs": 1, + "x": 1718.3354568481445, + "y": 728.3024883270264, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "92373ae3.dba458" + ] + ] + }, + { + "id": "92373ae3.dba458", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1854.3354606628418, + "y": 728.3024272918701, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "26c0cc7e.899014", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1729.66748046875, + "y": 835.3020601272583, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "a5cfaff.0a25c5" + ] + ] + }, + { + "id": "a5cfaff.0a25c5", + "type": "for", + "name": "for ppidx.. mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource[]", + "xml": "<for index='ppidx' start='0' end='`$mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource_length`' >\n", + "comments": "", + "outputs": 1, + "x": 2137.000732421875, + "y": 835.6356782913208, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "528bb6e8.287b28" + ] + ] + }, + { + "id": "45c7f2c8.9bbc9c", + "type": "set", + "name": "set prop.ar.provided-allotted-resource-id", + "xml": "<set>\n<parameter name='prop.ar.provided-allotted-resource-id' value='`$mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource[$ppidx].allotted-resource-id`' />\n\n", + "comments": "", + "x": 2228.0018463134766, + "y": 913.6359763145447, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "d3076636.df66e8", + "type": "for", + "name": "for loop aridx - Get role from allotted resource", + "xml": "<for index=\"aridx\" start=\"0\" end=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2246.0025482177734, + "y": 1024.302767753601, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "94a7fcab.3f18" + ] + ] + }, + { + "id": "e9ad6cc9.abb1", + "type": "switchNode", + "name": "switch Role", + "xml": "<switch test=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$aridx].name == 'Role'`\">\n", + "comments": "", + "outputs": 1, + "x": 2655.002658843994, + "y": 1027.3028545379639, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "356c0745.261588" + ] + ] + }, + { + "id": "356c0745.261588", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2796.0029907226562, + "y": 1026.3028535842896, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "2ecc17c9.bbea08" + ] + ] + }, + { + "id": "2ecc17c9.bbea08", + "type": "set", + "name": "set prop.role", + "xml": "<set>\n<parameter name='prop.role' value='`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$aridx].value`' />\n", + "comments": "", + "x": 2937.0030250549316, + "y": 1027.9027452468872, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "7d6e3904.ff8ae8", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 2732.0020446777344, + "y": 930.969269990921, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "92d1a6eb.dd91a8" + ] + ] + }, + { + "id": "b0148b51.89ec18", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2728.8537673950195, + "y": 985.0353531837463, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "c6ccd14a.96548" + ] + ] + }, + { + "id": "59d6c0f4.defd7", + "type": "switchNode", + "name": "switch role hub", + "xml": "<switch test=\"`$prop.role == hub`\">\n", + "comments": "", + "outputs": 1, + "x": 2112.3351821899414, + "y": 1089.6358079910278, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "d2d633b9.72ffd", + "10c92564.7d8f7b" + ] + ] + }, + { + "id": "a9370615.1e0a18", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2428.3345680236816, + "y": 1065.6354112625122, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "f944f364.78c47", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 2838.3042030334473, + "y": 1161.1045179367065, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "b250bb74.e941e8" + ] + ] + }, + { + "id": "e08d96d8.e1bd48", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 2840.155773162842, + "y": 1221.170599937439, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "d9301d98.96024" + ] + ] + }, + { + "id": "d9301d98.96024", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"Error: SDWAN service-data not found\" />\n \n", + "comments": "", + "x": 2984.304546356201, + "y": 1183.4380140304565, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "b250bb74.e941e8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2968.3042221069336, + "y": 1150.1046781539917, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "31ca4096.fa657", + "type": "set", + "name": "set prop.ar-service-instance-id", + "xml": "<set>\n<parameter name='prop.ar-service-instance-id' value='`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.connection-attachment-topology.allotted-resource-identifiers.consuming-service-instance-id`' />\n", + "comments": "", + "x": 2440.3356018066406, + "y": 1149.6360107660294, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "3250db4e.aae6c4", + "type": "for", + "name": "for arvidx.. mdsal-arsd.service-data.vnfs.vnf_length[]", + "xml": "<for index='arvidx' start='0' end='`$mdsal-arsd.service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 2484.0020751953125, + "y": 1271.6358003616333, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "5be088b1.9bd9d8" + ] + ] + }, + { + "id": "5be088b1.9bd9d8", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2830.6683959960938, + "y": 1261.6357765197754, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "b0a1b0f0.1cd88", + "64161d13.320da4", + "a305e869.75b198" + ] + ] + }, + { + "id": "b0a1b0f0.1cd88", + "type": "switchNode", + "name": "switch ActivateSDWANPortInstance", + "xml": "<switch test=\"`$mdsal-arsd.service-data.vnfs.vnf[$arvidx].vnf-data.request-information.request-action == 'ActivateSDWANPortInstance'`\">\n \n\n", + "comments": "", + "outputs": 1, + "x": 3092.668504714966, + "y": 1232.6367359161377, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "f4aa7045.eb114" + ] + ] + }, + { + "id": "494b8c51.d5a454", + "type": "switchNode", + "name": "switch tmp.wanportvidx ", + "xml": "<switch test=\"`$tmp.wanportvidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 2565.668212890625, + "y": 1316.3024454116821, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "a2447b78.519d38" + ] + ] + }, + { + "id": "273881de.ee082e", + "type": "for", + "name": "for loop wportidx - Get wan port ID from servicedata", + "xml": "<for index=\"wportidx\" start=\"0\" end=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.portvidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 3747.6689834594727, + "y": 1225.6369161605835, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "b8659698.4fa9a8" + ] + ] + }, + { + "id": "a2447b78.519d38", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 2737.096935272217, + "y": 1319.8741512298584, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "f6e26890.4d8a38" + ] + ] + }, + { + "id": "f6e26890.4d8a38", + "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-topology-operation-input.vnf-request-input.vnf-id (port) not found in service-data\" />\n", + "comments": "", + "x": 2881.525650024414, + "y": 1322.0174312591553, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "f4aa7045.eb114", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3320.66819190979, + "y": 1230.636736869812, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "ab1ef1f9.e54ea" + ] + ] + }, + { + "id": "b8659698.4fa9a8", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3699.6701984405518, + "y": 1309.6374425888062, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "79f89faa.fb19f" + ] + ] + }, + { + "id": "79f89faa.fb19f", + "type": "switchNode", + "name": "switch transportNetworkName", + "xml": "<switch test=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.portvidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$wportidx].name == 'transportNetworkName'`\">\n", + "comments": "", + "outputs": 1, + "x": 3917.6711139678955, + "y": 1307.6379308700562, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "863adb79.9947c8" + ] + ] + }, + { + "id": "564bf8e9.5ea9e8", + "type": "set", + "name": "set tmp.portvidx ", + "xml": "<set>\n<parameter name='tmp.portvidx' value='`$arvidx`' />\n\n", + "comments": "", + "x": 3644.667995452881, + "y": 1183.6369037628174, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "863adb79.9947c8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 4114.671541213989, + "y": 1306.6380996704102, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "896da4ec.a5e9f8" + ] + ] + }, + { + "id": "662f75a8.5b0d6c", + "type": "set", + "name": "set prop.hub.transportNetworkName", + "xml": "<set>\n<parameter name='prop.hub.transportNetworkName' value='`$mdsal-arsd.service-data.vnfs.vnf[$tmp.portvidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$wportidx].value`' />\n", + "comments": "", + "x": 4371.6733751297, + "y": 1506.2391166687012, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "372c4b67.d587a4", + "type": "switchNode", + "name": "switch prop.hub.transportNetworkName==prop.spoke.transportNetworkName", + "xml": "<switch test=\"`$prop.hub.transportNetworkName == $prop.spoke.transportNetworkName`\">\n", + "comments": "", + "outputs": 1, + "x": 2564.00431060791, + "y": 1466.3046674728394, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "ad67f3dd.ea7da", + "f32a34f9.fa2a88" + ] + ] + }, + { + "id": "ad67f3dd.ea7da", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2910.0038414001465, + "y": 1503.3047413825989, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "6ddb13cd.d02b7c" + ] + ] + }, + { + "id": "f32a34f9.fa2a88", + "type": "outcomeTrue", + "name": "false", + "xml": "<outcome value='false'>\n", + "comments": "", + "outputs": 1, + "x": 2904.004650115967, + "y": 1440.3046016693115, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "93fee3b6.b53b4" + ] + ] + }, + { + "id": "93fee3b6.b53b4", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3034.004837036133, + "y": 1440.3047542572021, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "528bb6e8.287b28", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1879.0322265625, + "y": 944.8333101272583, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "45c7f2c8.9bbc9c", + "9540984f.e97fb8", + "b384d688.b2dd28", + "59d6c0f4.defd7", + "d3076636.df66e8" + ] + ] + }, + { + "id": "e393fec8.f9974", + "type": "switchNode", + "name": "switch vpnId", + "xml": "<switch test=\"`$mdsal-psd.service-data.networks.network[$tmp.pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].name == 'vpn-id'`\">\n", + "comments": "", + "outputs": 1, + "x": 2097.001266479492, + "y": 703.6354351043701, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "d6a90986.8eb118" + ] + ] + }, + { + "id": "d6a90986.8eb118", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2241.001277923584, + "y": 703.6354761123657, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "c1f6fc9b.d909f" + ] + ] + }, + { + "id": "c1f6fc9b.d909f", + "type": "set", + "name": "set prop.vpnId", + "xml": "<set>\n<parameter name='prop.vpnId' value='`$mdsal-psd.service-data.networks.network[$tmp.pnidx].network-data.network-request-input.network-input-parameters.param[$paramidx].value`' />\n", + "comments": "", + "x": 2399.0009994506836, + "y": 702.2354106903076, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "56fbb125.4613b", + "type": "set", + "name": "Set prop.hubTnpId", + "xml": "<set>\n<parameter name='prop.hubTnpId' value='$prop.hub.wanPortId' />\n\n", + "comments": "", + "x": 2616.3368072509766, + "y": 1739.6364259719849, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "7c9721cc.23414", + "type": "execute", + "name": "execute RestApiCallNode underlay route", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-underlay.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/routing-protocol/static/action/batch-delete'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"underlayHubResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 3437.33624458313, + "y": 2571.9708592891693, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "f29c10b7.ab96c", + "d1ca729c.637d" + ] + ] + }, + { + "id": "d1ca729c.637d", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 3704.3361530303955, + "y": 2599.970888853073, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "4079a316.d4531c" + ] + ] + }, + { + "id": "f29c10b7.ab96c", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 3702.335832595825, + "y": 2555.97087931633, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "7b4a5da7.783c64" + ] + ] + }, + { + "id": "31f4dc9.4459824", + "type": "set", + "name": "Add prop.hub.route", + "xml": "<set>\n<parameter name='prop.route.id' value='`$prop.hubRouteId`' />\n<parameter name='prop.route.vpnId' value='`$prop.vpnId`' />\n<parameter name='prop.route.siteId' value='`$prop.hub.siteId`' />\n<parameter name='prop.route.deviceId' value='`$prop.hub.deviceId`' />\n<parameter name='prop.route.providerIpAddress' value='`$prop.hub.providerIpAddress`' />\n<parameter name='prop.route.wanportId' value='`$prop.spoke.wanPortId`' />\n<parameter name='prop.route.ipAddress' value='`$prop.hub.ipAddress`' />\n\n\n", + "comments": "", + "x": 3381.6696243286133, + "y": 2528.637367248535, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "bd1192a1.70e0b", + "type": "execute", + "name": "execute RestApiCallNode underlay route", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-underlay.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/routing-protocol/static/action/batch-delete'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"underlayspokeResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 3456.6696243286133, + "y": 2670.637832403183, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1372bf53.f8d271", + "7d49f976.fe2c38" + ] + ] + }, + { + "id": "7d49f976.fe2c38", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 3708.669771194458, + "y": 2699.6381289958954, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "a38da1c5.3c2df" + ] + ] + }, + { + "id": "1372bf53.f8d271", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 3706.6694507598877, + "y": 2655.638119459152, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "ae6e8595.d05358" + ] + ] + }, + { + "id": "1618d5.6f61e72c", + "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=\"Error executing sdwan spoke route underlay rest api\" />\n", + "comments": "", + "x": 3996.6703186035156, + "y": 2649.6383113861084, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "64161d13.320da4", + "type": "switchNode", + "name": "switch ActivateSDWANDeviceInstance", + "xml": "<switch test=\"`$mdsal-arsd.service-data.vnfs.vnf[$arvidx].vnf-data.request-information.request-action == 'ActivateSDWANDeviceInstance'`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 3103.532081604004, + "y": 1265.8336944580078, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "9f32e086.83793" + ] + ] + }, + { + "id": "c2ac42b9.22b8d", + "type": "switchNode", + "name": "switch tmp.devicevidx ", + "xml": "<switch test=\"`$tmp.devicevidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 2571.5316314697266, + "y": 1358.4999265670776, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "e36692fe.8d819" + ] + ] + }, + { + "id": "e36692fe.8d819", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 2737.9600677490234, + "y": 1358.0714597702026, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "3d811052.fd24c" + ] + ] + }, + { + "id": "3d811052.fd24c", + "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-topology-operation-input.vnf-request-input.vnf-id (device) not found in service-data\" />\n", + "comments": "", + "x": 2878.388999938965, + "y": 1360.2144346237183, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "9f32e086.83793", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3331.531768798828, + "y": 1263.8336954116821, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "869ea93a.54ef48" + ] + ] + }, + { + "id": "869ea93a.54ef48", + "type": "set", + "name": "set tmp.devicevidx ", + "xml": "<set>\n<parameter name='tmp.devicevidx' value='`$arvidx`' />\n\n", + "comments": "", + "x": 3486.531452178955, + "y": 1263.8336944580078, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "a305e869.75b198", + "type": "switchNode", + "name": "switch ActivateSiteInstance", + "xml": "<switch test=\"`$mdsal-arsd.service-data.vnfs.vnf[$arvidx].vnf-data.request-information.request-action == 'ActivateSiteInstance'`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 3066.5321521759033, + "y": 1299.833758354187, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "ab60af44.1fc14" + ] + ] + }, + { + "id": "aae2a2df.f7cc", + "type": "switchNode", + "name": "switch tmp.sitevidx ", + "xml": "<switch test=\"`$tmp.sitevidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 2570.5315017700195, + "y": 1396.4998044967651, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "834ee4ef.5fe588" + ] + ] + }, + { + "id": "834ee4ef.5fe588", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 2730.959966659546, + "y": 1396.0713243484497, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "4979a718.8325b8" + ] + ] + }, + { + "id": "4979a718.8325b8", + "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-topology-operation-input.vnf-request-input.vnf-id (site) not found in service-data\" />\n", + "comments": "", + "x": 2879.388921737671, + "y": 1398.2143306732178, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "ab60af44.1fc14", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3254.531717300415, + "y": 1299.833924293518, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1aaf3b5d.3c7645" + ] + ] + }, + { + "id": "1aaf3b5d.3c7645", + "type": "set", + "name": "set tmp.sitevidx ", + "xml": "<set>\n<parameter name='tmp.sitevidx' value='`$arvidx`' />\n\n", + "comments": "", + "x": 3409.531400680542, + "y": 1299.8339233398438, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "409305d5.93be5c", + "type": "for", + "name": "for loop deviceidx - Get wan port ID from servicedata", + "xml": "<for index=\"deviceidx\" start=\"0\" end=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.devicevidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2703.5333099365234, + "y": 1781.8342418670654, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "f3da0084.2ed3d" + ] + ] + }, + { + "id": "490623bf.f5be2c", + "type": "switchNode", + "name": "switch deviceId", + "xml": "<switch test=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.devicevidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$deviceidx].name == 'deviceId'`\">\n", + "comments": "", + "outputs": 1, + "x": 3188.5345611572266, + "y": 1712.8350954055786, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "fe8795f9.d93fb8" + ] + ] + }, + { + "id": "fe8795f9.d93fb8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3339.5349349975586, + "y": 1709.8353395462036, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "9a7de836.6030f8" + ] + ] + }, + { + "id": "9a7de836.6030f8", + "type": "set", + "name": "set prop.hub.deviceId", + "xml": "<set>\n<parameter name='prop.hub.deviceId' value='`$mdsal-arsd.service-data.vnfs.vnf[$tmp.devicevidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$deviceidx].value`' />\n", + "comments": "", + "x": 3514.535182952881, + "y": 1709.4358644485474, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "e6c5f470.5c1408", + "type": "for", + "name": "for loop siteidx - Get site ID from servicedata", + "xml": "<for index=\"siteidx\" start=\"0\" end=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.sitevidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2670.0331268310547, + "y": 1843.8342113494873, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "ee5b33c3.334cb" + ] + ] + }, + { + "id": "f647b09c.a81c", + "type": "comment", + "name": "Add route src->dst, dst->src", + "info": "", + "comments": "", + "x": 3005.668716430664, + "y": 1860.6360301971436, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "2ed283b9.4ced6c", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2115.334228515625, + "y": 1221.968747138977, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "3250db4e.aae6c4", + "372c4b67.d587a4", + "8238d072.258df", + "31ca4096.fa657", + "a06e1b02.e2dcb8", + "5f595aa8.cf14c4" + ] + ] + }, + { + "id": "8238d072.258df", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2370.333984375, + "y": 1358.3021211624146, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "c2ac42b9.22b8d", + "aae2a2df.f7cc", + "494b8c51.d5a454" + ] + ] + }, + { + "id": "6ddb13cd.d02b7c", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2390.3350219726562, + "y": 1730.635643005371, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "56fbb125.4613b", + "409305d5.93be5c", + "e6c5f470.5c1408", + "74f0a419.baab7c", + "f5ec2256.55a71" + ] + ] + }, + { + "id": "53da0cfd.4e5c84", + "type": "set", + "name": "Add prop.spoke.route", + "xml": "<set>\n<parameter name='prop.route.id' value='`$prop.spokeRouteId`' />\n<parameter name='prop.route.vpnId' value='`$prop.vpnId`' />\n<parameter name='prop.route.siteId' value='`$prop.spoke.siteId`' />\n<parameter name='prop.route.deviceId' value='`$prop.spoke.deviceId`' />\n<parameter name='prop.route.providerIpAddress' value='`$prop.spoke.providerIpAddress`' />\n<parameter name='prop.route.wanportId' value='`$prop.hub.wanPortId`' />\n<parameter name='prop.route.ipAddress' value='`$prop.spoke.ipAddress`' />\n\n\n\n\n", + "comments": "", + "x": 3391.533639907837, + "y": 2639.3345935344696, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "b99b3963.4b1368", + "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": 340.3343048095703, + "y": 1096.3343391418457, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "9692ac6c.5b398", + "type": "execute", + "name": "generate connection attachment AR url ", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"`$prop.restapi.connection-attachment-allottedresource`\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url-connection\"/>\n <parameter name=\"target\" value=\"{allotted-resource-id}\"/>\n <parameter name=\"replacement\" value=\"`$prop.ar.allotted-resource-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 1389.6672058105469, + "y": 158.30183696746826, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "a88c4be0.5a96c8", + "type": "execute", + "name": "execute RestApiCallNode - get-resource connection-attachment-allotted-resource", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-connection`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-ar\" />\n\n", + "comments": "", + "outputs": 1, + "x": 1516.667236328125, + "y": 206.3018274307251, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "43ba54c6.bea31c", + "b9e47095.da1a3" + ] + ] + }, + { + "id": "fa697270.9a4c6", + "type": "execute", + "name": "execute RestApiCallNode - get parent service data", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-parent-connection`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-psd\" />\n\n", + "comments": "", + "outputs": 1, + "x": 1741.0013885498047, + "y": 540.3021411895752, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "bc09ac7e.2dfa1", + "f0b156c6.5db3a8" + ] + ] + }, + { + "id": "9c710564.f70308", + "type": "execute", + "name": "generate connection attachment parent url ", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"/restconf/config/GENERIC-RESOURCE-API:services/service/{service-instance-id}/service-data\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url-parent-connection\"/>\n <parameter name=\"target\" value=\"{service-instance-id}\"/>\n <parameter name=\"replacement\" value=\"`$prop.parent-service-instance-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 1718.0010375976562, + "y": 486.30206871032715, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "b113d667.018288", + "type": "comment", + "name": "full mesh do nothing", + "info": "", + "comments": "", + "x": 1552.667839050293, + "y": 697.3021068572998, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "9c493d3a.013fd", + "type": "comment", + "name": "hub-spoke", + "info": "", + "comments": "", + "x": 2553.6672401428223, + "y": 794.3019967079163, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "9540984f.e97fb8", + "type": "execute", + "name": "generate connection attachment AR url ", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"`$prop.restapi.connection-attachment-allottedresource`\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url-connection\"/>\n <parameter name=\"target\" value=\"{allotted-resource-id}\"/>\n <parameter name=\"replacement\" value=\"`$prop.ar.provided-allotted-resource-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 2226.0003929138184, + "y": 945.3019919395447, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "b384d688.b2dd28", + "type": "execute", + "name": "execute RestApiCallNode - get-resource connection-attachment-allotted-resource", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-connection`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-providedAr\" />\n\n", + "comments": "", + "outputs": 1, + "x": 2357.000473022461, + "y": 984.9686217308044, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "7d6e3904.ff8ae8", + "b0148b51.89ec18" + ] + ] + }, + { + "id": "a06e1b02.e2dcb8", + "type": "execute", + "name": "generate service data url", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n <parameter name=\"source\" value=\"/restconf/config/GENERIC-RESOURCE-API:services/service/{service-instance-id}/service-data\"/>\n <parameter name=\"outputPath\" value=\"tmp.ar-url-connection\"/>\n <parameter name=\"target\" value=\"{service-instance-id}\"/>\n <parameter name=\"replacement\" value=\"`$prop.ar-service-instance-id`\"/>\n", + "comments": "", + "outputs": 1, + "x": 2407.504367828369, + "y": 1186.3058919906616, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "5f595aa8.cf14c4", + "type": "execute", + "name": "execute RestApiCallNode - get service data of allotted resource", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-connection`' />\n <parameter name='restapiUser' value='`$prop.controller.user`' />\n <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n <parameter name='format' value='json' />\n <parameter name='httpMethod' value='GET' />\n <parameter name=\"responsePrefix\" value=\"mdsal-arsd\" />\n\n", + "comments": "", + "outputs": 1, + "x": 2523.5045013427734, + "y": 1223.3057832717896, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "f944f364.78c47", + "e08d96d8.e1bd48" + ] + ] + }, + { + "id": "10c92564.7d8f7b", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2287.5000648498535, + "y": 1108.8018560409546, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "2ed283b9.4ced6c" + ] + ] + }, + { + "id": "d2d633b9.72ffd", + "type": "outcomeFalse", + "name": "false", + "xml": "<outcome value='false'>\n", + "comments": "", + "outputs": 1, + "x": 2293.500312805176, + "y": 1065.801947593689, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "a9370615.1e0a18" + ] + ] + }, + { + "id": "c22c6bf7.654618", + "type": "for", + "name": "for loop roleidx - Get role from allotted resource", + "xml": "<for index=\"roleidx\" start=\"0\" end=\"`$mdsal-ar.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2868.5008697509766, + "y": 213.30177307128906, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1e62939f.a940cc" + ] + ] + }, + { + "id": "1e62939f.a940cc", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3127.5011825561523, + "y": 212.3020887374878, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "6368cbef.0c0714" + ] + ] + }, + { + "id": "6368cbef.0c0714", + "type": "switchNode", + "name": "switch Role", + "xml": "<switch test=\"`$mdsal-ar.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$roleidx].name == 'role'`\">\n", + "comments": "", + "outputs": 1, + "x": 3276.501194000244, + "y": 213.3019256591797, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "602b9a1d.1f8fa4" + ] + ] + }, + { + "id": "9865389f.19f678", + "type": "set", + "name": "set prop.spoke.role", + "xml": "<set>\n<parameter name='prop.spoke.role' value='`$mdsal-ar.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.param[$roleidx].value`' />\n", + "comments": "", + "x": 3581.501754760742, + "y": 210.90183353424072, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "602b9a1d.1f8fa4", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3412.00101852417, + "y": 210.30176544189453, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "9865389f.19f678" + ] + ] + }, + { + "id": "c78c1bff.286648", + "type": "switchNode", + "name": "switch spoke", + "xml": "<switch test=\"`$prop.spoke.role == 'spoke'`\">\n", + "comments": "", + "outputs": 1, + "x": 1304.000373840332, + "y": 357.301700592041, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "45674b4e.4d0684" + ] + ] + }, + { + "id": "45674b4e.4d0684", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1445.000129699707, + "y": 358.30173778533936, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "44bfeb73.8a2794" + ] + ] + }, + { + "id": "c6974a98.f8b038", + "type": "for", + "name": "for i.. service-data.vnfs.vnf_length[]", + "xml": "<for index='i' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1717.5006561279297, + "y": 412.3017330169678, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "74ae021f.4e878c" + ] + ] + }, + { + "id": "74ae021f.4e878c", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2051.166847229004, + "y": 356.3016633987427, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "e5568bc9.6c4a18", + "10bef5c5.4c95ea", + "d2557f72.d615e" + ] + ] + }, + { + "id": "e5568bc9.6c4a18", + "type": "switchNode", + "name": "switch ActivateSDWANPortInstance", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$i].vnf-data.request-information.request-action == 'ActivateSDWANPortInstance'`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 2322.1668853759766, + "y": 302.3025498390198, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "730af204.11fefc" + ] + ] + }, + { + "id": "730af204.11fefc", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2535.166648864746, + "y": 303.3025527000427, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "90e7c80d.95a148" + ] + ] + }, + { + "id": "90e7c80d.95a148", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2684.0003929138184, + "y": 305.3017420768738, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "993b2158.a7204" + ] + ] + }, + { + "id": "993b2158.a7204", + "type": "for", + "name": "for loop widx - Get wan port ID from servicedata", + "xml": "<for index=\"widx\" start=\"0\" end=\"`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2957.000343322754, + "y": 303.6689600944519, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "a8fb6ac2.404148" + ] + ] + }, + { + "id": "a8fb6ac2.404148", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3226.0012702941895, + "y": 302.66920614242554, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "f56203d5.44648", + "844331fb.21709", + "c8a276bd.330448", + "878dc9b3.754498" + ] + ] + }, + { + "id": "f56203d5.44648", + "type": "switchNode", + "name": "switch transportNetworkName", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$widx].name == 'transportNetworkName'`\">\n", + "comments": "", + "outputs": 1, + "x": 3469.0023040771484, + "y": 257.6697793006897, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "c1622f74.5acec" + ] + ] + }, + { + "id": "c1622f74.5acec", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3669.0020790100098, + "y": 257.6699414253235, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "484c0f29.65918" + ] + ] + }, + { + "id": "484c0f29.65918", + "type": "set", + "name": "set prop.spoke.transportNetworkName", + "xml": "<set>\n<parameter name='prop.spoke.transportNetworkName' value='`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$widx].value`' />\n", + "comments": "", + "x": 3896.002815246582, + "y": 259.2705235481262, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "44bfeb73.8a2794", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1197.9694213867188, + "y": 668.2706489562988, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "c6974a98.f8b038", + "9c710564.f70308", + "fa697270.9a4c6", + "c9fcea4f.295c68", + "f17464be.205b38", + "3aec24fb.014f5c", + "427fd71a.a641b8", + "3da7a5e7.865d8a" + ] + ] + }, + { + "id": "10bef5c5.4c95ea", + "type": "switchNode", + "name": "switch ActivateSDWANDeviceInstance", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$i].vnf-data.request-information.request-action == 'ActivateSDWANDeviceInstance'`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 2314.5003204345703, + "y": 376.3017544746399, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "3b1b3b34.55a514" + ] + ] + }, + { + "id": "3b1b3b34.55a514", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2533.5000705718994, + "y": 377.30173921585083, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "371f6a10.c50d56" + ] + ] + }, + { + "id": "371f6a10.c50d56", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2684.3340606689453, + "y": 383.3009305000305, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "53996c8e.9b7f34" + ] + ] + }, + { + "id": "53996c8e.9b7f34", + "type": "for", + "name": "for loop didx - Get device ID from servicedata", + "xml": "<for index=\"didx\" start=\"0\" end=\"`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2943.334312438965, + "y": 385.66822576522827, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "f263db9e.f44158" + ] + ] + }, + { + "id": "f263db9e.f44158", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3229.334819793701, + "y": 418.66841077804565, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "5249df60.eaa65" + ] + ] + }, + { + "id": "5249df60.eaa65", + "type": "switchNode", + "name": "switch deviceId", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$didx].name == 'deviceId'`\">\n", + "comments": "", + "outputs": 1, + "x": 3412.3357315063477, + "y": 418.66902112960815, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "78ddeb0.2bf8314" + ] + ] + }, + { + "id": "78ddeb0.2bf8314", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3612.335506439209, + "y": 418.66918325424194, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "842e3e5c.4cad" + ] + ] + }, + { + "id": "842e3e5c.4cad", + "type": "set", + "name": "set prop.spoke.deviceId", + "xml": "<set>\n<parameter name='prop.spoke.deviceId' value='`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$didx].value`' />\n", + "comments": "", + "x": 3807.3361892700195, + "y": 415.26976442337036, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "d2557f72.d615e", + "type": "switchNode", + "name": "switch ActivateSiteInstance", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$i].vnf-data.request-information.request-action == 'ActivateSiteInstance'`\">\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 2293.5004348754883, + "y": 437.30178594589233, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1c713318.89265d" + ] + ] + }, + { + "id": "1c713318.89265d", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2527.500072479248, + "y": 438.3017258644104, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "ed702e21.07c0b" + ] + ] + }, + { + "id": "ed702e21.07c0b", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2679.3340606689453, + "y": 460.30096197128296, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "8ec1a47c.55b508", + "68bdc58a.c36e2c" + ] + ] + }, + { + "id": "8ec1a47c.55b508", + "type": "for", + "name": "for loop widx - Get wan site ID from servicedata", + "xml": "<for index=\"sidx\" start=\"0\" end=\"`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2960.3338928222656, + "y": 459.668164730072, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "edd6a6a1.36e3f8" + ] + ] + }, + { + "id": "edd6a6a1.36e3f8", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3229.334819793701, + "y": 458.66841077804565, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "12472c4.5235bd4", + "96a23bd5.060968", + "af471c20.d9cb7" + ] + ] + }, + { + "id": "12472c4.5235bd4", + "type": "switchNode", + "name": "switch siteId", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$sidx].name == 'siteId'`\">\n", + "comments": "", + "outputs": 1, + "x": 3418.33602142334, + "y": 508.66908264160156, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "3940a3b0.f06d3c" + ] + ] + }, + { + "id": "3940a3b0.f06d3c", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3618.3354988098145, + "y": 496.66919708251953, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "bc674b05.78b928" + ] + ] + }, + { + "id": "bc674b05.78b928", + "type": "set", + "name": "set prop.spoke.siteId", + "xml": "<set>\n<parameter name='prop.spoke.siteId' value='`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$sidx].value`' />\n", + "comments": "", + "x": 3811.336452484131, + "y": 503.26982736587524, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "844331fb.21709", + "type": "switchNode", + "name": "switch wanPortId", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$widx].name == 'wanPortId'`\">\n", + "comments": "", + "outputs": 1, + "x": 3442.5, + "y": 294.3018355369568, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "6b71a698.d33fe8" + ] + ] + }, + { + "id": "6b71a698.d33fe8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3672.5000038146973, + "y": 294.3019471168518, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "92bbf4e4.47a9a8" + ] + ] + }, + { + "id": "92bbf4e4.47a9a8", + "type": "set", + "name": "set prop.spoke.wanPortId", + "xml": "<set>\n<parameter name='prop.spoke.wanPortId' value='`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$widx].value`' />\n", + "comments": "", + "x": 3899.5007400512695, + "y": 295.90252923965454, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "c8a276bd.330448", + "type": "switchNode", + "name": "switch providerIpAddress", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$widx].name == 'providerIpAddress'`\">\n", + "comments": "", + "outputs": 1, + "x": 3460.500160217285, + "y": 338.30178594589233, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "adb74c6c.ec9a" + ] + ] + }, + { + "id": "adb74c6c.ec9a", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3660.4999351501465, + "y": 338.3019480705261, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1ca4e423.ffe23c" + ] + ] + }, + { + "id": "1ca4e423.ffe23c", + "type": "set", + "name": "set prop.spoke.providerIpAddress", + "xml": "<set>\n<parameter name='prop.spoke.providerIpAddress' value='`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$widx].value`' />\n", + "comments": "", + "x": 3887.5006713867188, + "y": 339.90253019332886, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "878dc9b3.754498", + "type": "switchNode", + "name": "switch ipAddress", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$widx].name == 'ipAddress'`\">\n", + "comments": "", + "outputs": 1, + "x": 3440.499988555908, + "y": 377.30182218551636, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "728cf41e.771a8c" + ] + ] + }, + { + "id": "728cf41e.771a8c", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3664.4998168945312, + "y": 377.3019394874573, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "dd2dd25f.6f587" + ] + ] + }, + { + "id": "dd2dd25f.6f587", + "type": "set", + "name": "set prop.spoke.ipAddress", + "xml": "<set>\n<parameter name='prop.spoke.ipAddress' value='`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$widx].value`' />\n", + "comments": "", + "x": 3891.5005531311035, + "y": 378.90252161026, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "ad0a3663.ab8598", + "type": "block", + "name": "block: atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1007.9999008178711, + "y": 236.50004196166992, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "2acab811.c13ee8", + "9692ac6c.5b398", + "a88c4be0.5a96c8", + "c78c1bff.286648" + ] + ] + }, + { + "id": "688f910f.1fade", + "type": "comment", + "name": "get spoke device,site,wanport info", + "info": "", + "comments": "", + "x": 1764.96875, + "y": 359.96874713897705, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "74cacf6d.c151", + "type": "comment", + "name": "Add routes only on activation of spoke Attach site", + "info": "", + "comments": "", + "x": 1425.4999160766602, + "y": 303.00006103515625, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "3d6571cf.a0a37e", + "type": "comment", + "name": "Loop for all the hub allotted resources, get respective service data and get vnfs info", + "info": "", + "comments": "", + "x": 2181.5, + "y": 798.500057220459, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "ee5b33c3.334cb", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2945.4998321533203, + "y": 1819.000135421753, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "c17add8f.67a28", + "229bba7c.508e96" + ] + ] + }, + { + "id": "f3da0084.2ed3d", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3012.4998321533203, + "y": 1715.0000114440918, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "490623bf.f5be2c" + ] + ] + }, + { + "id": "c17add8f.67a28", + "type": "switchNode", + "name": "switch siteId", + "xml": "<switch test=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.sitevidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$siteidx].name == 'siteId'`\">\n", + "comments": "", + "outputs": 1, + "x": 3122.499641418457, + "y": 1790.9998016357422, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "dbd1bbe9.db4a58" + ] + ] + }, + { + "id": "dbd1bbe9.db4a58", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3273.500011444092, + "y": 1789.999984741211, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "5c117986.38cf28" + ] + ] + }, + { + "id": "5c117986.38cf28", + "type": "set", + "name": "set prop.hub.siteId", + "xml": "<set>\n<parameter name='prop.hub.siteId' value='`$mdsal-arsd.service-data.vnfs.vnf[$tmp.sitevidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$siteidx].value`' />\n", + "comments": "", + "x": 3445.5000190734863, + "y": 1787.6005535125732, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "74f0a419.baab7c", + "type": "switchNode", + "name": "switch request-action", + "xml": "<switch test='`$connection-attachment-topology-operation-input.request-information.request-action`'>\n", + "comments": "", + "outputs": 1, + "x": 2598.9997482299805, + "y": 2143.0004453659058, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "8a79d931.696778", + "c7717ba5.717ea8" + ] + ] + }, + { + "id": "8a79d931.696778", + "type": "outcome", + "name": "ActivateSDWANAttachmentInstance", + "xml": "<outcome value='ActivateSDWANAttachmentInstance'>", + "comments": "", + "outputs": 1, + "x": 2869.0271530151367, + "y": 1954.0314779281616, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "c591ad14.b9dd7" + ] + ] + }, + { + "id": "a7156e9f.23a1b", + "type": "execute", + "name": "execute RestApiCallNode underlay route", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-underlay.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/routing-protocol/static'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"underlayHubResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 3457.500099182129, + "y": 1883.0003824234009, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "3761bb2b.afc314", + "4ebe8079.3f11c" + ] + ] + }, + { + "id": "4ebe8079.3f11c", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 3704.499927520752, + "y": 1862.0002145767212, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "78300110.b43b4" + ] + ] + }, + { + "id": "3761bb2b.afc314", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 3702.4996070861816, + "y": 1818.000205039978, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "722e84e9.8ab54c" + ] + ] + }, + { + "id": "e4f1543b.8ca618", + "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=\"Error executing sdwan hub route underlay rest api\" />\n", + "comments": "", + "x": 3980.500762939453, + "y": 1796.0005054473877, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "54f01fb1.eab0c", + "type": "set", + "name": "Add prop.hub.route", + "xml": "<set>\n<parameter name='prop.route.vpnId' value='`$prop.vpnId`' />\n<parameter name='prop.route.siteId' value='`$prop.hub.siteId`' />\n<parameter name='prop.route.deviceId' value='`$prop.hub.deviceId`' />\n<parameter name='prop.route.providerIpAddress' value='`$prop.hub.providerIpAddress`' />\n<parameter name='prop.route.wanportId' value='`$prop.spoke.wanPortId`' />\n<parameter name='prop.route.ipAddress' value='`$prop.hub.ipAddress`' />\n\n\n", + "comments": "", + "x": 3392.8337020874023, + "y": 1853.666922569275, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "b0e30676.c2a618", + "type": "execute", + "name": "execute RestApiCallNode underlay route", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-underlay.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/routing-protocol/static'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"underlayspokeResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 3474.834144592285, + "y": 2088.6675004959106, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "ad299c2d.b630e", + "51decbd4.61a7c4" + ] + ] + }, + { + "id": "51decbd4.61a7c4", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 3726.83424949646, + "y": 2076.667459964752, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "b3f4e792.e33638" + ] + ] + }, + { + "id": "ad299c2d.b630e", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 3724.8339290618896, + "y": 2032.667450428009, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "e6f4e702.6d5b68" + ] + ] + }, + { + "id": "c9cf02e0.97d29", + "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=\"Error executing sdwan spoke route underlay rest api\" />\n", + "comments": "", + "x": 3879.8350524902344, + "y": 1982.6677513122559, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "2726f205.443f6e", + "type": "set", + "name": "Add prop.spoke.route", + "xml": "<set>\n<parameter name='prop.route.vpnId' value='`$prop.vpnId`' />\n<parameter name='prop.route.siteId' value='`$prop.spoke.siteId`' />\n<parameter name='prop.route.deviceId' value='`$prop.spoke.deviceId`' />\n<parameter name='prop.route.providerIpAddress' value='`$prop.spoke.providerIpAddress`' />\n<parameter name='prop.route.wanportId' value='`$prop.hub.wanPortId`' /> \n<parameter name='prop.route.ipAddress' value='`$prop.spoke.ipAddress`' />\n\n\n", + "comments": "", + "x": 3415.6980171203613, + "y": 2051.3642127513885, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "72173b95.fc02b4", + "type": "set", + "name": "set prop.underlay.routeIds", + "xml": "<set>\n<parameter name='prop.underlay.routeIds[$prop.underlay.routeIds_length].hubSiteId' value='`$prop.hub.siteId`' />\n<!--parameter name='prop.underlay.routeIds[$prop.underlay.routeIds_length].spokeSiteId' value='`$prop.spoke.siteId`' /-->\n<parameter name='prop.underlay.routeIds[$prop.underlay.routeIds_length].hubRouteId' value='`$underlayHubResp.success[0].id`' />\n<parameter name='prop.underlay.routeIds[$prop.underlay.routeIds_length].spokeRouteId' value='`$underlayspokeResp.success[0].id`' />\n\n\n\n", + "comments": "", + "x": 3425.665542602539, + "y": 2211.0309886932373, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "c591ad14.b9dd7", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3104.999671936035, + "y": 1951.4999113082886, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "54f01fb1.eab0c", + "2726f205.443f6e", + "72173b95.fc02b4", + "b0e30676.c2a618", + "a7156e9f.23a1b", + "541b6902.dd6b58", + "77b69608.7345f8", + "75459c33.78c964", + "d5a685ee.a4f698", + "f073f95f.7848a8" + ] + ] + }, + { + "id": "58ea94fe.88fe4c", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3136.9997749328613, + "y": 2593.5002613067627, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "31f4dc9.4459824", + "53da0cfd.4e5c84", + "7c9721cc.23414", + "bd1192a1.70e0b", + "de488f87.4a5ee", + "cc49685f.b2d5d8", + "7b57d512.398e6c" + ] + ] + }, + { + "id": "c7717ba5.717ea8", + "type": "outcome", + "name": "DeactivateSDWANAttachmentInstance", + "xml": "<outcome value='DeactivateSDWANAttachmentInstance'>", + "comments": "", + "outputs": 1, + "x": 2885.4998321533203, + "y": 2587.500072479248, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "58ea94fe.88fe4c" + ] + ] + }, + { + "id": "77b69608.7345f8", + "type": "set", + "name": "Add sites to list and update length", + "xml": "<set>\n<parameter name='prop.provision.siteIds[$prop.provision.siteIds_length].hubSiteName' value='`$prop.hub.siteName`' />\n<parameter name='prop.provision.siteIds[$prop.provision.siteIds_length].hubSiteId' value='`$prop.hub.siteId`' />\n<parameter name='prop.provision.siteIds[$prop.provision.siteIds_length].spokeSiteName' value='`$prop.spoke.siteName`' />\n<parameter name='prop.provision.siteIds[$prop.provision.siteIds_length].spokeSiteId' value='`$prop.spoke.siteId`' />\n\n\n\n\n\n\n\n\n\n\n\n\n\n", + "comments": "", + "x": 3430.0318298339844, + "y": 2336.0318689346313, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "fd537752.3855d8", + "type": "comment", + "name": "save hubsiteIds and spoke siteIds for provision", + "info": "", + "comments": "", + "x": 3462.0322036743164, + "y": 2292.0317430496216, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "96a23bd5.060968", + "type": "switchNode", + "name": "switch name", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$sidx].name == 'name'`\">\n", + "comments": "", + "outputs": 1, + "x": 3419.031005859375, + "y": 458.03125, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "7dad2dd.add95d4" + ] + ] + }, + { + "id": "7dad2dd.add95d4", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3619.0307807922363, + "y": 458.0314121246338, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "deeabd26.1be7b" + ] + ] + }, + { + "id": "deeabd26.1be7b", + "type": "set", + "name": "set prop.spoke.siteName", + "xml": "<set>\n<parameter name='prop.spoke.siteName' value='`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$sidx].value`' />\n", + "comments": "", + "x": 3807.0315856933594, + "y": 456.63202571868896, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "229bba7c.508e96", + "type": "switchNode", + "name": "switch name", + "xml": "<switch test=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.sitevidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$siteidx].name == 'name'`\">\n", + "comments": "", + "outputs": 1, + "x": 3121.0310287475586, + "y": 1757.5311088562012, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "980f0d4f.cfeac" + ] + ] + }, + { + "id": "980f0d4f.cfeac", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3272.0313987731934, + "y": 1756.53129196167, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "bc242aa.e7cd1d8" + ] + ] + }, + { + "id": "bc242aa.e7cd1d8", + "type": "set", + "name": "set prop.hub.siteName", + "xml": "<set>\n<parameter name='prop.hub.siteName' value='`$mdsal-arsd.service-data.vnfs.vnf[$tmp.sitevidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$siteidx].value`' />\n", + "comments": "", + "x": 3444.031406402588, + "y": 1754.1318607330322, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "962ad5c3.0da1a8", + "type": "set", + "name": "set prop.provision.siteIds_length=0", + "xml": "<set>\n<parameter name='prop.provision.siteIds_length' value='0' />\n\n\n\n", + "comments": "", + "x": 444.03126525878906, + "y": 344.0312547683716, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "ba15291d.217778", + "type": "execute", + "name": "execute RestApiCallNode site provision urls", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-site-provision.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/sites/provision-urls'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"provisionUrlRsp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 796.0312957763672, + "y": 776.0314712524414, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "863c45b0.87f298", + "e8831f50.130f7" + ] + ] + }, + { + "id": "e8831f50.130f7", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1060.0315551757812, + "y": 798.0315160751343, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "863c45b0.87f298", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1061.0313415527344, + "y": 755.0314540863037, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "f11e1d9d.f9f63" + ] + ] + }, + { + "id": "f11e1d9d.f9f63", + "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=\"Error executing provision url rest api\" />\n", + "comments": "", + "x": 1206.0318641662598, + "y": 753.0314922332764, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "da982ae7.c19088", + "type": "for", + "name": "for providx..prop.provision.siteIds[]", + "xml": "<for index='providx' start='0' end='`$prop.provision.siteIds_length`' >\n", + "comments": "", + "outputs": 1, + "x": 437.0312957763672, + "y": 548.0312948226929, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "2d873e7f.4b1bc2" + ] + ] + }, + { + "id": "2d873e7f.4b1bc2", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 461.0313377380371, + "y": 758.031268119812, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "50fee5f7.6d296c", + "ba15291d.217778", + "89a54eb6.e2142" + ] + ] + }, + { + "id": "50fee5f7.6d296c", + "type": "set", + "name": "set prop.spoke.hubSiteId, spokeSiteId", + "xml": "<set>\n<parameter name='prop.provision.hubSitename' value='`$prop.provision.siteIds[$providx].hubSiteName`' />\n<parameter name='prop.provision.spokeSitename' value='`$prop.provision.siteIds[$providx].spokeSiteName`' />\n<parameter name='prop.provision.hubspokesite[0]' value='`$prop.provision.siteIds[$providx].hubSiteId`' />\n<parameter name='prop.provision.hubspokesite[1]' value='`$prop.provision.siteIds[$providx].spokeSiteId`' />\n<parameter name='prop.provision.hubspokesite_length' value='2' />\n", + "comments": "", + "x": 772.0339965820312, + "y": 634.6329832077026, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "89a54eb6.e2142", + "type": "record", + "name": "record provision url response to the file", + "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"`'/opt/opendaylight/current/data/log/' + 'HUB-' + $prop.provision.hubSitename + '-SPOKE-' + $prop.provision.spokeSitename + '-provisionUrl'`\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value='`$provisionUrlRsp.success[0].url`'/>\n\n", + "comments": "", + "outputs": 1, + "x": 768.0313720703125, + "y": 870.0313358306885, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "94a7fcab.3f18", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2510.031482696533, + "y": 1025.0313262939453, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "e9ad6cc9.abb1" + ] + ] + }, + { + "id": "d063fbaf.bf9cb8", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1990.0311584472656, + "y": 588.0313091278076, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "4b3c3b19.b12c44" + ] + ] + }, + { + "id": "a24202ba.c8c7c", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1934.0313262939453, + "y": 679.0312175750732, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1134832c.af388d", + "e393fec8.f9974" + ] + ] + }, + { + "id": "541b6902.dd6b58", + "type": "set", + "name": "set prop.underlay.routeIds_length++", + "xml": "<set>\n<parameter name='prop.underlay.routeIds_length' value='`$prop.underlay.routeIds_length + 1`' />\n\n\n\n\n", + "comments": "", + "x": 3455.0011596679688, + "y": 2247.250065803528, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "75459c33.78c964", + "type": "set", + "name": "Update prop.provision.siteIds_length", + "xml": "<set>\n<parameter name='prop.provision.siteIds_length' value='`$prop.provision.siteIds_length + 1`' />\n\n\n\n\n\n\n\n\n\n\n\n\n", + "comments": "", + "x": 3438.5009002685547, + "y": 2371.2501611709595, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "68bdc58a.c36e2c", + "type": "set", + "name": "set prop.spoke.siteidx", + "xml": "<set>\n<parameter name='prop.spoke.siteidx' value='`$i`' />\n\n", + "comments": "", + "x": 2878.7501907348633, + "y": 424.0000286102295, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "8706bf22.e777d", + "type": "set", + "name": "set underlay route ids to service data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$prop.spoke.siteidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$prop.spoke.siteidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].name' value=\"underlayRouteIds\" />\n<parameter name='service-data.vnfs.vnf[$prop.spoke.siteidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$prop.spoke.siteidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].value' value='`$tmp.routeString`' />\n\n\n", + "comments": "", + "x": 1901.0006408691406, + "y": 1911.0003986358643, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "546d6174.f994f", + "type": "set", + "name": "set prop.underlay.routeIds_length=0", + "xml": "<set>\n<parameter name='prop.underlay.routeIds_length' value='0' />\n\n\n\n", + "comments": "", + "x": 448.9961242675781, + "y": 295.9961128234863, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "de488f87.4a5ee", + "type": "for", + "name": "for loop uidx - Get route Id from prop.underlay.routeIds", + "xml": "<for index=\"uidx\" start=\"0\" end=\"`$prop.underlay.routeIds_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 3492.6630325317383, + "y": 2466.3295001983643, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "b94dca1b.799658" + ] + ] + }, + { + "id": "b94dca1b.799658", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3784.3297271728516, + "y": 2466.3295001983643, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "f30a5bcf.2eba98" + ] + ] + }, + { + "id": "f30a5bcf.2eba98", + "type": "switchNode", + "name": "switch prop.hub.siteId", + "xml": "<switch test=\"`$prop.underlay.routeIds[$uidx].hubSiteId == $prop.hub.siteId`\">\n", + "comments": "", + "outputs": 1, + "x": 3973.3297424316406, + "y": 2466.3296632766724, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "9e731b50.667688" + ] + ] + }, + { + "id": "9e731b50.667688", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 4144.329177856445, + "y": 2466.329662322998, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "34e4e4e1.bf23ec" + ] + ] + }, + { + "id": "34e4e4e1.bf23ec", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 4298.329177856445, + "y": 2470.3296699523926, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "7f01b9d0.ef7bc8" + ] + ] + }, + { + "id": "7f01b9d0.ef7bc8", + "type": "set", + "name": "set prop.hubRouteId prop.spokeRouteId", + "xml": "<set>\n<parameter name='prop.hubRouteId' value='`$prop.underlay.routeIds[$uidx].hubRouteId`' />\n<parameter name='prop.spokeRouteId' value='`$prop.underlay.routeIds[$uidx].spokeRouteId`' />\n", + "comments": "", + "x": 4384.32918548584, + "y": 2542.32967376709, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "af471c20.d9cb7", + "type": "switchNode", + "name": "switch underlayRouteIds", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$sidx].name == 'underlayRouteIds'`\">\n", + "comments": "", + "outputs": 1, + "x": 3423.99609375, + "y": 562.6627197265625, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "3c3b3752.f46c08" + ] + ] + }, + { + "id": "3c3b3752.f46c08", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3623.9955711364746, + "y": 550.6628341674805, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "981ac32e.958e4" + ] + ] + }, + { + "id": "a4a704fd.090458", + "type": "set", + "name": "set prop.underlay.routeIds", + "xml": "<set>\n<parameter name='prop.underlay.routeIdsString' value='`$service-data.vnfs.vnf[$i].vnf-data.vnf-request-input.vnf-input-parameters.param[$sidx].value`' />\n", + "comments": "", + "x": 3994.996971130371, + "y": 550.2635440826416, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "3da7a5e7.865d8a", + "type": "switchNode", + "name": "switch request-action", + "xml": "<switch test='`$connection-attachment-topology-operation-input.request-information.request-action`'>\n", + "comments": "", + "outputs": 1, + "x": 1110.9963836669922, + "y": 2002.329628944397, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1f1cb6fc.4dc6b9", + "a206c36a.2d39f" + ] + ] + }, + { + "id": "1f1cb6fc.4dc6b9", + "type": "outcome", + "name": "ActivateSDWANAttachmentInstance", + "xml": "<outcome value='ActivateSDWANAttachmentInstance'>", + "comments": "", + "outputs": 1, + "x": 1374.9964294433594, + "y": 1957.329626083374, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "3f4012bd.4d4d2e" + ] + ] + }, + { + "id": "3f4012bd.4d4d2e", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1616.9689407348633, + "y": 1953.7983770370483, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "8706bf22.e777d", + "cb472a7b.dc7d38", + "879af91.a400b08", + "93dcb194.e6988" + ] + ] + }, + { + "id": "1834840f.e68edc", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1620.9689292907715, + "y": 2037.7985458374023, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "92497dd5.46538" + ] + ] + }, + { + "id": "a206c36a.2d39f", + "type": "outcome", + "name": "DeactivateSDWANAttachmentInstance", + "xml": "<outcome value='DeactivateSDWANAttachmentInstance'>", + "comments": "", + "outputs": 1, + "x": 1372.4690704345703, + "y": 2039.7983827590942, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1834840f.e68edc" + ] + ] + }, + { + "id": "92497dd5.46538", + "type": "set", + "name": "set input parameter length -1", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$prop.spoke.siteidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length' value='`$service-data.vnfs.vnf[$prop.spoke.siteidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length - 1`' />\n\n\n\n\n", + "comments": "", + "x": 1849.6626281738281, + "y": 2036.32963180542, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "9af7165e.2d5758", + "type": "comment", + "name": "Get route routes IDs", + "info": "", + "comments": "", + "x": 3392.3294982910156, + "y": 2427.6627368927, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "cb472a7b.dc7d38", + "type": "set", + "name": "set underlay route ids to service data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$prop.spoke.siteidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length' value='`$service-data.vnfs.vnf[$prop.spoke.siteidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1`' />\n\n\n\n\n", + "comments": "", + "x": 1890.329574584961, + "y": 1985.662672996521, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "879af91.a400b08", + "type": "for", + "name": "for jidx paramidx - Get topology from servicedata", + "xml": "<for index=\"jidx\" start=\"0\" end=\"`$prop.underlay.routeIds_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 1979.3294982910156, + "y": 1532.329444885254, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "cdfd8790.f983d8" + ] + ] + }, + { + "id": "3e5fe1f4.4771be", + "type": "execute", + "name": "execute concat", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='concat' >\n <parameter name=\"source\" value='`$tmp.concat`'/>\n <parameter name=\"outputPath\" value=\"tmp.concat1\"/>\n <parameter name=\"target\" value='`$prop.underlay.routeIds[$jidx].hubRouteId`'/>\n\n\n", + "comments": "", + "outputs": 1, + "x": 2163.329833984375, + "y": 1665.9966478347778, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "328df7f4.d9d5f8", + "type": "execute", + "name": "execute concat", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='concat' >\n <parameter name=\"source\" value='`$prop.underlay.routeIds[$jidx].hubSiteId`'/>\n <parameter name=\"outputPath\" value=\"tmp.concat\"/>\n <parameter name=\"target\" value=\",\"/>\n\n\n", + "comments": "", + "outputs": 1, + "x": 2173.3298263549805, + "y": 1618.6629858016968, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "cdfd8790.f983d8", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1886.329517364502, + "y": 1717.6627750396729, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "328df7f4.d9d5f8", + "3e5fe1f4.4771be", + "413e65c4.2ce4ac", + "ce595947.f7b1e8", + "41c2276f.7ab7c8", + "a2941eac.dd47a" + ] + ] + }, + { + "id": "413e65c4.2ce4ac", + "type": "execute", + "name": "execute concat", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='concat' >\n <parameter name=\"source\" value='`$tmp.concat1`'/>\n <parameter name=\"outputPath\" value=\"tmp.concat2\"/>\n <parameter name=\"target\" value=\",\"/>\n\n\n", + "comments": "", + "outputs": 1, + "x": 2170.3295364379883, + "y": 1705.6628789901733, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "ce595947.f7b1e8", + "type": "execute", + "name": "execute concat", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='concat' >\n <parameter name=\"source\" value='`$tmp.concat2`'/>\n <parameter name=\"outputPath\" value=\"tmp.concat3\"/>\n <parameter name=\"target\" value='`$prop.underlay.routeIds[$jidx].spokeRouteId`'/>\n\n\n", + "comments": "", + "outputs": 1, + "x": 2170.3295364379883, + "y": 1741.6628789901733, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "41c2276f.7ab7c8", + "type": "execute", + "name": "execute concat", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='concat' >\n <parameter name=\"source\" value='`$tmp.concat3`'/>\n <parameter name=\"outputPath\" value=\"tmp.concat4\"/>\n <parameter name=\"target\" value=\" | \"/>\n\n\n", + "comments": "", + "outputs": 1, + "x": 2163.3295364379883, + "y": 1781.9962530136108, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "a2941eac.dd47a", + "type": "execute", + "name": "execute concat", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='concat' >\n <parameter name=\"source\" value='`$tmp.routeString`'/>\n <parameter name=\"outputPath\" value=\"tmp.routeString\"/>\n <parameter name=\"target\" value='`$tmp.concat4`'/>\n\n\n", + "comments": "", + "outputs": 1, + "x": 2166.329475402832, + "y": 1836.6627922058105, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "93dcb194.e6988", + "type": "set", + "name": "Set tmp.routeString", + "xml": "<set>\n<parameter name='tmp.routeString' value=\"\" />\n\n", + "comments": "", + "x": 1883.3294982910156, + "y": 1473.6627759933472, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "981ac32e.958e4", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3771.9963188171387, + "y": 596.9961318969727, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "a4a704fd.090458", + "474a807.5a3348" + ] + ] + }, + { + "id": "474a807.5a3348", + "type": "execute", + "name": "execute split |", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$prop.underlay.routeIdsString`'/>\n<parameter name=\"regex\" value=\" | \"/>\n<parameter name=\"ctx_memory_result_key\" value=\"prop.underlay.routeIdsValue\"/>\n", + "comments": "", + "outputs": 1, + "x": 3949.9963302612305, + "y": 616.9961318969727, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "5c929964.4b8ce8", + "acedb986.795fa8" + ] + ] + }, + { + "id": "acedb986.795fa8", + "type": "failure", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 4126.9963455200195, + "y": 597.9961309432983, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "96ac3ef1.0da81" + ] + ] + }, + { + "id": "5c929964.4b8ce8", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 4115.9963455200195, + "y": 645.996132850647, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "90fc0aec.112218" + ] + ] + }, + { + "id": "62992e2c.a242f", + "type": "set", + "name": "set ipAddress prefixLength", + "xml": "<set>\n<parameter name='prop.underlay.routeIds[$prop.underlay.routeIds_length].hubSiteId' value='`$prop.underlay.routeIdsValues[0]`' />\n<parameter name='prop.underlay.routeIds[$prop.underlay.routeIds_length].hubRouteId' value='`$prop.underlay.routeIdsValues[1]`' />\n<parameter name='prop.underlay.routeIds[$prop.underlay.routeIds_length].spokeRouteId' value='`$prop.underlay.routeIdsValues[2]`' />", + "comments": "", + "x": 5312.997211456299, + "y": 531.9963731765747, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "90fc0aec.112218", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 4245.996349334717, + "y": 645.996132850647, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "96ac3ef1.0da81", + "type": "for", + "name": "for loop ridx ", + "xml": "<for index=\"ridx\" start=\"0\" end=\"`$prop.underlay.routeIdsValue_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 4272.996032714844, + "y": 595.9961309432983, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "94fe12e4.b3272" + ] + ] + }, + { + "id": "94fe12e4.b3272", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 4451.329044342041, + "y": 592.9961318969727, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "bc1b307a.e9066" + ] + ] + }, + { + "id": "bc1b307a.e9066", + "type": "execute", + "name": "execute split ,", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$prop.underlay.routeIdsValue[$ridx]`'/>\n<parameter name=\"regex\" value=\",\"/>\n<parameter name=\"ctx_memory_result_key\" value=\"prop.underlay.routeIdsValues\"/>\n", + "comments": "", + "outputs": 1, + "x": 4626.329055786133, + "y": 591.996129989624, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "479c7699.d03df8", + "992b4620.1b2238" + ] + ] + }, + { + "id": "479c7699.d03df8", + "type": "failure", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 4783.32905960083, + "y": 568.9961376190186, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "bee08918.a3dfe8" + ] + ] + }, + { + "id": "992b4620.1b2238", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 4772.32905960083, + "y": 616.9961395263672, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "1506d77b.2e8159" + ] + ] + }, + { + "id": "1506d77b.2e8159", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 4902.329063415527, + "y": 616.9961395263672, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "16eea4b9.2fb1ab", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 5105.661590576172, + "y": 547.9962916374207, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "62992e2c.a242f", + "2107fdbe.561112" + ] + ] + }, + { + "id": "2107fdbe.561112", + "type": "set", + "name": "set ipAddress prefixLength", + "xml": "<set>\n<parameter name='prop.underlay.routeIds_length' value='`$prop.underlay.routeIds_length + 1`' />\n", + "comments": "", + "x": 5305.329250335693, + "y": 573.996169090271, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "bee08918.a3dfe8", + "type": "switchNode", + "name": "switch prop.underlay.routeIdsValues_length", + "xml": "<switch test='`$prop.underlay.routeIdsValues_length`'>\n", + "comments": "", + "outputs": 1, + "x": 4981.663215637207, + "y": 449.9961624145508, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "17f5531.c69dcad", + "9cd3fd30.65304" + ] + ] + }, + { + "id": "17f5531.c69dcad", + "type": "outcome", + "name": "3", + "xml": "<outcome value='3'>\n", + "comments": "", + "outputs": 1, + "x": 5216.632148742676, + "y": 486.9648895263672, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "16eea4b9.2fb1ab" + ] + ] + }, + { + "id": "9cd3fd30.65304", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 5233.663074493408, + "y": 368.99610328674316, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "ae2b29d0.cafa18" + ] + ] + }, + { + "id": "ae2b29d0.cafa18", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 5394.66259765625, + "y": 408.99609375, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "c6ccd14a.96548", + "type": "returnFailure", + "name": "return failure", + "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"Error: SOTN resource not found\" />\n \n", + "comments": "", + "x": 2874.002540588379, + "y": 982.3028502464294, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "92d1a6eb.dd91a8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2860.0020484924316, + "y": 930.9692711830139, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "d5a685ee.a4f698", + "type": "set", + "name": "hardcode hub route", + "xml": "<set>\n<parameter name='prop.hub.ipAddress' value=\"10.2.0.2\" />\n<parameter name='prop.hub.providerIpAddress' value=\"10.2.0.0/16\" />\n\n\n", + "comments": "", + "x": 3394.0038681030273, + "y": 1822.0039892196655, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "f073f95f.7848a8", + "type": "set", + "name": "hardcode spoke route", + "xml": "<set>\n<parameter name='prop.spoke.ipAddress' value=\"10.3.0.1\" />\n<parameter name='prop.spoke.providerIpAddress' value=\"10.3.0.0/16\" />", + "comments": "", + "x": 3409.004409790039, + "y": 2020.0039653778076, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "cc49685f.b2d5d8", + "type": "set", + "name": "hardcode hub route", + "xml": "<set>\n<parameter name='prop.hub.ipAddress' value=\"10.2.0.2\" />\n<parameter name='prop.hub.providerIpAddress' value=\"10.2.0.0/16\" />\n\n\n", + "comments": "", + "x": 3425.3335723876953, + "y": 2496.000065803528, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "7b57d512.398e6c", + "type": "set", + "name": "hardcode spoke route", + "xml": "<set>\n<parameter name='prop.spoke.ipAddress' value=\"10.3.0.1\" />\n<parameter name='prop.spoke.providerIpAddress' value=\"10.3.0.0/16\" />", + "comments": "", + "x": 3450.333251953125, + "y": 2608, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "ab1ef1f9.e54ea", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3461.0041694641113, + "y": 1227.5040493011475, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "564bf8e9.5ea9e8", + "273881de.ee082e" + ] + ] + }, + { + "id": "896da4ec.a5e9f8", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3791.2541217803955, + "y": 1395.0040378570557, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "9ec9fc87.5d09e" + ] + ] + }, + { + "id": "9ec9fc87.5d09e", + "type": "switchNode", + "name": "switch transportNetworkName==prop.spoke.transportNetworkName", + "xml": "<switch test=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.portvidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$wportidx].value == $prop.spoke.transportNetworkName`\">\n", + "comments": "", + "outputs": 1, + "x": 4124.004144668579, + "y": 1397.004313468933, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "3f80722d.d94e9e" + ] + ] + }, + { + "id": "3f80722d.d94e9e", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3991.0055894851685, + "y": 1493.0042219161987, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "473f2da5.df7aa4" + ] + ] + }, + { + "id": "473f2da5.df7aa4", + "type": "block", + "name": "block atmoic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 4146.755597114563, + "y": 1485.0042219161987, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "662f75a8.5b0d6c", + "d2c57b63.a72078" + ] + ] + }, + { + "id": "d2c57b63.a72078", + "type": "set", + "name": "set tmp.wanportvidx ", + "xml": "<set>\n<parameter name='tmp.wanportvidx' value='`$arvidx`' />\n\n", + "comments": "", + "x": 4324.2565660476685, + "y": 1461.004343032837, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "f5ec2256.55a71", + "type": "for", + "name": "for loop wanportvidx - Get wan port ID from servicedata", + "xml": "<for index=\"wportidx\" start=\"0\" end=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.wanportvidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n \n \n", + "comments": "", + "outputs": 1, + "x": 2732.5042877197266, + "y": 1673.0043449401855, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "a355c702.37b978" + ] + ] + }, + { + "id": "a355c702.37b978", + "type": "block", + "name": "block atomic", + "xml": "<block atomic=\"true\">\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3035.5056915283203, + "y": 1631.004680633545, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "4841755.e7a768c", + "7ff6e951.a32b78", + "803020cc.5b481" + ] + ] + }, + { + "id": "4841755.e7a768c", + "type": "switchNode", + "name": "switch wanPortId", + "xml": "<switch test=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.wanportvidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$wportidx].name == 'wanPortId'`\">\n", + "comments": "", + "outputs": 1, + "x": 3234.8393783569336, + "y": 1588.0048933029175, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "2cb90465.e59cdc" + ] + ] + }, + { + "id": "2cb90465.e59cdc", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3395.8397064208984, + "y": 1589.00497341156, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "406b564f.be2668" + ] + ] + }, + { + "id": "406b564f.be2668", + "type": "set", + "name": "set prop.hub.wanPortId", + "xml": "<set>\n<parameter name='prop.hub.wanPortId' value='`$mdsal-arsd.service-data.vnfs.vnf[$tmp.wanportvidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$wportidx].value`' />\n", + "comments": "", + "x": 3585.8401679992676, + "y": 1588.6052494049072, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "7ff6e951.a32b78", + "type": "switchNode", + "name": "switch providerIpAddress", + "xml": "<switch test=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.wanportvidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$wportidx].name == 'providerIpAddress'`\">\n", + "comments": "", + "outputs": 1, + "x": 3256.367862701416, + "y": 1625.2011981010437, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "de4c4cc0.abc22" + ] + ] + }, + { + "id": "de4c4cc0.abc22", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3432.3688468933105, + "y": 1625.2013206481934, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "409dc8c5.eeb998" + ] + ] + }, + { + "id": "409dc8c5.eeb998", + "type": "set", + "name": "set prop.hub.providerIpAddress", + "xml": "<set>\n<parameter name='prop.hub.providerIpAddress' value='`$mdsal-arsd.service-data.vnfs.vnf[$tmp.wanportvidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$wportidx].value`' />\n", + "comments": "", + "x": 3634.368885040283, + "y": 1625.8012409210205, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "803020cc.5b481", + "type": "switchNode", + "name": "switch ipAddress", + "xml": "<switch test=\"`$mdsal-arsd.service-data.vnfs.vnf[$tmp.wanportvidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$wportidx].name == 'ipAddress'`\">\n", + "comments": "", + "outputs": 1, + "x": 3228.867944717407, + "y": 1662.701283454895, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "25fd164b.117a3a" + ] + ] + }, + { + "id": "25fd164b.117a3a", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 3432.868885040283, + "y": 1662.701235294342, + "z": "ea31d3f9.c58ce", + "wires": [ + [ + "10522aa8.f003c5" + ] + ] + }, + { + "id": "10522aa8.f003c5", + "type": "set", + "name": "set prop.hub.ipAddress", + "xml": "<set>\n<parameter name='prop.hub.ipAddress' value='`$mdsal-arsd.service-data.vnfs.vnf[$tmp.wanportvidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$wportidx].value`' />\n", + "comments": "", + "x": 3627.8688888549805, + "y": 1662.3012108802795, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "722e84e9.8ab54c", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3837.254180908203, + "y": 1815.2539224624634, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "78300110.b43b4", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3849.25390625, + "y": 1859.25390625, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "e6f4e702.6d5b68", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3860.2543621063232, + "y": 2026.2540483474731, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "b3f4e792.e33638", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3861.254119873047, + "y": 2073.2540493011475, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "7b4a5da7.783c64", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3852.2542991638184, + "y": 2554.0039710998535, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "4079a316.d4531c", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3853.254056930542, + "y": 2601.003972053528, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "2a5c753b.10964a", + "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=\"Error executing sdwan hub route underlay rest api\" />\n", + "comments": "", + "x": 4005.336700439453, + "y": 2555.9710121154785, + "z": "ea31d3f9.c58ce", + "wires": [] + }, + { + "id": "ae6e8595.d05358", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3852.25390625, + "y": 2645.00390625, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + }, + { + "id": "a38da1c5.3c2df", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 3853.2536640167236, + "y": 2692.0039072036743, + "z": "ea31d3f9.c58ce", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-activate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-activate.json new file mode 100644 index 00000000..e920aca2 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-activate.json @@ -0,0 +1,1145 @@ +[ + { + "id": "3b96b94e.d2db46", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 101.71429443359375, + "y": 190.01038789749146, + "z": "f7b8765.9d87788", + "wires": [ + [ + "2a24b40f.15257c" + ] + ] + }, + { + "id": "2a24b40f.15257c", + "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": 177, + "y": 230.24849939346313, + "z": "f7b8765.9d87788", + "wires": [ + [ + "13982dc8.7557c2" + ] + ] + }, + { + "id": "13982dc8.7557c2", + "type": "method", + "name": "method site-vnf-topology-operation-activate", + "xml": "<method rpc='site-vnf-topology-operation-activate' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 198.14291381835938, + "y": 320.01038789749146, + "z": "f7b8765.9d87788", + "wires": [ + [ + "cc746.fa4808ba" + ] + ] + }, + { + "id": "cc746.fa4808ba", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 186.3810272216797, + "y": 509.6771664619446, + "z": "f7b8765.9d87788", + "wires": [ + [ + "7d7132e1.2faacc", + "43a548ad.54cc98", + "b5ec2bbf.0ef568", + "c9f28855.c58858", + "2cf8df50.df009", + "5f881f0.741dae", + "445ef8.15e44108", + "448dd2dd.bafb8c", + "f7484eea.3c8a9", + "3fda4a72.8f9396" + ] + ] + }, + { + "id": "7d7132e1.2faacc", + "type": "switchNode", + "name": "switch service-data.vnfs.vnf_length", + "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n", + "comments": "", + "outputs": 1, + "x": 625.7039566040039, + "y": 138.9999828338623, + "z": "f7b8765.9d87788", + "wires": [ + [ + "ed712d22.18f85", + "d79f3765.c39a08", + "34d8aa26.2a5306" + ] + ] + }, + { + "id": "ed712d22.18f85", + "type": "other", + "name": "Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 856.7039337158203, + "y": 141.00004625320435, + "z": "f7b8765.9d87788", + "wires": [ + [ + "774eda2e.68a9d4" + ] + ] + }, + { + "id": "774eda2e.68a9d4", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1014.4814491271973, + "y": 121.8889946937561, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "d79f3765.c39a08", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 848.7043609619141, + "y": 176.00006818771362, + "z": "f7b8765.9d87788", + "wires": [ + [ + "3a3303bd.28cb7c" + ] + ] + }, + { + "id": "3a3303bd.28cb7c", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1014.9738311767578, + "y": 167.55460166931152, + "z": "f7b8765.9d87788", + "wires": [ + [ + "46ac8f1a.93c77", + "dec89d20.3ffd2", + "aa1fa754.8a56c8" + ] + ] + }, + { + "id": "46ac8f1a.93c77", + "type": "for", + "name": "for vidx..service-data.vnfs.vnf_length[]", + "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1265.9899597167969, + "y": 112.42860507965088, + "z": "f7b8765.9d87788", + "wires": [ + [ + "5d97713b.b0498" + ] + ] + }, + { + "id": "dec89d20.3ffd2", + "type": "switchNode", + "name": "switch tmp.vidx ", + "xml": "<switch test=\"`$tmp.vidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1221.291275024414, + "y": 162.41179132461548, + "z": "f7b8765.9d87788", + "wires": [ + [ + "12d5f510.98545b" + ] + ] + }, + { + "id": "12d5f510.98545b", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1372.7200775146484, + "y": 162.9832215309143, + "z": "f7b8765.9d87788", + "wires": [ + [ + "baac3d2b.9c149" + ] + ] + }, + { + "id": "5d333a67.ea5b04", + "type": "switchNode", + "name": "switch vnfid found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1682.4186630249023, + "y": 71.67872476577759, + "z": "f7b8765.9d87788", + "wires": [ + [ + "ff1652c5.5f817" + ] + ] + }, + { + "id": "baac3d2b.9c149", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1511.1484756469727, + "y": 164.1260437965393, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "ff1652c5.5f817", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1856.3711433410645, + "y": 71.57144498825073, + "z": "f7b8765.9d87788", + "wires": [ + [ + "c70c2471.2c7958" + ] + ] + }, + { + "id": "34d8aa26.2a5306", + "type": "outcome", + "name": "0", + "xml": "<outcome value='0'>\n", + "comments": "", + "outputs": 1, + "x": 854.6727447509766, + "y": 103.9687352180481, + "z": "f7b8765.9d87788", + "wires": [ + [ + "774eda2e.68a9d4" + ] + ] + }, + { + "id": "c9f28855.c58858", + "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": 570.0479927062988, + "y": 692.344172000885, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "448dd2dd.bafb8c", + "type": "set", + "name": "set vnf-level-oper-status to Active", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.order-status' value='Active' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].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[$tmp.vidx].vnf-data.vnf-level-oper-status.last-action' value='`$vnf-topology-operation-input.request-information.request-action`' />\n", + "comments": "", + "x": 632.5281829833984, + "y": 526.6816115379333, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "445ef8.15e44108", + "type": "set", + "name": "set vnf-index and vnf-object-path", + "xml": "<set>\n<parameter name='vnfId' value='`$service-data.vnfs.vnf[$tmp.vidx].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/' + $vnf-topology-operation-input.vnf-information.vnf-id + '/vnf-data/'` \" />", + "comments": "", + "x": 632.2147827148438, + "y": 483.34414625167847, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "bbcb4df5.064e3", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1490.2148704528809, + "y": 428.0003957748413, + "z": "f7b8765.9d87788", + "wires": [ + [ + "1ea13654.9fcfaa" + ] + ] + }, + { + "id": "1ea13654.9fcfaa", + "type": "set", + "name": "set controller data", + "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n", + "comments": "", + "x": 1678.7149658203125, + "y": 422.00040543079376, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "f9005f03.a47fb", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 1493.7058372497559, + "y": 475.57443141937256, + "z": "f7b8765.9d87788", + "wires": [ + [ + "5c27d008.c54fe" + ] + ] + }, + { + "id": "5c27d008.c54fe", + "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1667.2772483825684, + "y": 463.86016750335693, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "5f7c43f4.71b4dc", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1486.0388450622559, + "y": 516.9077444076538, + "z": "f7b8765.9d87788", + "wires": [ + [ + "690bd523.e7874c" + ] + ] + }, + { + "id": "690bd523.e7874c", + "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1673.8114013671875, + "y": 512.3469371795654, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "766aef68.e4df8", + "type": "get-resource", + "name": "get-resource esr-thirdparty-sdnc", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n", + "comments": "", + "outputs": 1, + "x": 1223.2147827148438, + "y": 476.0004016160965, + "z": "f7b8765.9d87788", + "wires": [ + [ + "bbcb4df5.064e3", + "f9005f03.a47fb", + "5f7c43f4.71b4dc" + ] + ] + }, + { + "id": "cd48267e.9edf28", + "type": "execute", + "name": "execute RestApiCallNode Create SDWAN site", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-site-' + $template.site.role + '.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/sites'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"site-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 1250.71484375, + "y": 666.0003662109375, + "z": "f7b8765.9d87788", + "wires": [ + [ + "42f4d566.03c33c", + "bdd9ab07.dc7f48" + ] + ] + }, + { + "id": "f430b9bd.f345f8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1666.381420135498, + "y": 634.8892965316772, + "z": "f7b8765.9d87788", + "wires": [ + [] + ] + }, + { + "id": "49b0ec38.4844e4", + "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=\"Error executing Create vpn rest api\" />\n", + "comments": "", + "x": 1651.8260040283203, + "y": 694.4446439743042, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "bdd9ab07.dc7f48", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1506.8259944915771, + "y": 691.4446420669556, + "z": "f7b8765.9d87788", + "wires": [ + [ + "49b0ec38.4844e4" + ] + ] + }, + { + "id": "42f4d566.03c33c", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1507.2703323364258, + "y": 635.1114501953125, + "z": "f7b8765.9d87788", + "wires": [ + [ + "f430b9bd.f345f8" + ] + ] + }, + { + "id": "f7484eea.3c8a9", + "type": "set", + "name": "copy input data to service data", + "xml": "<set>\n<!--parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' /-->\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.sdnc-request-header.' value='$vnf-topology-operation-input.sdnc-request-header.' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.request-information.' value='$vnf-topology-operation-input.request-information.' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.service-information.' value='$vnf-topology-operation-input.service-information.' />", + "comments": "", + "x": 623.7147369384766, + "y": 570.0006427764893, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "416674e0.73681c", + "type": "execute", + "name": "execute RestApiCallNode Get token", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>", + "comments": "", + "outputs": 1, + "x": 1224.468879699707, + "y": 569.0044623613358, + "z": "f7b8765.9d87788", + "wires": [ + [ + "58134bd4.bcfed4", + "6a9bb51c.bc170c" + ] + ] + }, + { + "id": "58134bd4.bcfed4", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1489.4687614440918, + "y": 554.004357457161, + "z": "f7b8765.9d87788", + "wires": [ + [ + "b4100138.98e92" + ] + ] + }, + { + "id": "6a9bb51c.bc170c", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1481.7187614440918, + "y": 595.6472407579422, + "z": "f7b8765.9d87788", + "wires": [ + [ + "bf434721.5049e8" + ] + ] + }, + { + "id": "bf434721.5049e8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1607.8022575378418, + "y": 595.893273472786, + "z": "f7b8765.9d87788", + "wires": [ + [] + ] + }, + { + "id": "b4100138.98e92", + "type": "set", + "name": "set token-id", + "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n", + "comments": "", + "x": 1626.4687614440918, + "y": 554.004357457161, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "c6987662.432148", + "type": "comment", + "name": "tmp.thirdparty-sdnc-id is hardcoded value?", + "info": "", + "comments": "", + "x": 1271.7186813354492, + "y": 430.00437355041504, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "5f881f0.741dae", + "type": "set", + "name": "set siteId to service data", + "xml": "<set>\n<!--parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-id' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-id`' /-->\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].name' value='siteId' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].value' value='`$site-result.success[0].id`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1`' />\n", + "comments": "", + "x": 613.7185668945312, + "y": 445.0042562484741, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "473eb805.0b9488", + "type": "switchNode", + "name": "switch ActivateSDWANDeviceInstance", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-data.request-information.request-action == 'ActivateSDWANDeviceInstance'`\">\n\n \n \n\n", + "comments": "", + "outputs": 1, + "x": 1749.968635559082, + "y": 141.00390195846558, + "z": "f7b8765.9d87788", + "wires": [ + [ + "a2ae14c0.4e83e8" + ] + ] + }, + { + "id": "a2ae14c0.4e83e8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1976.968490600586, + "y": 140.00390100479126, + "z": "f7b8765.9d87788", + "wires": [ + [ + "e66294b6.7e7298" + ] + ] + }, + { + "id": "c0693138.694c4", + "type": "comment", + "name": "Get devices", + "info": "", + "comments": "", + "x": 1783.718650817871, + "y": 161.75391721725464, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "43a548ad.54cc98", + "type": "set", + "name": "set prop.site.sdwan false", + "xml": "<set>\n<parameter name='prop.site.sdwan' value=\"false\" />\n\n", + "comments": "", + "x": 604.7143096923828, + "y": 80.00003242492676, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "2cf8df50.df009", + "type": "switchNode", + "name": "switch prop.site.sdwan", + "xml": "<switch test=\"`$prop.site.sdwan`\">\n", + "comments": "", + "outputs": 1, + "x": 600.7144165039062, + "y": 387.6666216850281, + "z": "f7b8765.9d87788", + "wires": [ + [ + "6b990b0d.fef984" + ] + ] + }, + { + "id": "6b990b0d.fef984", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 779.7144660949707, + "y": 384.6666216850281, + "z": "f7b8765.9d87788", + "wires": [ + [ + "fac23885.a00b38" + ] + ] + }, + { + "id": "fac23885.a00b38", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 935.7146911621094, + "y": 381.66694355010986, + "z": "f7b8765.9d87788", + "wires": [ + [ + "d4d22841.f00eb8", + "cd48267e.9edf28", + "766aef68.e4df8", + "416674e0.73681c", + "793cd9f6.80cc58", + "702b3ce6.3adbe4" + ] + ] + }, + { + "id": "e66294b6.7e7298", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1932.381404876709, + "y": 202.00004196166992, + "z": "f7b8765.9d87788", + "wires": [ + [ + "288cc13c.94077e" + ] + ] + }, + { + "id": "288cc13c.94077e", + "type": "for", + "name": "for loop deviceidx - Get deviceId from servicedata", + "xml": "<for index=\"deviceidx\" start=\"0\" end=\"`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">", + "comments": "", + "outputs": 1, + "x": 2213.7151584625244, + "y": 212.00006246566772, + "z": "f7b8765.9d87788", + "wires": [ + [ + "d7048ef8.65174" + ] + ] + }, + { + "id": "d7048ef8.65174", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2329.714942932129, + "y": 263.00024795532227, + "z": "f7b8765.9d87788", + "wires": [ + [ + "2e66cefe.b9e7b2" + ] + ] + }, + { + "id": "2e66cefe.b9e7b2", + "type": "switchNode", + "name": "switch deviceId", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$deviceidx].name == 'deviceId'`\">\n", + "comments": "", + "outputs": 1, + "x": 2489.7151985168457, + "y": 265.00010108947754, + "z": "f7b8765.9d87788", + "wires": [ + [ + "302f3690.f9a14a" + ] + ] + }, + { + "id": "302f3690.f9a14a", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2641.7153701782227, + "y": 264.00010108947754, + "z": "f7b8765.9d87788", + "wires": [ + [ + "35a2ea58.cd5716" + ] + ] + }, + { + "id": "35a2ea58.cd5716", + "type": "set", + "name": "set deviceId", + "xml": "<set>\n<parameter name='prop.site.deviceId[$prop.site.deviceId_length]' value='`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$deviceidx].value`' />\n<parameter name='prop.site.deviceId_length' value='`$prop.site.deviceId_length + 1`' />\n", + "comments": "", + "x": 2781.71537399292, + "y": 263.6000556945801, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "aa1fa754.8a56c8", + "type": "set", + "name": "set prop.site.deviceId_length", + "xml": "<set>\n<parameter name='prop.site.deviceId_length' value='0' />\n", + "comments": "", + "x": 1257.7143669128418, + "y": 66.99999475479126, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "3fda4a72.8f9396", + "type": "save", + "name": "update siteInstance configuration in AAI", + "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='site-resource' \n key='site-resource.site-resource-id = $vnf-topology-operation-input.vnf-information.vnf-id' >\n<parameter name='site-resource-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' /> \n<parameter name='generated-site-id' value='`$site-result.success[0].id`' /> \n<parameter name='operational-status' value='Active' />\n", + "comments": "", + "outputs": 1, + "x": 653.7144622802734, + "y": 631.0001573562622, + "z": "f7b8765.9d87788", + "wires": [ + [] + ] + }, + { + "id": "b5ec2bbf.0ef568", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 596.7143325805664, + "y": 276.9999966621399, + "z": "f7b8765.9d87788", + "wires": [ + [] + ] + }, + { + "id": "d4d22841.f00eb8", + "type": "set", + "name": "set siteId", + "xml": "<set>\n<parameter name='prop.site.siteId' value=\"\" />\n\n", + "comments": "", + "x": 1158.714599609375, + "y": 384.0000915527344, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "c70c2471.2c7958", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 2026.7144393920898, + "y": 75.65758037567139, + "z": "f7b8765.9d87788", + "wires": [ + [ + "9ba5f463.943968", + "32028fb9.746e", + "fb0b8823.b3d168" + ] + ] + }, + { + "id": "32028fb9.746e", + "type": "set", + "name": "set vnf-request-input.", + "xml": "<set>\n<parameter name='vnf-request-input.' value='`$ctx.vnf-data.vnf-data.vnf-request-input.`' />\n\n", + "comments": "", + "x": 2279.04744720459, + "y": 92.65763568878174, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "9ba5f463.943968", + "type": "set", + "name": "set tmp.vidx and ctx.vnf-data", + "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].`' />\n", + "comments": "", + "x": 2306.60115814209, + "y": 46, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "fb0b8823.b3d168", + "type": "call", + "name": "call sdwan-get-site-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-site-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 2277.6881256103516, + "y": 128.1071195602417, + "z": "f7b8765.9d87788", + "wires": [ + [] + ] + }, + { + "id": "6f03dda4.fbdb64", + "type": "for", + "name": "for cpidx..prop.site.controlpoints", + "xml": "<for index='cpidx' start='0' end='`$prop.site.controlpoints_length`' >\n\t\t\t\t\t\t\t\t\t\n", + "comments": "", + "outputs": 1, + "x": 1240.7148895263672, + "y": 341.03131008148193, + "z": "f7b8765.9d87788", + "wires": [ + [ + "6ae2a7d2.64e9e8" + ] + ] + }, + { + "id": "6ae2a7d2.64e9e8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1447.7144165039062, + "y": 271.0312547683716, + "z": "f7b8765.9d87788", + "wires": [ + [ + "d5e8a02e.b6af9", + "f4a3ecf1.a3a47" + ] + ] + }, + { + "id": "5d97713b.b0498", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1504.9644374847412, + "y": 112.00390911102295, + "z": "f7b8765.9d87788", + "wires": [ + [ + "5d333a67.ea5b04", + "473eb805.0b9488" + ] + ] + }, + { + "id": "d5e8a02e.b6af9", + "type": "get-resource", + "name": "get-resource control pts for sideId", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"site-resource\" \n\t\tkey=\"site-resource.site-resource-name = $prop.controlPtId AND \n\t\t depth = '1'\"\n pfx='tmp.aai.controlPoints' local-only='false' >\n\n", + "comments": "", + "outputs": 1, + "x": 1671.0439834594727, + "y": 296.0000762939453, + "z": "f7b8765.9d87788", + "wires": [ + [ + "3002f41f.7cb61c", + "9eec95b7.76f808" + ] + ] + }, + { + "id": "545c41c0.800ed", + "type": "set", + "name": "set siteId in control point", + "xml": "<set>\n<parameter name='prop.site.controlpoints[$cpidx]' value='`$tmp.aai.controlPoints.generated-site-id`' />\n\n", + "comments": "", + "x": 2068.3771781921387, + "y": 266.0001964569092, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "3002f41f.7cb61c", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1889.7108268737793, + "y": 265.0000743865967, + "z": "f7b8765.9d87788", + "wires": [ + [ + "545c41c0.800ed" + ] + ] + }, + { + "id": "9eec95b7.76f808", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1891.9606704711914, + "y": 303.6429605484009, + "z": "f7b8765.9d87788", + "wires": [ + [ + "aebaf4c.ab33d08" + ] + ] + }, + { + "id": "aebaf4c.ab33d08", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 2032.3770179748535, + "y": 302.0000171661377, + "z": "f7b8765.9d87788", + "wires": [ + [] + ] + }, + { + "id": "f4a3ecf1.a3a47", + "type": "set", + "name": "set prop.controlPtId", + "xml": "<set>\n<parameter name='prop.controlPtId' value='`$prop.site.controlpoints[$cpidx]`' />\n\n", + "comments": "", + "x": 1632.7104873657227, + "y": 236.0000114440918, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "793cd9f6.80cc58", + "type": "call", + "name": "call sdwan-get-tenant-auth", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-tenant-auth' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 1203, + "y": 614, + "z": "f7b8765.9d87788", + "wires": [ + [] + ] + }, + { + "id": "702b3ce6.3adbe4", + "type": "switchNode", + "name": "switch prop.site.controlpoints ", + "xml": "<switch test=\"`$prop.site.controlPoint`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1098, + "y": 224, + "z": "f7b8765.9d87788", + "wires": [ + [ + "4ac6f9a0.74a1d8", + "b2aa5e32.50984" + ] + ] + }, + { + "id": "4ac6f9a0.74a1d8", + "type": "other", + "name": "Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1294, + "y": 197, + "z": "f7b8765.9d87788", + "wires": [ + [ + "d9d8dd65.e2446" + ] + ] + }, + { + "id": "b2aa5e32.50984", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1286, + "y": 246, + "z": "f7b8765.9d87788", + "wires": [ + [ + "d71ee31.658172" + ] + ] + }, + { + "id": "d9d8dd65.e2446", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1432, + "y": 199, + "z": "f7b8765.9d87788", + "wires": [ + [ + "ca30cd8f.df3a" + ] + ] + }, + { + "id": "f1ac4b9c.e46258", + "type": "comment", + "name": "should be null in request", + "info": "", + "comments": "", + "x": 1334.714584350586, + "y": 384.00006771087646, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "ca30cd8f.df3a", + "type": "set", + "name": "set template file hub", + "xml": "<set>\n<parameter name='template.site.role' value=\"hub\" />\n\n", + "comments": "", + "x": 1601.0039978027344, + "y": 202.00392055511475, + "z": "f7b8765.9d87788", + "wires": [] + }, + { + "id": "d71ee31.658172", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1095.003890991211, + "y": 289.0039052963257, + "z": "f7b8765.9d87788", + "wires": [ + [ + "6f03dda4.fbdb64", + "f3663259.ad67e" + ] + ] + }, + { + "id": "f3663259.ad67e", + "type": "set", + "name": "set template file spoke", + "xml": "<set>\n<parameter name='template.site.role' value=\"spoke\" />\n\n", + "comments": "", + "x": 1275.00390625, + "y": 308.0039129257202, + "z": "f7b8765.9d87788", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-create.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-create.json new file mode 100644 index 00000000..4d947bbf --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-create.json @@ -0,0 +1,439 @@ +[ + { + "id": "735f5ad1.ead7c4", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 77.71430206298828, + "y": 47, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "fe8db64d.524ea8" + ] + ] + }, + { + "id": "fe8db64d.524ea8", + "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": 177, + "y": 121.23810789268464, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "1caac0d4.b3765f" + ] + ] + }, + { + "id": "1caac0d4.b3765f", + "type": "method", + "name": "method site-vnf-topology-operation-create", + "xml": "<method rpc='site-vnf-topology-operation-create' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 198.14291381835938, + "y": 210.99999639671296, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "d05aaf1d.08055" + ] + ] + }, + { + "id": "d05aaf1d.08055", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 178.3809585571289, + "y": 382.66666814964265, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "6f65d305.7dd0dc", + "c0e8c4a0.84ad08", + "d1be6ea1.8ea6a", + "8988370b.251a38", + "61f164dd.5ae33c", + "1f2f5cd6.515d03", + "7fec36e8.2120f8", + "2f304e20.895352", + "4e05fc36.a331a4", + "b30ee953.435c78", + "1bdd47aa.96d5c8", + "e5bdd145.df52f" + ] + ] + }, + { + "id": "c0e8c4a0.84ad08", + "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": 606.5277099609375, + "y": 801.6705660820007, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "6f65d305.7dd0dc", + "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-index`' />\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": 593.380859375, + "y": 699.6667819023132, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "61f164dd.5ae33c", + "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-index\"/>\n", + "comments": "", + "outputs": 1, + "x": 577.7143936157227, + "y": 626.3334531784058, + "z": "5c7962f1.1a851c", + "wires": [ + [] + ] + }, + { + "id": "8388db61.48edd8", + "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-index`' />\n", + "comments": "", + "x": 590.7144584655762, + "y": 755.333420753479, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "d1be6ea1.8ea6a", + "type": "switchNode", + "name": "switch service-data.vnfs.vnf_length", + "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n", + "comments": "", + "outputs": 1, + "x": 607.7142791748047, + "y": 261.33335971832275, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "ec91878.ef3fc78", + "8eb89062.3f8df" + ] + ] + }, + { + "id": "ec91878.ef3fc78", + "type": "other", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 842.4286651611328, + "y": 256.4761800765991, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "ee0ce75d.fadbc8" + ] + ] + }, + { + "id": "ee0ce75d.fadbc8", + "type": "set", + "name": "set vnf-index=0", + "xml": "<set>\n<parameter name='vnf-index' value='0' />\n", + "comments": "", + "x": 1002.7143707275391, + "y": 256.4762716293335, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "8eb89062.3f8df", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 838.8572044372559, + "y": 289.76201152801514, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "dddde8e2.a6e3a8" + ] + ] + }, + { + "id": "22bd6504.22c48a", + "type": "set", + "name": "set vnf-index = vnf_length", + "xml": "<set>\n<parameter name='vnf-index' value='`$service-data.vnfs.vnf_length`' />\n", + "comments": "", + "x": 1231.7144470214844, + "y": 268.04773712158203, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "8d104e1d.a35c3", + "type": "for", + "name": "for each existing VNF", + "xml": "<for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1220.14306640625, + "y": 303.0477089881897, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "5570c3fc.a06f2c" + ] + ] + }, + { + "id": "dddde8e2.a6e3a8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 973.5714874267578, + "y": 291.761981010437, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "22bd6504.22c48a", + "8d104e1d.a35c3" + ] + ] + }, + { + "id": "5570c3fc.a06f2c", + "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": 1613.4288024902344, + "y": 303.6191930770874, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "476608a3.dc62a8" + ] + ] + }, + { + "id": "476608a3.dc62a8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1894.7145042419434, + "y": 302.190598487854, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "c72cc9fe.2f14b8" + ] + ] + }, + { + "id": "480cbd60.5b2ab4", + "type": "comment", + "name": "make sure this vnf-id doesn't exist already", + "info": "", + "comments": "", + "x": 1582.571418762207, + "y": 267.1905851364136, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "8988370b.251a38", + "type": "set", + "name": "set new vnf_length", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf_length' value='`$vnf-index + 1`' />\n", + "comments": "", + "x": 559.71435546875, + "y": 593.3334078788757, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "2f304e20.895352", + "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": 561.7143821716309, + "y": 1024.5970349311829, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "1f2f5cd6.515d03", + "type": "save", + "name": "save siteInstance configuration in AAI", + "xml": "<save plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='site-resource' \n key='site-resource.site-resource-id = $prop.vnf-index' >\n<parameter name='site-resource-id' value='`$prop.vnf-index`' /> \n<parameter name='site-resource-name' value='`$prop.site.name`' />\n<parameter name='description' value='`$prop.site.description`' />\n<parameter name='type' value='`$prop.site.type`' />\n<parameter name='role' value='`$prop.site.role`' />\n<parameter name='operational-status' value='Created' />\n<parameter name='model-customization-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`' />\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='selflink' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/' + $vnf-topology-operation-input.service-information.service-instance-id + '/service-data/vnfs/vnf/' + $prop.vnf-index + '/vnf-data/'` \" />\n", + "comments": "", + "outputs": 1, + "x": 610.3811264038086, + "y": 896.8190660476685, + "z": "5c7962f1.1a851c", + "wires": [ + [] + ] + }, + { + "id": "7fec36e8.2120f8", + "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=\"site-resource\" />\n<parameter name=\"relationship-list.relationship[0].related-link\" value=\"`'/network/site-resources/site-resource/' + $prop.vnf-index`\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-key\" value=\"site-resource.site-resource-id\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-value\" value=\"`$prop.vnf-index`\" />", + "comments": "", + "outputs": 1, + "x": 599.3811302185059, + "y": 959.5969486236572, + "z": "5c7962f1.1a851c", + "wires": [ + [] + ] + }, + { + "id": "4e05fc36.a331a4", + "type": "set", + "name": "set vnf-index and vnf-object-path", + "xml": "<set>\n<parameter name='vnfId' value='`$prop.vnf-index`' />\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-index + '/vnf-data/'` \" />", + "comments": "", + "x": 600.7143783569336, + "y": 845.5968370437622, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "b30ee953.435c78", + "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": 593.7143936157227, + "y": 400.0000629425049, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "a33f518e.35371" + ] + ] + }, + { + "id": "a33f518e.35371", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 808.4927368164062, + "y": 397.5556468963623, + "z": "5c7962f1.1a851c", + "wires": [ + [ + "97fc593c.33ca48", + "dcd520b2.7e574" + ] + ] + }, + { + "id": "97fc593c.33ca48", + "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": 1004.7489395141602, + "y": 375.3037853240967, + "z": "5c7962f1.1a851c", + "wires": [ + [] + ] + }, + { + "id": "dcd520b2.7e574", + "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": 974.1933670043945, + "y": 412.3039016723633, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "1bdd47aa.96d5c8", + "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": 555.7140121459961, + "y": 474.3247776031494, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "e5bdd145.df52f", + "type": "call", + "name": "call sdwan-get-site-param", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-site-param' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 571.7143783569336, + "y": 506.3249816894531, + "z": "5c7962f1.1a851c", + "wires": [ + [] + ] + }, + { + "id": "c72cc9fe.2f14b8", + "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": 2023.285873413086, + "y": 353.19061279296875, + "z": "5c7962f1.1a851c", + "wires": [] + }, + { + "id": "272c1a85.bab626", + "type": "comment", + "name": "Take the parameter names by removing prefix", + "info": "", + "comments": "", + "x": 1316.714485168457, + "y": 356.6666793823242, + "z": "5c7962f1.1a851c", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-deactivate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-deactivate.json new file mode 100644 index 00000000..739b68f0 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-deactivate.json @@ -0,0 +1,1036 @@ +[ + { + "id": "f2d5a044.e7585", + "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": 182.8570785522461, + "y": 139.23809814453125, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "3fa00e50.ff8f92" + ] + ] + }, + { + "id": "1dae242d.6645cc", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 107.57137298583984, + "y": 98.99998664855957, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "f2d5a044.e7585" + ] + ] + }, + { + "id": "3fa00e50.ff8f92", + "type": "method", + "name": "method site-vnf-topology-operation-deactivate", + "xml": "<method rpc='site-vnf-topology-operation-deactivate' mode='sync'>", + "comments": "", + "outputs": 1, + "x": 176, + "y": 178.99998092651367, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "42e004c2.23654c" + ] + ] + }, + { + "id": "42e004c2.23654c", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 216.73809814453125, + "y": 250.69349193572998, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "65c407c9.9f1008", + "48bce7ba.2d8768", + "a7851b19.e94318", + "7b84792a.cd09f8", + "33ca4ea0.f0ad62", + "85876d42.f8148", + "145e6ab2.474a25", + "65cd0ad5.7b6474", + "e07817c8.713ef8" + ] + ] + }, + { + "id": "33ca4ea0.f0ad62", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 623.7856979370117, + "y": 115.80950736999512, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "44befce.c3f5f04", + "7d171976.884c68", + "2cfd8e20.8f3c62", + "c7b90528.204df8" + ] + ] + }, + { + "id": "44befce.c3f5f04", + "type": "switchNode", + "name": "switch service-data.vnfs.vnf_length", + "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n", + "comments": "", + "outputs": 1, + "x": 903.6747055053711, + "y": 141.14282512664795, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "85e6c857.e79cf8", + "f4c886b6.8c7de8" + ] + ] + }, + { + "id": "85e6c857.e79cf8", + "type": "other", + "name": "outcome Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1157.2858276367188, + "y": 122.8095121383667, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "f39dd2df.24642" + ] + ] + }, + { + "id": "f39dd2df.24642", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1331.2858428955078, + "y": 122.8095121383667, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "f4c886b6.8c7de8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1140.7857971191406, + "y": 158.80952262878418, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "9dbcc4cd.8daf68" + ] + ] + }, + { + "id": "9dbcc4cd.8daf68", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1322.7859954833984, + "y": 169.80952835083008, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "5192b087.75251", + "a84b6b1.e64a598" + ] + ] + }, + { + "id": "a84b6b1.e64a598", + "type": "switchNode", + "name": "switch tmp.vidx ", + "xml": "<switch test=\"`$tmp.vidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1512.785888671875, + "y": 186.80952262878418, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "f8861e43.09ff7" + ] + ] + }, + { + "id": "c7b90528.204df8", + "type": "switchNode", + "name": "switch vnf-level-oper-status", + "xml": "<switch test='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.order-status`'>\n", + "comments": "", + "outputs": 1, + "x": 866.952507019043, + "y": 236.69837856292725, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "4f6faf17.9da86", + "63b6f7c3.593ea8" + ] + ] + }, + { + "id": "4f6faf17.9da86", + "type": "outcome", + "name": "outcome Active", + "xml": "<outcome value='Active'>\n", + "comments": "", + "outputs": 1, + "x": 1173.7858200073242, + "y": 217.8095006942749, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "a798f2fb.14365" + ] + ] + }, + { + "id": "63b6f7c3.593ea8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1141.7858200073242, + "y": 257.8095006942749, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "1d11ed5c.996383" + ] + ] + }, + { + "id": "1d11ed5c.996383", + "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 is not in appropriate state for deactivate. Current state is ' + $service-data.vnfs.vnf[$tmp.nidx].vnf-data.vnf-level-oper-status.order-status`\" />", + "comments": "", + "x": 1299.2858200073242, + "y": 257.8095006942749, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "7d171976.884c68", + "type": "switchNode", + "name": "switch vnf-id", + "xml": "<switch test=\"`$vnf-topology-operation-input.vnf-information.vnf-id`\">\n", + "comments": "", + "outputs": 1, + "x": 845.7858047485352, + "y": 81.80949974060059, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "f940f6c8.c04158" + ] + ] + }, + { + "id": "f940f6c8.c04158", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 988.7857971191406, + "y": 81.80950260162354, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "8db9d430.4ecf68" + ] + ] + }, + { + "id": "8db9d430.4ecf68", + "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-topology-operation-input.vnf-information.vnf-id is a required input\" />\n", + "comments": "", + "x": 1137.2857971191406, + "y": 81.80950164794922, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "5192b087.75251", + "type": "for", + "name": "for vidx..service-data.vnfs.vnf[]", + "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1558.2859191894531, + "y": 148.8095121383667, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "93fbba5f.463c78" + ] + ] + }, + { + "id": "93fbba5f.463c78", + "type": "switchNode", + "name": "switch vnf-id found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1844.2859191894531, + "y": 148.8095121383667, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "8c6bb65a.97de78" + ] + ] + }, + { + "id": "8c6bb65a.97de78", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2029.7859954833984, + "y": 148.80951404571533, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "5c836ef8.46731" + ] + ] + }, + { + "id": "5c836ef8.46731", + "type": "set", + "name": "set tmp.vidx and ctx.vnf-data", + "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].vnf-data.`' />\n", + "comments": "", + "x": 2237.785919189453, + "y": 148.8095121383667, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "7e651921.d7b4c8", + "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-topology-operation-input.vnf-information.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1804.285888671875, + "y": 186.80952262878418, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "f8861e43.09ff7", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1666.785888671875, + "y": 186.80952262878418, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "7e651921.d7b4c8" + ] + ] + }, + { + "id": "65c407c9.9f1008", + "type": "set", + "name": "set vnf in service-data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.sdnc-request-header.' value='`$vnf-topology-operation-input.sdnc-request-header.`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.request-information.' value='`$vnf-topology-operation-input.request-information.`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.service-information.' value='`$vnf-topology-operation-input.service-information.`' />", + "comments": "", + "x": 610.5715866088867, + "y": 584.00022315979, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "48bce7ba.2d8768", + "type": "set", + "name": "set vnfId and vnf-object-path", + "xml": "<set>\n<parameter name='vnfId' value='`$vnf-topology-operation-input.vnf-information.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/' + $vnf-topology-operation-input.vnf-information.vnf-id + '/vnf-data/'` \" />", + "comments": "", + "x": 632.1271820068359, + "y": 621.2224445343018, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "7b84792a.cd09f8", + "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": 585.9049634933472, + "y": 771.7778739929199, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "a7851b19.e94318", + "type": "set", + "name": "set vnf-level-oper-status to PendingDelete", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.order-status' value='PendingDelete' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].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[$tmp.vidx].vnf-data.vnf-level-oper-status.last-action' value='`$vnf-topology-operation-input.request-information.request-action`' />\n", + "comments": "", + "x": 670.5715866088867, + "y": 665.0002861022949, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "a798f2fb.14365", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1367.713279724121, + "y": 221.88886964321136, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [] + ] + }, + { + "id": "2cfd8e20.8f3c62", + "type": "execute", + "name": "execute requiredParameters", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='requiredParameters' >\n<parameter name=\"vnf-topology-operation-input.vnf-information.vnf-id\" value=\"$vnf-topology-operation-input.vnf-information.vnf-id\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 895.5716171264648, + "y": 44, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [] + ] + }, + { + "id": "dc5cbf86.069cb", + "type": "comment", + "name": "site-vnf-topology-operation-deactivate", + "info": "", + "comments": "", + "x": 489.8570785522461, + "y": 44.23809814453125, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "85876d42.f8148", + "type": "for", + "name": "for loop idx - VNF input parameters", + "xml": "<for index='idx' start='0' end='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`' >\n", + "comments": "", + "outputs": 1, + "x": 667.8572273254395, + "y": 315.0000219345093, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "3e4458ac.5a1978" + ] + ] + }, + { + "id": "3e4458ac.5a1978", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 874.7529640197754, + "y": 314.9218854904175, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "d28edbd3.ae9358", + "bda524fb.86fa98" + ] + ] + }, + { + "id": "d28edbd3.ae9358", + "type": "switchNode", + "name": "switch type", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$idx].name == 'type'`\">\n", + "comments": "", + "outputs": 1, + "x": 1011.8701667785645, + "y": 314.89532566070557, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "a740d422.40d728" + ] + ] + }, + { + "id": "a740d422.40d728", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1151.870174407959, + "y": 315.89532566070557, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "feaf8bb0.d7e508" + ] + ] + }, + { + "id": "feaf8bb0.d7e508", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1300.419822692871, + "y": 316.9220190048218, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "6e080bd9.2cad94" + ] + ] + }, + { + "id": "6e080bd9.2cad94", + "type": "set", + "name": "set type and sdwan flag", + "xml": "<set>\n<parameter name='prop.site.type' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n<parameter name='prop.site.sdwan' value=\"true\" />\n", + "comments": "", + "x": 1444.7531852722168, + "y": 317.9220361709595, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "145e6ab2.474a25", + "type": "switchNode", + "name": "switch prop.site.sdwan", + "xml": "<switch test=\"`$prop.site.sdwan`\">\n", + "comments": "", + "outputs": 1, + "x": 641.8570785522461, + "y": 470.00004386901855, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "c9081f3c.c4c52" + ] + ] + }, + { + "id": "c9081f3c.c4c52", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 822.8572120666504, + "y": 471.0000705718994, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "5bb614a8.7a50ac" + ] + ] + }, + { + "id": "619fc994.c8c7e8", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1527.357234954834, + "y": 439.00012493133545, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "9d1c31d.0bb00d" + ] + ] + }, + { + "id": "9d1c31d.0bb00d", + "type": "set", + "name": "set controller data", + "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n", + "comments": "", + "x": 1715.8573303222656, + "y": 433.0001345872879, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "a8d0eff5.22c29", + "type": "not-found", + "name": "not-found", + "xml": "<outcome value='not-found'>\n", + "comments": "", + "outputs": 1, + "x": 1530.848201751709, + "y": 486.5741605758667, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "182c54e4.50314b" + ] + ] + }, + { + "id": "182c54e4.50314b", + "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1704.4196128845215, + "y": 474.8598966598511, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "dafc7114.f9611", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1523.181209564209, + "y": 527.907473564148, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "9c3bc7c8.8428c8" + ] + ] + }, + { + "id": "9c3bc7c8.8428c8", + "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n", + "comments": "", + "x": 1710.9537658691406, + "y": 523.3466663360596, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "2718b5aa.7ee4da", + "type": "get-resource", + "name": "get-resource esr-thirdparty-sdnc", + "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n", + "comments": "", + "outputs": 1, + "x": 1260.3571472167969, + "y": 487.00013077259064, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "619fc994.c8c7e8", + "a8d0eff5.22c29", + "dafc7114.f9611" + ] + ] + }, + { + "id": "f6e580dc.483b5", + "type": "execute", + "name": "execute RestApiCallNode Create SDWAN site", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-site-del.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/sites/action/batch-delete'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"site-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />", + "comments": "", + "outputs": 1, + "x": 1288.8574905395508, + "y": 685.0002021789551, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "9ccdb4e3.7037b8", + "542d6497.1e051c" + ] + ] + }, + { + "id": "efaab9ba.da6af8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1684.523811340332, + "y": 664.8890171051025, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [] + ] + }, + { + "id": "eed03e10.52741", + "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=\"Error executing Create vpn rest api\" />\n", + "comments": "", + "x": 1681.9683113098145, + "y": 699.444356918335, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "f190e7e4.b492e8", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1537.9683074951172, + "y": 698.444356918335, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "eed03e10.52741" + ] + ] + }, + { + "id": "3d884d4b.3bb372", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1541.4126434326172, + "y": 667.1111841201782, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "efaab9ba.da6af8" + ] + ] + }, + { + "id": "268a0227.9f4d8e", + "type": "success", + "name": "success", + "xml": "<outcome value='success'>\n", + "comments": "", + "outputs": 1, + "x": 1526.611125946045, + "y": 565.0040866136551, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "7a5f68d2.12c3e8" + ] + ] + }, + { + "id": "ec5d99f5.fe59b8", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1518.861125946045, + "y": 606.6469699144363, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "dc9e3b17.c88cb8" + ] + ] + }, + { + "id": "dc9e3b17.c88cb8", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1644.944622039795, + "y": 606.8930026292801, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [] + ] + }, + { + "id": "7a5f68d2.12c3e8", + "type": "set", + "name": "set token-id", + "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n", + "comments": "", + "x": 1663.611125946045, + "y": 565.0040866136551, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "cbf3519f.042f3", + "type": "comment", + "name": "tmp.thirdparty-sdnc-id is hardcoded value?", + "info": "", + "comments": "", + "x": 1256.8610382080078, + "y": 454.0040522813797, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "5bb614a8.7a50ac", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 983.8571472167969, + "y": 471.6665782928467, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "2718b5aa.7ee4da", + "8fc11da9.0efed", + "f6e580dc.483b5", + "49b38240.460c6c" + ] + ] + }, + { + "id": "65cd0ad5.7b6474", + "type": "save", + "name": "update siteInstance configuration in AAI", + "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='site-resource' \n key='site-resource.site-resource-id = $vnf-topology-operation-input.vnf-information.vnf-id' >\n<parameter name='site-resource-id' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' /> \n<parameter name='operational-status' value='PendingDelete' />\n", + "comments": "", + "outputs": 1, + "x": 663.8571701049805, + "y": 704.0001029968262, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [] + ] + }, + { + "id": "bda524fb.86fa98", + "type": "switchNode", + "name": "switch siteId", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$idx].name == 'siteId'`\">\n", + "comments": "", + "outputs": 1, + "x": 1011.8700637817383, + "y": 389.8953685760498, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "5e12f6f2.154df8" + ] + ] + }, + { + "id": "5e12f6f2.154df8", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1151.8700714111328, + "y": 390.8953685760498, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "c0b4aa42.b23db8" + ] + ] + }, + { + "id": "c0b4aa42.b23db8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1300.419719696045, + "y": 391.922061920166, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "12912fa7.36df6" + ] + ] + }, + { + "id": "12912fa7.36df6", + "type": "set", + "name": "set siteId", + "xml": "<set>\n<parameter name='prop.site.siteId' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$idx].value`' />\n\n", + "comments": "", + "x": 1444.7530822753906, + "y": 392.9220790863037, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "cc3aa10c.cf485", + "type": "comment", + "name": "Get siteId to delete", + "info": "", + "comments": "", + "x": 1023.857048034668, + "y": 359.0000247955322, + "z": "ccd0c7cf.3cb8d8", + "wires": [] + }, + { + "id": "8fc11da9.0efed", + "type": "execute", + "name": "execute RestApiCallNode Get token", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>", + "comments": "", + "outputs": 1, + "x": 1277.0000762939453, + "y": 588.000039100647, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "268a0227.9f4d8e", + "ec5d99f5.fe59b8" + ] + ] + }, + { + "id": "e07817c8.713ef8", + "type": "execute", + "name": "execute Properties", + "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", + "comments": "", + "outputs": 1, + "x": 617, + "y": 225.00000095367432, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [] + ] + }, + { + "id": "49b38240.460c6c", + "type": "call", + "name": "call sdwan-get-tenant-auth", + "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-tenant-auth' mode='sync' >\n", + "comments": "", + "outputs": 1, + "x": 1237, + "y": 637, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [] + ] + }, + { + "id": "9ccdb4e3.7037b8", + "type": "failure", + "name": "failure", + "xml": "<outcome value='failure'>\n", + "comments": "", + "outputs": 1, + "x": 1545, + "y": 762, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "b8677116.110c6" + ] + ] + }, + { + "id": "b8677116.110c6", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1701, + "y": 762, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [] + ] + }, + { + "id": "542d6497.1e051c", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1545, + "y": 811, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [ + "e1c3f88e.80fd88" + ] + ] + }, + { + "id": "e1c3f88e.80fd88", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "comments": "", + "outputs": 1, + "x": 1723, + "y": 808, + "z": "ccd0c7cf.3cb8d8", + "wires": [ + [] + ] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-delete.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-delete.json new file mode 100644 index 00000000..463dc7f2 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_site-vnf-topology-operation-delete.json @@ -0,0 +1,569 @@ +[ + { + "id": "1e0cb698.a04019", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 107.57138061523438, + "y": 61.999998569488525, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "277c65c2.ed804a" + ] + ] + }, + { + "id": "277c65c2.ed804a", + "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": 182.85708618164062, + "y": 102.2381100654602, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "a7e1f73c.bc4948" + ] + ] + }, + { + "id": "a7e1f73c.bc4948", + "type": "method", + "name": "method site-vnf-topology-operation-delete", + "xml": "<method rpc='site-vnf-topology-operation-delete' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 163, + "y": 237.99999856948853, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "bdf1765.0f24c88" + ] + ] + }, + { + "id": "ca44419d.5ab99", + "type": "comment", + "name": "site-vnf-topology-operation-delete", + "info": "", + "comments": "", + "x": 556.9162979125977, + "y": 135.58639764785767, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "bdf1765.0f24c88", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 184.23804473876953, + "y": 363.6666703224182, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "372cbde7.587372", + "5c8ef11.4d9e21", + "c063c177.c449a", + "b76f0527.dbb128", + "bcc212f6.b90ab", + "12ca3dc.2d458c2", + "c460861f.38f098", + "6a5ea2dd.9c807c", + "55ed5ce8.2b1ae4", + "ba708495.2ebbe8", + "4890886d.4993b8" + ] + ] + }, + { + "id": "bcc212f6.b90ab", + "type": "switchNode", + "name": "switch service-data.vnfs.vnf_length", + "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n", + "comments": "", + "outputs": 1, + "x": 645.6660842895508, + "y": 297.2611689567566, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "d5d54ea4.ba5c6", + "291bcf0.559d232" + ] + ] + }, + { + "id": "d5d54ea4.ba5c6", + "type": "other", + "name": "outcome Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 910.3883972167969, + "y": 279.81679105758667, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "30ee642f.b18d2c" + ] + ] + }, + { + "id": "30ee642f.b18d2c", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1091.3882675170898, + "y": 274.81666898727417, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "291bcf0.559d232", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 895.8883972167969, + "y": 331.81675386428833, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "fb8a0e1a.913bb" + ] + ] + }, + { + "id": "fb8a0e1a.913bb", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1067.8881034851074, + "y": 331.8167519569397, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "5412f014.12424", + "97fd60bf.39c2c" + ] + ] + }, + { + "id": "97fd60bf.39c2c", + "type": "switchNode", + "name": "switch tmp.nidx ", + "xml": "<switch test=\"`$tmp.nidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1242.8882751464844, + "y": 350.81667375564575, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "7e0c16e8.e0d2b8" + ] + ] + }, + { + "id": "b76f0527.dbb128", + "type": "switchNode", + "name": "switch vnf-level-oper-status", + "xml": "<switch test='`$service-data.vnfs.vnf[$tmp.nidx].vnf-data.vnf-level-oper-status.order-status`'>\n", + "comments": "", + "outputs": 1, + "x": 616.0550842285156, + "y": 371.705632686615, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "2c1cb407.0b20fc", + "7a49e612.028b78" + ] + ] + }, + { + "id": "2c1cb407.0b20fc", + "type": "outcome", + "name": "outcome PendingDelete", + "xml": "<outcome value='PendingDelete'>\n", + "comments": "", + "outputs": 1, + "x": 906.8883514404297, + "y": 375.81675577163696, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "4b86cba0.d35104" + ] + ] + }, + { + "id": "7a49e612.028b78", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 852.8884124755859, + "y": 422.81675958633423, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "cae57504.d32048" + ] + ] + }, + { + "id": "cae57504.d32048", + "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 is not in appropriate state for activate. Current state is ' + $service-data.vnfs.vnf[$tmp.nidx].vnf-data.vnf-level-oper-status.order-status`\" />", + "comments": "", + "x": 1012.3881797790527, + "y": 425.8167586326599, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "12ca3dc.2d458c2", + "type": "switchNode", + "name": "switch vnf-id", + "xml": "<switch test=\"`$vnf-topology-operation-input.vnf-information.vnf-id`\">\n", + "comments": "", + "outputs": 1, + "x": 581.8884010314941, + "y": 252.81676244735718, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "479f1e18.fbfce" + ] + ] + }, + { + "id": "479f1e18.fbfce", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 779.8884658813477, + "y": 242.8167748451233, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "e26d76c0.5decd8" + ] + ] + }, + { + "id": "e26d76c0.5decd8", + "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-request-input.vnf-input-parameters.name is a required input\" />\n", + "comments": "", + "x": 946.3883514404297, + "y": 239.8167691230774, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "c460861f.38f098", + "type": "execute", + "name": "execute requiredParameters", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='requiredParameters' >\n<parameter name=\"vnf-topology-operation-input.vnf-information.vnf-id\" value=\"$vnf-topology-operation-input.vnf-information.vnf-id\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 639.3884582519531, + "y": 192.81676149368286, + "z": "4e13a6ca.bd7208", + "wires": [ + [] + ] + }, + { + "id": "5412f014.12424", + "type": "for", + "name": "for nidx..service-data.vnfs.vnf[]", + "xml": "<for index='nidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 1303.3882789611816, + "y": 286.8166699409485, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "148fbb0c.c24365" + ] + ] + }, + { + "id": "148fbb0c.c24365", + "type": "switchNode", + "name": "switch vnf-id found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$nidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1559.388298034668, + "y": 286.8166699409485, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "b65bbab.9ca2c48" + ] + ] + }, + { + "id": "b65bbab.9ca2c48", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 1735.8883514404297, + "y": 289.8166699409485, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "1a4ecfb7.7d8f8" + ] + ] + }, + { + "id": "1a4ecfb7.7d8f8", + "type": "set", + "name": "set tmp.nidx and ctx.vnf-data", + "xml": "<set>\n<parameter name='tmp.nidx' value='`$nidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$nidx].vnf-data.`' />\n", + "comments": "", + "x": 1902.8883666992188, + "y": 350.8166699409485, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "e8e5a7c0.1c4938", + "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-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n", + "comments": "", + "x": 1548.3882904052734, + "y": 350.81667375564575, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "7e0c16e8.e0d2b8", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1410.8882904052734, + "y": 350.81667375564575, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "e8e5a7c0.1c4938" + ] + ] + }, + { + "id": "5c8ef11.4d9e21", + "type": "set", + "name": "set vnfId and vnf-object-path", + "xml": "<set>\n<parameter name='vnfId' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' />\n<parameter name='vnf-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vnf-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'` \" />", + "comments": "", + "x": 578.9050178527832, + "y": 641.3335304260254, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "c063c177.c449a", + "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": 538.0161476135254, + "y": 759.8890404701233, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "372cbde7.587372", + "type": "delete", + "name": "delete site instance configuration in AAI", + "xml": "<delete plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" resource='site-resource' \n key='site-resource.site-resource-id = $vnf-topology-operation-input.vnf-information.vnf-id'>\n", + "comments": "", + "outputs": 1, + "x": 606.4265480041504, + "y": 697.1378149986267, + "z": "4e13a6ca.bd7208", + "wires": [ + [] + ] + }, + { + "id": "4b86cba0.d35104", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1104.194751739502, + "y": 386.14191007614136, + "z": "4e13a6ca.bd7208", + "wires": [ + [] + ] + }, + { + "id": "6a5ea2dd.9c807c", + "type": "set", + "name": "set prop.vnfNewidx", + "xml": "<set>\n<parameter name='prop.vnfidxLen' value='`0`' />\n", + "comments": "", + "x": 585.0000762939453, + "y": 422.00006771087646, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "55ed5ce8.2b1ae4", + "type": "for", + "name": "for lidx..service-data.vnfs.vnf[]", + "xml": "<for index='lidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n", + "comments": "", + "outputs": 1, + "x": 602.0000381469727, + "y": 472.00007152557373, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "1913c26.edfaf3e" + ] + ] + }, + { + "id": "1913c26.edfaf3e", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 863.000114440918, + "y": 476.0001063346863, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "b02e3feb.ffee3" + ] + ] + }, + { + "id": "b02e3feb.ffee3", + "type": "switchNode", + "name": "switch vnf-id found", + "xml": "<switch test=\"`$service-data.vnfs.vnf[$lidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1055.0000610351562, + "y": 485.000150680542, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "e6008550.52d2f8" + ] + ] + }, + { + "id": "e6008550.52d2f8", + "type": "outcomeFalse", + "name": "false", + "xml": "<outcome value='false'>\n", + "comments": "", + "outputs": 1, + "x": 1241.0000762939453, + "y": 469.00003719329834, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "59e45e4c.5156f" + ] + ] + }, + { + "id": "59e45e4c.5156f", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1392, + "y": 470.00007343292236, + "z": "4e13a6ca.bd7208", + "wires": [ + [ + "9655d3b.ed2503", + "ee40dd88.8d1f1" + ] + ] + }, + { + "id": "9655d3b.ed2503", + "type": "set", + "name": "set vnf data", + "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$prop.vnfidxLen].vnf-id' value='`$service-data.vnfs.vnf[$lidx].vnf-id`' />\n<parameter name='service-data.vnfs.vnf[$prop.vnfidxLen].vnf-data.' value='`$service-data.vnfs.vnf[$lidx].vnf-data.`' />\n", + "comments": "", + "x": 1557.0000953674316, + "y": 445.00022888183594, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "ee40dd88.8d1f1", + "type": "set", + "name": "set prop.vnfNewidx", + "xml": "<set>\n<parameter name='prop.vnfidxLen' value='`$prop.vnfidxLen + 1`' />\n", + "comments": "", + "x": 1579.0000953674316, + "y": 501.0001926422119, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "ba708495.2ebbe8", + "type": "set", + "name": "set new vnf length", + "xml": "<set>\n\t<parameter name=\"service-data.vnfs.vnf_length\" value='`$prop.vnfidxLen`'/>\n\n\t\n", + "comments": "", + "x": 571.101432800293, + "y": 525.8043546676636, + "z": "4e13a6ca.bd7208", + "wires": [] + }, + { + "id": "4890886d.4993b8", + "type": "set", + "name": "Remove vnf from ServiceData", + "xml": "<set>\n\t<parameter name=\"service-data.vnfs.vnf[$prop.vnfidxLen].\" value=\"\"/>\n\n", + "comments": "", + "x": 608.0001106262207, + "y": 581.0001163482666, + "z": "4e13a6ca.bd7208", + "wires": [] + } +] diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_validate-sdwan-network-input-parameters.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_validate-sdwan-network-input-parameters.json new file mode 100644 index 00000000..3d6d6bc4 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_validate-sdwan-network-input-parameters.json @@ -0,0 +1,1201 @@ +[ + { + "id": "afeb4b10.2ec518", + "type": "dgstart", + "name": "DGSTART", + "outputs": 1, + "x": 107.00390625, + "y": 51.76191961765289, + "z": "7458dba4.32cb64", + "wires": [ + [ + "9ef25946.8f8138" + ] + ] + }, + { + "id": "9ef25946.8f8138", + "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": 352.2896194458008, + "y": 50.999998688697815, + "z": "7458dba4.32cb64", + "wires": [ + [ + "92a3d741.4ec998" + ] + ] + }, + { + "id": "92a3d741.4ec998", + "type": "method", + "name": "validate-sdwan-network-input-parameters", + "xml": "<method rpc='validate-sdwan-network-input-parameters' mode='sync'>\n", + "comments": "", + "outputs": 1, + "x": 309.92059326171875, + "y": 126.01493704319, + "z": "7458dba4.32cb64", + "wires": [ + [ + "11ca3a4.93689c6" + ] + ] + }, + { + "id": "11ca3a4.93689c6", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 593.9206008911133, + "y": 114.01496183872223, + "z": "7458dba4.32cb64", + "wires": [ + [ + "2b12fe90.83a562", + "91c94469.10e2a8" + ] + ] + }, + { + "id": "2b12fe90.83a562", + "type": "switchNode", + "name": "switch svc-action", + "xml": "<switch test='`$network-topology-operation-input.sdnc-request-header.svc-action`'>\n", + "comments": "", + "outputs": 1, + "x": 874.9206008911133, + "y": 109.01494753360748, + "z": "7458dba4.32cb64", + "wires": [ + [ + "d55b2509.439598" + ] + ] + }, + { + "id": "d55b2509.439598", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 1065.6349029541016, + "y": 110.0149484872818, + "z": "7458dba4.32cb64", + "wires": [ + [ + "aa102400.8ed8a8" + ] + ] + }, + { + "id": "aa102400.8ed8a8", + "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=\"sdnc-request-header.svc-request-id is a required input\" />\n", + "comments": "", + "x": 1240.0634536743164, + "y": 109.01494085788727, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "91c94469.10e2a8", + "type": "switchNode", + "name": "switch svc-action", + "xml": "<switch test='`$network-topology-operation-input.sdnc-request-header.svc-action`'>\n", + "comments": "", + "outputs": 1, + "x": 175.92054748535156, + "y": 385.01496183872223, + "z": "7458dba4.32cb64", + "wires": [ + [ + "13054de7.037f72", + "196d19c4.864306", + "766974bb.0b0c8c", + "c4c13754.2744e8", + "d97f2f03.ab243" + ] + ] + }, + { + "id": "13054de7.037f72", + "type": "outcome", + "name": "create", + "xml": "<outcome value='create'>\n", + "comments": "", + "outputs": 1, + "x": 384.50392150878906, + "y": 214.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "ce85f1c.60e7f1" + ] + ] + }, + { + "id": "ce85f1c.60e7f1", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 545.5039215087891, + "y": 214.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "14ed1ad7.45eb75" + ] + ] + }, + { + "id": "196d19c4.864306", + "type": "outcome", + "name": "deactivate", + "xml": "<outcome value='deactivate'>\n", + "comments": "", + "outputs": 1, + "x": 357.49591064453125, + "y": 823.1904579401016, + "z": "7458dba4.32cb64", + "wires": [ + [ + "39810a58.826e96" + ] + ] + }, + { + "id": "766974bb.0b0c8c", + "type": "outcome", + "name": "delete", + "xml": "<outcome value='delete'>\n", + "comments": "", + "outputs": 1, + "x": 361.2102928161621, + "y": 993.9050155878067, + "z": "7458dba4.32cb64", + "wires": [ + [ + "8132304a.a7e6f" + ] + ] + }, + { + "id": "c4c13754.2744e8", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 360.97218322753906, + "y": 1167.3333011865616, + "z": "7458dba4.32cb64", + "wires": [ + [ + "4398ae0d.dda9f" + ] + ] + }, + { + "id": "4398ae0d.dda9f", + "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=\"`$network-topology-operation-input.sdnc-request-header.svc-action + ' is not a valid svc-action'`\" />\n", + "comments": "", + "x": 544.5437164306641, + "y": 1167.9524418115616, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "14ed1ad7.45eb75", + "type": "switchNode", + "name": "switch request-action", + "xml": "<switch test='`$network-topology-operation-input.request-information.request-action`'>\n", + "comments": "", + "outputs": 1, + "x": 746.0038986206055, + "y": 212.42859840393066, + "z": "7458dba4.32cb64", + "wires": [ + [ + "501d8531.74505c", + "9ab1ce33.97d5d" + ] + ] + }, + { + "id": "501d8531.74505c", + "type": "other", + "name": "Other", + "xml": "<outcome value='Other'>", + "comments": "", + "outputs": 1, + "x": 944.5039215087891, + "y": 234.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "fe537f74.2801e" + ] + ] + }, + { + "id": "fe537f74.2801e", + "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=\"request-information.request-action is required to be SOTN CreateVPNNetworkInstance for svc-action=create\" />\n", + "comments": "", + "x": 1082.003921508789, + "y": 234.42858946323395, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "8d93a83c.557ca8", + "type": "other", + "name": "DeleteSDWANConnectivityInstance", + "xml": "<outcome value='DeleteSDWANConnectivityInstance'>", + "comments": "", + "outputs": 1, + "x": 783.0673332214355, + "y": 994.460285782814, + "z": "7458dba4.32cb64", + "wires": [ + [ + "ce9cc56b.d10598" + ] + ] + }, + { + "id": "5b1ba696.fd4ac8", + "type": "other", + "name": "Other", + "xml": "<outcome value='Other'>", + "comments": "", + "outputs": 1, + "x": 718.6228790283203, + "y": 1066.6825548410416, + "z": "7458dba4.32cb64", + "wires": [ + [ + "781f0dda.132404" + ] + ] + }, + { + "id": "781f0dda.132404", + "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=\"request-information.request-action is required to be SOTN DeleteVPNNetworkInstance for svc-action=delete\" />\n", + "comments": "", + "x": 878.956298828125, + "y": 1068.7936922311783, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "ce9cc56b.d10598", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1026.9562072753906, + "y": 996.6825376749039, + "z": "7458dba4.32cb64", + "wires": [ + [ + "d93bc459.24d028", + "c2120486.723e58", + "bad3546.ed6b1a8", + "36e3a49c.e1e66c" + ] + ] + }, + { + "id": "d97f2f03.ab243", + "type": "outcome", + "name": "activate", + "xml": "<outcome value='activate'>\n", + "comments": "", + "outputs": 1, + "x": 378.4324760437012, + "y": 477.47623217105865, + "z": "7458dba4.32cb64", + "wires": [ + [ + "11ba1c11.e436c4" + ] + ] + }, + { + "id": "11ba1c11.e436c4", + "type": "switchNode", + "name": "switch request-action", + "xml": "<switch test='`$network-topology-operation-input.request-information.request-action`'>\n", + "comments": "", + "outputs": 1, + "x": 561.2896423339844, + "y": 474.61908209323883, + "z": "7458dba4.32cb64", + "wires": [ + [ + "4b7aba5c.10de74", + "b08d251d.2801a8" + ] + ] + }, + { + "id": "4b7aba5c.10de74", + "type": "other", + "name": "ActivateSDWANConnectivityInstance", + "xml": "<outcome value='ActivateSDWANConnectivityInstance'>", + "comments": "", + "outputs": 1, + "x": 814.5039215087891, + "y": 454.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "59e37406.bc397c" + ] + ] + }, + { + "id": "b08d251d.2801a8", + "type": "other", + "name": "Other", + "xml": "<outcome value='Other'>", + "comments": "", + "outputs": 1, + "x": 744.5039215087891, + "y": 494.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "a5228d9.922b87" + ] + ] + }, + { + "id": "a5228d9.922b87", + "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=\"request-information.request-action is required to be SOTN ActivateVPNNetworkInstance for svc-action=activate\" />\n", + "comments": "", + "x": 902.0039215087891, + "y": 494.42858946323395, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "59e37406.bc397c", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1045.503921508789, + "y": 454.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "bad3546.ed6b1a8", + "d93bc459.24d028", + "c2120486.723e58", + "3af5d77e.c8b058" + ] + ] + }, + { + "id": "33ba9655.52034a", + "type": "other", + "name": "DeactivateSDWANConnectivityInstance", + "xml": "<outcome value='DeactivateSDWANConnectivityInstance'>", + "comments": "", + "outputs": 1, + "x": 800.9245376586914, + "y": 824.9048515558243, + "z": "7458dba4.32cb64", + "wires": [ + [ + "fc8127c.e4d07d8" + ] + ] + }, + { + "id": "a9fb5199.fc8f5", + "type": "other", + "name": "Other", + "xml": "<outcome value='Other'>", + "comments": "", + "outputs": 1, + "x": 715.9245300292969, + "y": 893.9048591852188, + "z": "7458dba4.32cb64", + "wires": [ + [ + "98e8303b.28c" + ] + ] + }, + { + "id": "98e8303b.28c", + "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=\"request-information.request-action is required to be SOTN DeactivateVPNNetworkInstance for svc-action=deactivate\" />\n", + "comments": "", + "x": 896.9245452880859, + "y": 894.9048591852188, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "39810a58.826e96", + "type": "switchNode", + "name": "switch request-action", + "xml": "<switch test='`$network-topology-operation-input.request-information.request-action`'>\n", + "comments": "", + "outputs": 1, + "x": 537.7815933227539, + "y": 825.3806854486465, + "z": "7458dba4.32cb64", + "wires": [ + [ + "33ba9655.52034a", + "a9fb5199.fc8f5" + ] + ] + }, + { + "id": "8132304a.a7e6f", + "type": "switchNode", + "name": "switch request-action", + "xml": "<switch test='`$network-topology-operation-input.request-information.request-action`'>\n", + "comments": "", + "outputs": 1, + "x": 541.5593948364258, + "y": 993.7142394781113, + "z": "7458dba4.32cb64", + "wires": [ + [ + "8d93a83c.557ca8", + "5b1ba696.fd4ac8" + ] + ] + }, + { + "id": "fc8127c.e4d07d8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1060.8926849365234, + "y": 827.7142463922501, + "z": "7458dba4.32cb64", + "wires": [ + [ + "d93bc459.24d028", + "c2120486.723e58", + "bad3546.ed6b1a8", + "376f44f.91631bc" + ] + ] + }, + { + "id": "9ab1ce33.97d5d", + "type": "other", + "name": "CreateSDWANConnectivityInstance", + "xml": "<outcome value='CreateSDWANConnectivityInstance'>", + "comments": "", + "outputs": 1, + "x": 1010.5039215087891, + "y": 194.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "b176ae48.6fe8f" + ] + ] + }, + { + "id": "b176ae48.6fe8f", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1225.503921508789, + "y": 194.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "cf12d38b.a3405" + ] + ] + }, + { + "id": "cf12d38b.a3405", + "type": "for", + "name": "for loop i - Network input parameters", + "xml": "<for index=\"i\" start=\"0\" end=\"`$network-topology-operation-input.network-request-input.network-input-parameters.param_length`\">\n", + "comments": "", + "outputs": 1, + "x": 1476.003921508789, + "y": 194.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "635e00b0.83e09" + ] + ] + }, + { + "id": "635e00b0.83e09", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1704.503921508789, + "y": 194.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "d02f1a6c.9ed398", + "7b155a14.1d88e4", + "a5572ff3.83699" + ] + ] + }, + { + "id": "d02f1a6c.9ed398", + "type": "set", + "name": "clear tmp-data", + "xml": "<set>\n<parameter name='tmp.name' value='' />\n<parameter name='tmp.value' value='' />\n", + "comments": "", + "x": 1887.503921508789, + "y": 154.42858946323395, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "7b155a14.1d88e4", + "type": "set", + "name": "set tmp-data", + "xml": "<set>\n<parameter name='tmp.name' value=\"`$network-topology-operation-input.network-request-input.network-input-parameters.param[$i].name`\"/>\n<parameter name='tmp.value' value=\"`$network-topology-operation-input.network-request-input.network-input-parameters.param[$i].value`\"/>\n", + "comments": "", + "x": 1882.003921508789, + "y": 194.42858946323395, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "a5572ff3.83699", + "type": "switchNode", + "name": "switch name", + "xml": "<switch test=\"`$tmp.name`\">\n", + "comments": "", + "outputs": 1, + "x": 1882.003921508789, + "y": 234.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "4c1f2b9e.d59164", + "930c8bdc.0463f8", + "6c76b8a1.37a458" + ] + ] + }, + { + "id": "9f5e4298.3ba59", + "type": "switchNode", + "name": "switch value", + "xml": "<switch test=\"`$tmp.value`\">\n", + "comments": "", + "outputs": 1, + "x": 2342.0040893554688, + "y": 186.42861008644104, + "z": "7458dba4.32cb64", + "wires": [ + [ + "b3a0c7f3.4a5588" + ] + ] + }, + { + "id": "6c76b8a1.37a458", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 2101.5042572021484, + "y": 252.42859768867493, + "z": "7458dba4.32cb64", + "wires": [ + [ + "6ab0e444.08d8bc" + ] + ] + }, + { + "id": "6ab0e444.08d8bc", + "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=\"`'network-topology-operation-input.network-request-input.network-input-parameters.param[' + $i + ']' + '.name is a required input'`\" />\n", + "comments": "", + "x": 2276.5042610168457, + "y": 251.42859768867493, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "4c1f2b9e.d59164", + "type": "other", + "name": "name", + "xml": "<outcome value='name'>", + "comments": "", + "outputs": 1, + "x": 2101.5042572021484, + "y": 136.42859196662903, + "z": "7458dba4.32cb64", + "wires": [ + [ + "9f5e4298.3ba59" + ] + ] + }, + { + "id": "930c8bdc.0463f8", + "type": "other", + "name": "topology", + "xml": "<outcome value='topology'>", + "comments": "", + "outputs": 1, + "x": 2113.5040130615234, + "y": 190.09525418281555, + "z": "7458dba4.32cb64", + "wires": [ + [ + "9f5e4298.3ba59" + ] + ] + }, + { + "id": "b3a0c7f3.4a5588", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 2485.5040893554688, + "y": 186.42861008644104, + "z": "7458dba4.32cb64", + "wires": [ + [ + "e1e167f3.9a8ab8" + ] + ] + }, + { + "id": "e1e167f3.9a8ab8", + "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=\"`'network-request-input.network-input-parameters.param '+ $tmp.name +' is a required input'`\" />\n", + "comments": "", + "x": 2643.5040893554688, + "y": 186.42861008644104, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "bad3546.ed6b1a8", + "type": "switchNode", + "name": "switch service-data.networks.network_length", + "xml": "<switch test='`$service-data.networks.network_length`'>\n", + "comments": "", + "outputs": 1, + "x": 1350.3927841186523, + "y": 497.7619024515152, + "z": "7458dba4.32cb64", + "wires": [ + [ + "5db60397.24e42c", + "d1ba2f0d.dcd85" + ] + ] + }, + { + "id": "5db60397.24e42c", + "type": "other", + "name": "outcome Null", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1604.003921508789, + "y": 474.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "9216f078.ec3f4" + ] + ] + }, + { + "id": "9216f078.ec3f4", + "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=\"network-topology-operation-input.network-request-input.network-id not found in service-data\" />\n", + "comments": "", + "x": 1782.003921508789, + "y": 474.42858946323395, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "d1ba2f0d.dcd85", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1584.503921508789, + "y": 514.428589463234, + "z": "7458dba4.32cb64", + "wires": [ + [ + "9e24923a.18e3c" + ] + ] + }, + { + "id": "9e24923a.18e3c", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1745.503921508789, + "y": 514.428589463234, + "z": "7458dba4.32cb64", + "wires": [ + [ + "a46227c4.f759c8", + "748af6ef.c63f88" + ] + ] + }, + { + "id": "a46227c4.f759c8", + "type": "for", + "name": "for nidx..service-data.networks.network[]", + "xml": "<for index='nidx' start='0' end='`$service-data.networks.network_length`' >\n", + "comments": "", + "outputs": 1, + "x": 2008.003921508789, + "y": 494.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "fa1d115b.6d17b" + ] + ] + }, + { + "id": "fa1d115b.6d17b", + "type": "switchNode", + "name": "switch networkid found", + "xml": "<switch test=\"`$service-data.networks.network[$nidx].network-id == $network-topology-operation-input.network-information.network-id`\">\n\n", + "comments": "", + "outputs": 1, + "x": 2294.003921508789, + "y": 494.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "37889212.4c53ee" + ] + ] + }, + { + "id": "37889212.4c53ee", + "type": "outcomeTrue", + "name": "true", + "xml": "<outcome value='true'>\n", + "comments": "", + "outputs": 1, + "x": 2464.503921508789, + "y": 494.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "b3a1659a.240748" + ] + ] + }, + { + "id": "272a6015.e0db5", + "type": "set", + "name": "set tmp.nidx and ctx.network-data", + "xml": "<set>\n<parameter name='tmp.nidx' value='`$nidx`' />\n<parameter name='ctx.network-data.' value='`$service-data.networks.network[$nidx].network-data.`' />\n", + "comments": "", + "x": 2865.5039825439453, + "y": 491.42863273620605, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "732b4efd.21101", + "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=\"network-topology-operation-input.network-request-input.network-id not found in service-data\" />\n", + "comments": "", + "x": 2222.003921508789, + "y": 534.428589463234, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "763f7f60.997eb", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 2084.503921508789, + "y": 534.428589463234, + "z": "7458dba4.32cb64", + "wires": [ + [ + "732b4efd.21101" + ] + ] + }, + { + "id": "748af6ef.c63f88", + "type": "switchNode", + "name": "switch tmp.nidx ", + "xml": "<switch test=\"`$tmp.nidx`\">\n\n", + "comments": "", + "outputs": 1, + "x": 1930.503921508789, + "y": 534.428589463234, + "z": "7458dba4.32cb64", + "wires": [ + [ + "763f7f60.997eb" + ] + ] + }, + { + "id": "3af5d77e.c8b058", + "type": "switchNode", + "name": "switch network-level-oper-status", + "xml": "<switch test='`$service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.order-status`'>\n", + "comments": "", + "outputs": 1, + "x": 1309.6706085205078, + "y": 573.3174673318863, + "z": "7458dba4.32cb64", + "wires": [ + [ + "c33efa09.b018d8", + "4cfec973.493b68" + ] + ] + }, + { + "id": "c33efa09.b018d8", + "type": "outcome", + "name": "outcome Created", + "xml": "<outcome value='Created'>\n", + "comments": "", + "outputs": 1, + "x": 1606.5040245056152, + "y": 573.3174654245377, + "z": "7458dba4.32cb64", + "wires": [ + [ + "7c4edd00.49aac4" + ] + ] + }, + { + "id": "4cfec973.493b68", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1574.5040245056152, + "y": 613.3174654245377, + "z": "7458dba4.32cb64", + "wires": [ + [ + "dabe6a18.d1d558" + ] + ] + }, + { + "id": "dabe6a18.d1d558", + "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=\"`'Network is not in appropriate state for activate. Current state is ' + $service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.order-status`\" />", + "comments": "", + "x": 1732.0040245056152, + "y": 613.3174654245377, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "c2120486.723e58", + "type": "switchNode", + "name": "switch network-id", + "xml": "<switch test=\"`$network-topology-operation-input.network-information.network-id`\">\n", + "comments": "", + "outputs": 1, + "x": 1256.503921508789, + "y": 434.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "c9dd79cc.30f0a8" + ] + ] + }, + { + "id": "c9dd79cc.30f0a8", + "type": "outcome", + "name": "NULL", + "xml": "<outcome value=''>", + "comments": "", + "outputs": 1, + "x": 1484.503921508789, + "y": 434.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [ + "f8690bd9.02e568" + ] + ] + }, + { + "id": "f8690bd9.02e568", + "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=\"network-request-input.network-input-parameters.name is a required input\" />\n", + "comments": "", + "x": 1622.003921508789, + "y": 434.42858946323395, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "d93bc459.24d028", + "type": "execute", + "name": "execute requiredParameters", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='requiredParameters' >\n<parameter name=\"network-topology-operation-input.network-information.network-id\" value=\"$network-topology-operation-input.network-information.network-id\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 1291.003921508789, + "y": 394.42858946323395, + "z": "7458dba4.32cb64", + "wires": [ + [] + ] + }, + { + "id": "376f44f.91631bc", + "type": "switchNode", + "name": "switch network-level-oper-status", + "xml": "<switch test='`$service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.order-status`'>\n", + "comments": "", + "outputs": 1, + "x": 1337.837173461914, + "y": 823.3174444437027, + "z": "7458dba4.32cb64", + "wires": [ + [ + "4ff725b8.75f0ac", + "b79412d2.13234" + ] + ] + }, + { + "id": "4ff725b8.75f0ac", + "type": "outcome", + "name": "outcome Active", + "xml": "<outcome value='Active'>\n", + "comments": "", + "outputs": 1, + "x": 1611.1705474853516, + "y": 797.7619024515152, + "z": "7458dba4.32cb64", + "wires": [ + [ + "d84d7eae.ba968" + ] + ] + }, + { + "id": "b79412d2.13234", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1581.1705474853516, + "y": 837.7619024515152, + "z": "7458dba4.32cb64", + "wires": [ + [ + "b8e9f263.26346" + ] + ] + }, + { + "id": "b8e9f263.26346", + "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=\"`'Network is not in appropriate state for deactivate. Current state is ' + $service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.order-status`\" />", + "comments": "", + "x": 1747.1705474853516, + "y": 839.7619024515152, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "36e3a49c.e1e66c", + "type": "switchNode", + "name": "switch network-level-oper-status", + "xml": "<switch test='`$service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.order-status`'>\n", + "comments": "", + "outputs": 1, + "x": 1326.726089477539, + "y": 994.4285284280777, + "z": "7458dba4.32cb64", + "wires": [ + [ + "fc99139.ec0cdf", + "4e170b57.b8a2a4" + ] + ] + }, + { + "id": "fc99139.ec0cdf", + "type": "outcome", + "name": "outcome PendingDelete", + "xml": "<outcome value='PendingDelete'>\n", + "comments": "", + "outputs": 1, + "x": 1626.7261505126953, + "y": 962.2063242197037, + "z": "7458dba4.32cb64", + "wires": [ + [ + "9aca9b79.d849b8" + ] + ] + }, + { + "id": "4e170b57.b8a2a4", + "type": "other", + "name": "other", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1570.0594635009766, + "y": 1008.8729864358902, + "z": "7458dba4.32cb64", + "wires": [ + [ + "50d4161c.bde178" + ] + ] + }, + { + "id": "50d4161c.bde178", + "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=\"`'Network is not in appropriate state for delete. Current state is ' + $service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.order-status`\" />", + "comments": "", + "x": 1736.0594635009766, + "y": 1010.8729864358902, + "z": "7458dba4.32cb64", + "wires": [] + }, + { + "id": "7c4edd00.49aac4", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1794.5039024353027, + "y": 574.4285494089127, + "z": "7458dba4.32cb64", + "wires": [ + [] + ] + }, + { + "id": "d84d7eae.ba968", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1811.170425415039, + "y": 795.910034775734, + "z": "7458dba4.32cb64", + "wires": [ + [] + ] + }, + { + "id": "9aca9b79.d849b8", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 1842.2816314697266, + "y": 962.5766607522964, + "z": "7458dba4.32cb64", + "wires": [ + [] + ] + }, + { + "id": "b3a1659a.240748", + "type": "block", + "name": "block : atomic", + "xml": "<block atomic=\"true\">", + "atomic": "true", + "outputs": 1, + "x": 2614.6704330444336, + "y": 490.7619377374649, + "z": "7458dba4.32cb64", + "wires": [ + [ + "272a6015.e0db5" + ] + ] + } +] |